Forum Replies Created

Viewing 15 posts - 2,461 through 2,475 (of 3,668 total)

  • RE: Reset Identity PK field

    If you want to reset an identity range then

    DBCC CHECKIDENT('YourTable',RESEED,0)

    If you want to explicitly add a record that over rides the identity then

    SET IDENTITY_INSERT dbo.YourTable ON

    INSERT Yourtable(PKField,OtherFields) VALUES (0,Yourvalues)

    SET IDENTITY_INSERT...

  • RE: UDF - Executing dynamic sql

    If all you want is a rowcount and you are prepared to put up with an estimate then set up your function to pass in the name of your table...

  • RE: Can Enterprise Manager & SQL Server 2005 Management Studio coexist?

    I've got both SQL2000 and SQL2005 on my box at work without any problems.

    I don't think it will be SQL2005 that hosed EM because SQL2005 does not use MMC.

  • RE: Looping through files with DTS

    OK my eventual solution (which probably isn't the best) was to have my begin loop code enable/disable the relevant steps but store the number of steps in a global variable.

    At...

  • RE: WHICH OF THESE TWO QUERIES IS FAST

    Yes I did mean "This doesn't".

    In both SQL 2000 and SQL 2005 the statement forces an index seek however in SQL2005 a "Filter" step is added into the execution plan...

  • RE: Trigger to Auto Update

    Don't do it as a trigger, do it as a stored procedure and schedule it for 1st July and 1st Jan.

  • RE: File Defragmenting

    From previous posts the native defragger is a cut down version of Diskeeper.

    If your files are across a RAID array or a SAN then be careful with your chosen defrag...

  • RE: DBCC SHOWCONTIG drives DBREINDEX

    Don't all indexes hang of the clustered index?

    If you rebuild a non-clustered index and then rebuild the clustered index doesn't that alter the first index?

    I have noticed that DBCC UPDATEUSAGE(0)...

  • RE: maintenance plan job hanging

    Have you asked the job to notify you on success.

    I had a situation where I got SQLMail to email me on successful completion. Something went pear shaped on the...

  • RE: Runaway Identity column values

    If an attempt is made to insert a value in a table with an identity value and it fails the identity value still increments.

    I would run a SQL Profiler to...

  • RE: Using A Stored Procedure instead of writing out SQL Statements

    What value do you have for adCmdStoredProc?

  • RE: WHICH OF THESE TWO QUERIES IS FAST

    In terms of performance I don't think there will be any difference.

    I prefer to specify the columns because if the underlying table changes its structure my query is still bringing...

  • RE: Using A Stored Procedure instead of writing out SQL Statements

    Firstly SQL Server has two functions that get the system date

    GETDATE() retrieves the current system date

    GETUTCDATE() which retrieves the Greenwich Meantime Date and Time

    There are several ways of getting the...

  • RE: SQL Query Help

    My question would be "Why do you want to do this"?

    If it is something that the front end application requires then I would return the original recordset but have the...

  • RE: Question on Index usage

    Yes

    Provided your query uses Col A the index will be used.

Viewing 15 posts - 2,461 through 2,475 (of 3,668 total)