Results 1 to 2 of 2
  1. #1
    Join Date
    Aug 2010

    Unanswered: newbie DB2 SQL question

    I am brand new to DB2. My background is SQL Server.

    I installed DB2 Express C v.9.7.2 and IBM Data Studio.

    In SQL Server Management Studio, I'd write some ad-hoc T-SQL like this :

    declare @date1 date
    declare @date2 date
    declare @date3 date

    set @date1 = CAST('1999-12-31' as date)

    set @date2 = GETUTCDATE()

    set @date3 = DATEADD(YEAR,-1,GETUTCDATE())

    print @date1
    print @date2
    print @date3

    How would I write similar in DB2 ?

    Last edited by johnagrandy; 08-13-10 at 19:47.

  2. #2
    Join Date
    Jun 2003
    Toronto, Canada
    Provided Answers: 1
    You would probably open IBM DB2 9.7 for Linux, UNIX and Windows Information Center, read the application development section, look at some samples, and you'd be good to go.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts