Unanswered: Getting the latest date from 4 different date fields
I was wondering if someone could help me write this query. I have one database with a number of records. In each of this record, I have an ID # and 4 different date fields. I want to compare each of these 4 dates (date1, date2 etc...) against each other. At each comparison, I want to store or retain only the latest date out of these 4 in a separate field called 'latest date'.
date1 is 040101
date2 is 040315
date3 is 031001
date4 is 021101
so latest date field should be then 040315. Please let me know how I would store or insert also the last date in 'latest date' field.