Watch, Follow, &
Connect with Us

For forums, blogs and more please visit our
Developer Tools Community.


Welcome, Guest
Guest Settings
Help

Thread: Case When


This question is answered. Helpful answers available: 2. Correct answers available: 1.


Permlink Replies: 1 - Last Post: Apr 21, 2018 6:35 AM Last Post By: Melissa Torn
Melissa Torn

Posts: 143
Registered: 4/30/09
Case When  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Apr 21, 2018 2:40 AM
Case When (IT.UOMRNO = IT.LASTUOMRNO) Then
IT.LASTPRICE Else (IT.LASTPRICE / IT.UOMQTY2) End AS LASTPRICE,
Case When IT.BOMCOST_LAST IS NULL or IT.BOMCOST_LAST=0 Then
IT.LASTPRICE Else IT.BOMCOST_LAST End AS LASTPRICE

Above SQL works but i get 2 LASTPRICES (LASTPRICE & LASTPRICE2)
How can i combine above 2 Case sql to get just 1 field (LASTPRICE)

Thank You
Melissa Torn

Posts: 143
Registered: 4/30/09
Re: Case When  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Apr 21, 2018 6:35 AM   in response to: Melissa Torn in response to: Melissa Torn
I solved the problem
Thank You
Legend
Helpful Answer (5 pts)
Correct Answer (10 pts)

Server Response from: ETNAJIVE02