Forum Replies Created

Viewing 15 posts - 286 through 300 (of 692 total)

  • RE: Restore database

    You'll have to restore it with all 4 files.

    Then, you'll need to use the DBCC SHRINKFILE command with the EMPTYFILE option to move all the data out of the file...

  • RE: The insult before Christmas

    There is absolutely no doubt that it would have been cheaper and more fun, and I'd probably have more hair!

    Steve

    Oh, and I checked that book cover, and, umm, I still...

  • RE: The insult before Christmas

    Joe,

    Speak for yourself!  I weigh nearly twice what I did in the 70's!  And I think the only clothes that I still have from back then is the coveralls...

  • RE: SSWUG is it a real USER GROUP or not ??

    When I first became a SQL DBA, SWYNK.com was THE website to go to for help, reference, scripts, etc.  I spent a lot of time...

  • RE: sa Audit Trail

    If its always from the same machine, put a key-logger on it.  That'd give you concrete proof.

    Steve

  • RE: Based on @error how to omit SQL err msg

    Yes, of course.  Sorry about that.  However, the general idea will still work.  Just plug in @strTableName where I have tmpCDR_Hold_Table in the IF EXISTS

    Steve

  • RE: Transaction log backup - A silly question

    Another possibility is that they realized that the full backup wasn't truncating the log, and added the log backup to achieve that, without considering recoverability at all.

    Steve

  • RE: SQL 2000 cause memory leakage?

    Its not leakage.  SQL, by default, will grab memory from the system as it needs it and will keep it unless another process needs it.  So, if at some point,...

  • RE: Backing up a database

    Here's a stored procedure that will delete backup files based on the age given in the filename.  Note that it gets retention information and the path for the backups from...

  • RE: Backing up a database

    Here's some code that will include the date and time in your backup name -

    DECLARE 

      @BKdate varchar(20),

     @BKExec varchar(200),

     @BKDevice varchar(200),

     @path varchar(150),

     @DBname varchar(30)

    SET @path = 'X:\SQL_Backups\'

    SET @DBname = 'PUBS'

    SELECT @BKdate= CONVERT(varchar(26),getdate(),21)

    SELECT...

  • RE: Based on @error how to omit SQL err msg

    You can check for the existence of the table before the insert, raise your error if the table doesn't exist, and bypass the insert statement.

    if exists (select * from sysobjects...

  • RE: tracing SA login Falied

    You said that you can't get them to shut everything down and bring up one by one.  Can you get them to bring clients down one by one?  Bring one...

  • RE: Invalid character value for cast specification

    Its a "typematch error".  Basically, you're trying to load a non-numeric character into a numeric field, or a non-date value into a datetime field.

    Steve

  • RE: Missing SPs for sending mail

    For the record-

    I just checked our MSDE instance, and sp_oacreate and its partners exist in the extended stored procedures grouping in Enterprise Manager.

    Steve

  • RE: setting a variable based on query in dynamic SQL?

    Here's a sample that I have saved on my harddrive.  It should get you going...

    declare

     @command nvarchar(1000),

     @parmlist nvarchar(100),

     @fname varchar(20),

     @lname varchar(20)

    set @lname = 'accorti'

    set @command = N'select @fname = fname from...

Viewing 15 posts - 286 through 300 (of 692 total)