Consider a database with 2 large tables -- Book and BookLog. The Book table contains millions of book records and BookLog contains activity about those books (e.g. acquired, checked out, checked in, damaged, repaired, etc.). Each Book could have 0 to many (thousands) of log entries. Each log entry contains a datetime that indicated when it was recorded. I need to create a stored proc that will return all books along with the most recent log entry (if one exists). I can think of a few ways to do this, but all require multiple steps/queries and suffer from performance problems. Anyone have any suggestions for a query / stored proc like this that maximizes performance for large tables? I run into this scenario quite often - you've got a master table then a related table with 0 to many rows in it, and want to return a query that shows the last (or first or whatever) related record. I've never found a solution to this type of query that I'm happy with.