Still working in access.
Here is the SQL from one of the queries in the database:
INSERT INTO t_bookorders
(ISBN, BOOK_ID, BookSequenceNum, Publisher ORDer_DATE, ORDered_QTY, QTYS, Book_PRICE, List_Value_1, List_Value_2,Book_DESC )
master_Book_List.RET_QTY, "Units" AS Expr1,
CASE WHEN titles.backorder= 'N' THEN 'Verify with teacher"',
WHEN titles.backorder= = 'Y' THEN 'add surcharge',
FROM (master_Book_List LEFT JOIN MASTER_PublisherList ON master_Book_List.PROD_ID = master_Book_List.PROD_ID)
LEFT JOIN dupe_Books ON (master_Book_List.BookSequenceNum = q_dupes_1.[SEQ_NBR Field]))
WHERE (((master_Book_List.Mark)=True) AND ((q_dupes_1.[ORD_ID Field]) Is Null));
I get this error around my CASE statements: "Syntax error missing operator in query expression"
I then substituted the CASE statements with Ifs:
If titles.backorder= 'N' THEN 'Verify with teacher"',
ELSE IF titles.backorder= = 'Y' THEN 'add surcharge',
I got the same error.
What am I doing wrong?