M
MilesMonkMingus
Can I use case statement within an Access query?
I have a data item PCPCajCd1 that may contain a value of "FED", "H&W" and/or
"SMI" When it contains "FED", I want to subtotal the corresponding numeric
data within data item PCPCajAm1 as FED_Sum.
This is the syntax that I am using:
SUM(CASE PCPCajCd1 WHEN "FED" THEN PCPCajAm1 ELSE NULL END) AS FED_Sum
I have a data item PCPCajCd1 that may contain a value of "FED", "H&W" and/or
"SMI" When it contains "FED", I want to subtotal the corresponding numeric
data within data item PCPCajAm1 as FED_Sum.
This is the syntax that I am using:
SUM(CASE PCPCajCd1 WHEN "FED" THEN PCPCajAm1 ELSE NULL END) AS FED_Sum