Forum Discussion
Ganesh99
Jan 11, 2023Copper Contributor
iif statement in Access DB
Hi all, I m unable to get my iif statement right. I have a table Dec 22 in which 2 columns are SO and Description. Say if I want a True if the values in SO = Description and otherwise a False. H...
Harun24HR
Jan 11, 2023Bronze Contributor
Ganesh99 Try the below query. See the attached file.
SELECT Table1.SO, Table1.Description, IIF([SO]=[Description],"TRUE","FALSE") as [Boolean] FROM Table1;
- Ganesh99Jan 11, 2023Copper Contributor
Hi, Harun24HR! Thanks.
This interaction made me feel I m not alone here. Thanks again.
I achieved this. I have been trying to use the Update query as I want this column to have True and False in an already existing table. I am getting an error test saying that there should be at least one destination. I guess the field - Update To can't be left blank. But we are supposed to write the iif function in the first row which happens to be field. So what do I write in Update to?
I see that you have used Select query.
Regards
Ganesh
+91 8451046072