get posts and postmetas in assoc array

Basically, you can’t do it in a single SQL query. You need two.

You don’t have to make direct queries though, since you can use get_post() and get_post_custom().