April 10, 2008 at 12:55 pm
I have a view that contains order shipping info (order#, name, address1, EmailAddress, etc.) using existing table fields. It works great in conjunction with our UPS shipping app but now I need another column in the view called "Profile". The value in Profile will be dependent upon whether existing "EmailAddress" column is null or not. If I were doing this in Access QBE grid it would read
Profile:IIf([EmailAddress] is not null, "QV", "PARK")
I know I should be using CASE_WHEN_ELSE but not sure where to use AS to give the column the name "Profile". Any help would be appreciated!
April 10, 2008 at 12:59 pm
...
select field1,
case when [EmailAddress] is not null then 'QV' else 'PARK' end as Profile,
field2
from
...
----------------------------------------------------------------------------------
Your lack of planning does not constitute an emergency on my part...unless you're my manager...or a director and above...or a really loud-spoken end-user..All right - what was my emergency again?
April 10, 2008 at 1:11 pm
Thanks Matt! Did the trick.
Viewing 3 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply
This website stores cookies on your computer.
These cookies are used to improve your website experience and provide more personalized services to you, both on this website and through other media.
To find out more about the cookies we use, see our Privacy Policy