Saudi Mike
Registered User.
- Local time
- Today, 15:22
- Joined
- Jun 10, 2015
- Messages
- 28
I am trying to compare dates between multiple tables and retrieve the latest date. Basically:
1 - I have a master table that records work requests given to the group.
2 - I have 9 different tables, one for each team in the group. Each team gets handed different parts of one task and reports when they completed the task under a field on their respective tables called "1stIssuedDate". All tasks have the same ID that relates the tasks.
Now I am trying to derive a query that will compare the various "1stIssuedDate"s and determine the latest date. I think this should be straight forward, but I've not figured it out.
I thought I could write an IIF statement that would compare the first team to the second, third, etc, and if it does not have the latest date it would go to the next IIF statement that would compare the second to the third, forth, ect, but this gets to be a rather long winded multi-nested IIF statement.
In general, how would I go about doing this in an efficient manner?
thanks!!
1 - I have a master table that records work requests given to the group.
2 - I have 9 different tables, one for each team in the group. Each team gets handed different parts of one task and reports when they completed the task under a field on their respective tables called "1stIssuedDate". All tasks have the same ID that relates the tasks.
Now I am trying to derive a query that will compare the various "1stIssuedDate"s and determine the latest date. I think this should be straight forward, but I've not figured it out.
I thought I could write an IIF statement that would compare the first team to the second, third, etc, and if it does not have the latest date it would go to the next IIF statement that would compare the second to the third, forth, ect, but this gets to be a rather long winded multi-nested IIF statement.
In general, how would I go about doing this in an efficient manner?
thanks!!