Table 1
ID
1
2
3
Table 2
ID date opt
1 1/1/10 1
1 1/2/10 0
2 1/1/10 1
I Want
ID date opt
1 1/2/10 0
2 1/1/10 1
How do I join these 2 tables? Just match all the ID's in table 1 with their most recent opt in table 2. Without partitions, please. I'm in sql 2005. Thanks.