Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 728281
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 14, 20262026-05-14T06:39:49+00:00 2026-05-14T06:39:49+00:00

I have a games table which holds the data about a game. Then another

  • 0

I have a games table which holds the data about a game.
Then another table which holds the data about news.

So far so good.

First I thought about creating a junction table for game_news so I could relate news to games.

This way works as intended when the game exists. So whenever I insert a news I can relate it to a game using the junction table.

However there are cases when there is news about game but the game isn’t published and it doesn’t exists.

So my question would be; is there a way to relate these news to a particular game when the game record is created.

What is the best way to do this? Any ideas?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-14T06:39:50+00:00Added an answer on May 14, 2026 at 6:39 am

    The junction table is the way to go. If a news article is about more than one game, then you need it. To handle games that do not exist yet, just insert a row for them, include all the info you currently know about it (possibly from the news article) and have a status column that marks it as not released yet. You can display this game as not released yet or rumor, etc.

    set the tables up something like this:

    Games
    GameID           int          not null auto increment PK
    GameStatus       char(1)      not null "P"=published, "N"=not released yet, "R"=game is only a rumor
    GameReleaseDate  date         null
    GameName         varchar(...) not null
    GameDescription...
    ...
    
    News
    NewsID      int               not null auto increment PK
    NewsTitle   varchar(...)      not null
    ...
    
    GameNews
    GameNewsID  int auto increment PK
    GameID      int FK to Games.GameID
    NewsID      int FK to News.NewsID
    

    With this setup you can have multiple games related to a single News item. Just insert all the proper GameNews rows to link each game to the News row.

    If a game has not been published yet, you can still link it to news by creating the Games row with the status “N” or “R” (or something like that) and using the GameNews table just as you would for a published game. You could populate all the fields within Games with as much info as possible and update it as you find out more. in the end you would have complete game info in the Games row (after the game is published) and it would link to the all the News rows, even when it was just a rumor in the news.

    To give you an idea about what I’m talking about, here is a sample of what the data for a “rumored” game would look like over time (this is a simplified example and without multiple Games per News rows):

    data as of 1/1/2010
        Games    GameID  GameStatus  GameReleaseDate  GameName
                 1234    "R"         1/1/2012         "God of War 4"
        News     NewsID  NewsTitle
                 543     "Future Of Games"
        GameNews GameNewsID  GameID  NewsID
                 768         1234    543
    
    data as of 4/1/2010
        Games    GameID  GameStatus  GameReleaseDate  GameName
                 1234    "R"         1/1/2012         "God of War 4"
        News     NewsID  NewsTitle
                 543     "Future Of Games"
                 544     "Interview with John Hight"
        GameNews GameNewsID  GameID  NewsID
                 768         1234    543
                 769         1234    544
    
    data as of 11/20/2010
        Games    GameID  GameStatus  GameReleaseDate  GameName
                 1234    "N"         12/31/2011         "God of War IV"
        News     NewsID  NewsTitle
                 543     "Future Of Games"
                 544     "Interview with John Hight"
                 545     "God of War Expected Next Year"
        GameNews GameNewsID  GameID  NewsID
                 768         1234    543
                 769         1234    544
                 770         1234    545
    
    data as of 8/15/2011
        Games    GameID  GameStatus  GameReleaseDate  GameName
                 1234    "N"         12/01/2011         "God of War IV"
        News     NewsID  NewsTitle
                 543     "Future Of Games"
                 544     "Interview with John Hight"
                 545     "God of War Expected Next Year"
                 546     "Retailers Get Ready For New Games"
        GameNews GameNewsID  GameID  NewsID
                 768         1234    543
                 769         1234    544
                 770         1234    545
                 771         1234    546
    
    data as of 1/1/2012
        Games    GameID  GameStatus  GameReleaseDate  GameName
                 1234    "P"         12/01/2011         "God of War IV"
        News     NewsID  NewsTitle
                 543     "Future Of Games"
                 544     "Interview with John Hight"
                 545     "God of War Expected Next Year"
                 546     "Retailers Get Ready For New Games"
                 547     "God of War IV Review"
        GameNews GameNewsID  GameID  NewsID
                 768         1234    543
                 769         1234    544
                 770         1234    545
                 771         1234    546
                 772         1234    547
    

    if on 1/1/2012 you were to look at News.NewsID=543 you would see that it links to the complete and reviewed Games.GameID=1234, even though the News.NewsID=543 article is about a “rumored” upcoming version of God of War. And all this was done without making any changes to the old News or GameNews rows.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a table that holds information about cities in a game, you can
I have one table GAMES and another PLAYERS . Currently each game has a
I have a table containing the results of games played. I have another table
I have a table of games, which is described as follows: +---------------+-------------+------+-----+---------+----------------+ | Field
I have a two player game which stores scores in a table. I want
I have a table that holds stats for a game, this table will have
I have a games table which contains player_id and player_action . player_id | player_action
I have some tables that contain data about players and the games they have
I have a table of 'games' with a different entry for each game like
I am trying to code a global lookup table of sorts. I have game

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.