Hello,
i am trying to use a switch statement in a access query and i be leave i have the code right but for some reason it will only output a string i need it to output an long integer please look over my code and see if you have any ideas.(all the columns that are in the statement are Numbers)
thank you
Code:
columnName:Switch (([column1]<>0), [column1], ([column2]<>0), [column2], ([column3]<>0), [column3],([column4]<>0),[column4],([column4]=0),0)
outputs a string i need an long integer
i have tried
Code:
columnName:Switch (([column1]<>0), CLng(column1), ([column2]<>0), CLng(column2), ([column3]<>0), CLng(column3),([column4]<>0),CLng(column4),([column4]=0),0)
and dose not work just outputs a string
It outputs the right number but not as an intiger
anyone got any ideas
thank you ahead of time