Home Forums SQL Server 2012 SQL Server 2012 - T-SQL how to update column city value from 'A' to 'B' and 'B' to 'A' in single query RE: how to update column city value from 'A' to 'B' and 'B' to 'A' in single query

  • GilaMonster (10/8/2013)


    LutzM (10/8/2013)


    if we update a "left" table in a 1 ..n relationship, will sql server perform n updates or will it just do a single update?

    Single.

    I know. But I thought it would make a good question. 😉

    Unfortunately, answered immediately. :crying: (as it is common here at SSC...)

    But the list of questions can be continued:

    If it's a single update, which value will be used? Will it be consistent/reproducable or may it vary under certain conditions (e.g. parallelism)?



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]