I have a query (see snapshot) which I have added a field to (ReschDate). The query has been used to determine if an order was delivered on time or not. Currently the "OnTime" field looks at "DateShpd" and compares it to "Ack_Date". If DateShpd" is <= Ack_Date then the answer is Y.
But now we want to compare "DateShpd" to EITHER "Ack_Date" OR "ReschDate" using the higher valued date from "Ack_Date" or "ReschDate". So if DateShpd is <= the higher of the values, Ack_Date or ReschDate" the the answer should be "Y". If not then the answer should be "N".
How can I rework this query to handle this?