Please ignore this question if it seems silly to you.
I have a SQL table (SQL Server) for photo albums, and it has 20 + columns, and it will contain millions of albums.
I need to label some albums as featured and some as Favorite every week. I also need a very effective way to get these albums (per page) when I show them to users.
How do I create this?
option 1: I can create another table to save the identifiers of advanced and recognized albums like this, and then join the main album table to get the set of columns that I need.
tableited_albums:
album_id promoted_featured 1 1 5 0 7 1 15 0
Promotion request will be returned 1, 7 Request for attribute will return 5, 15
Option 2: I can add 1 column store 1 if it was advanced, and 0 if it is specified. Otherwise, it is zero. Then I can request a check of 1 in this column for advanced albums and 0 for showing.
Option 3: I can add 2-bit columns: one for advanced (0/1) and one for recognized (0/1)
Which way will work better?
EDIT: Design should also be effective in SQL 2008. I now have SQL 2005.
source share