I'm currently joining 2 tables, and am having a slight problem. Basically, the table that links the posts and hte categories should be able to have as many categories as needed (realistically it's 2, occasionally 3) per post. Now the problem is, when I want to select 10 posts, I can't just LIMIT 10, because if there's 5 posts with 2 categories each, it'll come out as 10. (Oh, and the query's something like "SELECT posts.*, postcats.cid FROM posts, postcats WHERE posts.id=postcats.pid && ..."
Any ideas what the most efficient way of doing this is? Thanks.