Forum Replies Created

Viewing 15 posts - 4,336 through 4,350 (of 7,613 total)

  • RE: What is the difference between Left Outer join and Left Outer join restricted- Interview question

    Yep, exactly. It sounds like some type of certification q too, where because MS mentions "restricted" in BOL or some other help, you're supposed to remember it exactly and...

    SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".

  • RE: Prod DB on Simple Recovery Model

    GonnaCatchIT (4/8/2016)

    We run re-indexing and update statistics on daily basis

    Is that really necessary? Do you re-index all tables or just those that really need it? Hopefully you don't...

    SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".

  • RE: BULK INSERT row order guaranteed?

    If the incoming data is sorted in clustering key order, you can add an:

    ORDER ( { column [ ASC | DESC ] } [ ,... n ] )

    clause to the...

    SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".

  • RE: Query help

    Add another temp table to hold the Project & Packages you want to list. Then run the SELECT below.

    Btw, you should add a clustering key to the #DateHr table...

    SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".

  • RE: Best Way write Query for parameter

    Not sure which ClientId column is in Temp_Client, so change if needed:

    SELECT [AssigneeID]

    FROM [dbo].Assignee

    LEFT OUTER JOIN Temp_Client ON Clientid = Client_ID

    WHERE @clientid = 'ALL' OR Temp_Client.Clientid IS NOT...

    SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".

  • RE: Set ANSI_WARNINGS OFF not working while sever based trigger enabled

    CREATE TRIGGER %%

    ON ALL SERVER

    WITH EXECUTE AS 'sa'

    AFTER

    CREATE_TABLE,ALTER_TABLE,DROP_TABLE,CREATE_VIEW, ALTER_VIEW, DROP_VIEW

    , CREATE_FUNCTION, ALTER_FUNCTION, DROP_FUNCTION

    , CREATE_PROCEDURE, ALTER_PROCEDURE, DROP_PROCEDURE

    AS

    SET ANSI_PADDING ON;

    SET ANSI_WARNINGS ON;

    SET ARITHABORT ON;

    SET CONCAT_NULL_YIELDS_NULL ON;

    SET NOCOUNT ON;

    SET NUMERIC_ROUNDABORT...

    SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".

  • RE: Search Optomisation

    DesNorton (4/6/2016)

    Hi Scott

    This is certainly fast, with similar I/O to the other solutions, but very low CPU numbers. However, I am unable to wrap my head around the math...

    SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".

  • RE: Restoring a database and maintaning filename

    Rather than using a gui, use a SQL RESTORE command to do the restore. Then the new files can be specified using the "WITH" clause.

    And here's a function I...

    SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".

  • RE: How to find out if any user aliases are being used on SQL Server instance?

    I think you can use the (old) view "sysusers", "WHERE isaliased = 1" to find any aliases.

    SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".

  • RE: Search Optomisation

    Another possibility is to leave the main table alone, and create a separate table to hold the partial partids to match on. Use a trigger on the main table...

    SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".

  • RE: Comparing two tables in two databases

    MS provides tablediff.exe for free. It works ... but it is a command-line tool and, like bcp, takes a bit of time/work to get used to and get it...

    SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".

  • RE: Why Identity value gets jumps to lower value ?

    No, a stop / start of SQL Server will not cause an identity value to go down. Your code must be resetting it for that to happen.

    SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".

  • RE: About Index - Can we create a nonclustered index on clustered index column

    Yes, creating a non-clustered index on the clus index column(s) can indeed help performance for certain queries. It's a valid thing to do when that situation exists.

    SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".

  • RE: How do I Avoid Deadlocks?

    You could also consider using an A/B table approach. That is, the nightly load goes into a different table name. When the load process is complete, either the...

    SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".

  • RE: which algorithm is used in my query?

    Most likely a LOOP join will be used. That is not guaranteed, of course, but it is likely.

    If you want to be sure what join algorithm will be used,...

    SQL DBA,SQL Server MVP(07, 08, 09) "It's a dog-eat-dog world, and I'm wearing Milk-Bone underwear." "Norm", on "Cheers". Also from "Cheers", from "Carla": "You need to know 3 things about Tortelli men: Tortelli men draw women like flies; Tortelli men treat women like flies; Tortelli men's brains are in their flies".

Viewing 15 posts - 4,336 through 4,350 (of 7,613 total)