Complex updating query, Help!!!!!

sql Malaysia
  • 13 years ago

    There are two tables:

     Table A                                                                   Table B

    ---------------------------------------                                        ----------------------------------------

    AID      C1       C2      Status                                     BID           col1       col2         status

    ---------------------------------------                                        ---------------------------------------------------------

    1         22         21        AA                                        1                22         21           A

    2         23         25        BB                                        2                23         21           C

    3          23         21        AA                                       3                11         44           B

     

    So here is the case,

     I want to update tableB Colom Status with condition like this:

    search colom status in table A that equal to AA, compare col C1

    and

Post a reply

No one has replied yet! Why not be the first?

Sign in or Join us (it's free).

Contribute

Why not write for us? Or you could submit an event or a user group in your area. Alternatively just tell us what you think!

Our tools

We've got automatic conversion tools to convert C# to VB.NET, VB.NET to C#. Also you can compress javascript and compress css and generate sql connection strings.

“God could create the world in six days because he didn't have to make it compatible with the previous version.”