So I have 2 tables:
- Customers
- Files
How do I do a join to show the latest record, i.e by created_on DESC
e.g
SELECT customers.name, files.last_file_submission
if I have:
customer A
- File 1, created_on 10-10-2012
- File 2, created_on 11-10-2012
and I want to return a single line for each customer that has:
customer A, 11-10-2012
Per file:
Per user: