In MS Access, I'm trying to append data from one table (Table A) into another table (Table B). Table A has a column of type 'Short Text' with a single value 'Even' or empty/null. Table B has an equivalent column of type Yes/No. I've to insert data from Table A to Table B, while doing this conversion - if Table A's column has 'Even' set Table B's value to True, otherwise, set it to False.
I've tried a query like the following but it didn't work:
INSERT INTO TableB( BookName, ChapterName, PageNo, Even)
SELECT name, chapter, page, IIf(UCase([Even or Odd]) = 'EVEN', True,False)
FROM TableA;
The above query gives me following error:
Microsoft Access can't append all the records in the append query. Microsoft Access set 0 field(s) to Null due to a type conversion failure, and it didn't add 117 record(s) to the table due to key violations....
How can I make access change the value while appending the data?