If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > General > Database Concepts & Design > News Section ~ Please Help

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 11-20-03, 11:13
rm82 rm82 is offline
Registered User
 
Join Date: Jul 2002
Posts: 9
Red face News Section ~ Please Help

Hi all,

I need some advice. I am creating the last part of my website which is a news section. Now i have created the basic tables but i also want my news section to relate to other tables within my database. Now i could take the very narrow approach and put some cells in my table to represent this, but then i am not really future proofing my database with that. I know that a news article will only belong to one of my sites categories so thats not an issue, but a news item may belong to several countries or resorts.

So here is what i have and i want to know if anyone has any views. I just have added PK and FK to illustrate.

Table: tblNews
ID (PK)
SiteCategoryID(FK From Site Category)
...Rest Of Table

Table: tblResort
ID (PK)
ResortName
...Rest Of Table

Table: tblCountry
ID(PK)
CountryName
...Rest Of Table

Table: tblNewsCountry
ID(PK)
NewsID (FK From News)
CountryID (FK From Country)

Table: tblNewsResort
ID(PK)
NewsID(FK From News)
ResortID(FK From Resort)

if anyone has any ideas, even to say that this is ok i would be extremly grateful for any feedback.

Thanks,

Rob
Reply With Quote
  #2 (permalink)  
Old 11-20-03, 23:21
orababa@kshema orababa@kshema is offline
Registered User
 
Join Date: Nov 2003
Location: Bangalore,India
Posts: 51
A Table like this....


Country Id,
Resort Id,
News ID

is just fine. IF you really wish to have a table which is FUTURE Proof then have a table like
SECTION_ID
SOME_SECTION ->(It could take values like Resort,country...whaterver)

and in the transaction table
NEWSID
SECTION_ID (references previous table)

Cheers..........
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On