Hi,
I'm using a switch function in a select statement,and the query is
SELECT ret_date as return_date,
switch([dbarc.cat_cd]="TOTA","TOTAL",
[dbarc.cat_cd]="TOTM","TOTM",
[dbarc.cat_cd]="EQT","EQTALL",
[dbarc.cat_cd]="FIX","FIXALL") AS class,'N'AS cash
FROM acct_category AS dbarc ;
The switch works fine,ie it changes,if it finds
the values'TOTA','TOTM','EQT','FIX' to the respective values
But if it finds other than these values I want to keep it
the same but what it does is puts a space in all other
values.So what should be added to preserve the other values
other than specified in the switch.
And can I pls know good websites for learning MS-Access SQL
Syntax ?
Thanks much
-GR
I'm using a switch function in a select statement,and the query is
SELECT ret_date as return_date,
switch([dbarc.cat_cd]="TOTA","TOTAL",
[dbarc.cat_cd]="TOTM","TOTM",
[dbarc.cat_cd]="EQT","EQTALL",
[dbarc.cat_cd]="FIX","FIXALL") AS class,'N'AS cash
FROM acct_category AS dbarc ;
The switch works fine,ie it changes,if it finds
the values'TOTA','TOTM','EQT','FIX' to the respective values
But if it finds other than these values I want to keep it
the same but what it does is puts a space in all other
values.So what should be added to preserve the other values
other than specified in the switch.
And can I pls know good websites for learning MS-Access SQL
Syntax ?
Thanks much
-GR