Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
sqlfresher2k7
Aged Yak Warrior
623 Posts |
Posted - 2014-01-29 : 17:46:44
|
I need a query which should update the master table with status based on the details records..Below is the sample data with expected output.Thanks for your help in advance..TableASID ---- 1011 12TableBSID action ---- ------- 10 110 311 511 611 512 1Expected Output:SID status---- ------10 Y11 N12 Y |
|
tkizer
Almighty SQL Goddess
38200 Posts |
Posted - 2014-01-29 : 18:11:39
|
What is the correlation between action and status? I don't understand why 10/12 are Y and 11 is N.Tara KizerSQL Server MVP since 2007http://weblogs.sqlteam.com/tarad/ |
|
|
sqlfresher2k7
Aged Yak Warrior
623 Posts |
Posted - 2014-01-29 : 18:45:36
|
I want to update "Y" when the actions are (1,3,4) else "N" |
|
|
|
|
|