Results 1 to 2 of 2

Thread: Combine Update Queries

  1. #1
    Join Date
    Sep 2002
    Posts
    218

    Combine Update Queries

    Is it possible to run these two queries as one ? If so how do l combine them so that l issue one update
    Statement not two.


    Begin Transaction
    Update EXACTUS_Fields
    Set FileName =
    Case
    WHEN SUBSTRING(Field, 1, 3) = 'T01' THEN 'ZA31100P'
    WHEN SUBSTRING(Field, 1, 3) = 'T02' THEN 'ZA32000P'
    WHEN SUBSTRING(Field, 1, 3) = 'T03' THEN 'ZA10000P'
    WHEN SUBSTRING(Field, 1, 3) = 'T04' THEN 'ZA04300P'
    WHEN SUBSTRING(Field, 1, 3) = 'T05' THEN 'ZA31400P'
    End
    Go

    Begin Transaction
    Update EXACTUS_Fields
    Set QryName = 'Exctract1'
    ,LibraryName = 'tesQry'
    ,Owner = 'Ian Kaplan'
    Commit


    Q 2)

    When doing a conversion from DB2 to SQL whats the best approach to use. Thesystem is not well documented and the data dictionery is not very helpful it contains insuffient data.What the best approach? Are they any articles that l can read?

  2. #2
    Join Date
    Feb 2009
    Posts
    17
    To my knowledge you will have to still keepthis in two queries but here is a great resource for you to refer to when Migrating from DB2 to SQL Server...

    http://www.microsoft.com/sqlserver/2...e-ibm-db2.aspx

    Hope this helps,

    Larry D
    MS Architect Evangelist

Posting Permissions

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