Forum Replies Created

Viewing 6 posts - 331 through 337 (of 337 total)

  • RE: date calculations

    Are you using SQL 2008 ?If not then it will error out.

    --------------------------------------------------------------------------------------------------
    I am just an another naive wannabe DBA trying to learn SQL Server

  • RE: date calculations

    select convert(date,dateadd(mm,-3,GETDATE()+1))

    --------------------------------------------------------------------------------------------------
    I am just an another naive wannabe DBA trying to learn SQL Server

  • RE: Help with the Stored Proc

    That wont be much of a problem.any of the above solutions posted will work.

    --------------------------------------------------------------------------------------------------
    I am just an another naive wannabe DBA trying to learn SQL Server

  • RE: Help with the Stored Proc

    select top 1 status from yourtable where status='Failure'

    IF @@rowcount>=1

    select 'Failed'

    else

    select 'Success'

    --------------------------------------------------------------------------------------------------
    I am just an another naive wannabe DBA trying to learn SQL Server

  • RE: Need help with writing TSQL

    declare @t table(id int identity,dt date NULL,stepid int)

    insert @t

    select '2008-03-03',1 union all

    select '2008-03-04',1 union all

    select '2008-03-14',5 union all

    select null,5 union all

    select '2008-03-20',6...

    --------------------------------------------------------------------------------------------------
    I am just an another naive wannabe DBA trying to learn SQL Server

  • RE: ATTACHED SUSPECT DATABASE in SQL2008 R2

    Is the last full backup and log file available.If yes then you need to

    1)Take a Tail log backup.

    2)Create a new database and then restore the full backup.

    3)Restore the Tail log...

    --------------------------------------------------------------------------------------------------
    I am just an another naive wannabe DBA trying to learn SQL Server

Viewing 6 posts - 331 through 337 (of 337 total)