Hi,
I'm working on a news site. Like every news site there will be news, columns, videos and photo galleries. I'm planning to keep these different types of records in different tables but relate them with tags. Here is a simple schema:
Tables: News, Videos, Galleries, Columns, Tags, Post_to_tags
Post_to_tags:
- tagid
- postid
- posttype [news,video,gallery,column]
Now what I need to do is get related records for a post in a single query. It's easy to join one table and get related posts but when it comes to different tables... Any idea?