By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
443,560 Members | 949 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 443,560 IT Pros & Developers. It's quick & easy.

Update Query

P: 6
I have two update query as following.

UPDATE Grade SET Grade.Variance = [Plan]-[Actual]
WHERE ([Score]<>0);

UPDATE Grade SET Grade.Variance = 0
WHERE ([Score]=0);

Is that possible that I can merge above two queries into One query to finish the job?

I apprecaite you can help me with this.
Dec 1 '06 #1
Share this Question
Share on Google+
1 Reply


NeoPa
Expert Mod 15k+
P: 31,602
I have two update query as following.

UPDATE Grade SET Grade.Variance = [Plan]-[Actual]
WHERE ([Score]<>0);

UPDATE Grade SET Grade.Variance = 0
WHERE ([Score]=0);

Is that possible that I can merge above two queries into One query to finish the job?

I apprecaite you can help me with this.
Expand|Select|Wrap|Line Numbers
  1. UPDATE Grade
  2. SET Variance = IIf([Score]=0,0,[Plan]-[Actual]);
Dec 1 '06 #2

Post your reply

Sign in to post your reply or Sign up for a free account.