Jump to content

Structure for outputing "News" from two tables


fluidsharp

Recommended Posts

Hi all,

 

I have two tables: article and records (haven't create but will be same as article)

article:

+-------------+------------- ----+------+-----+---------+----------------+

| Field          | Type              | Null | Key | Default | Extra          |

+-------------+------------------+------+-----+---------+----------------+

| id              | int(11)          | NO  | PRI | NULL    | auto_increment |

| title          | varchar(255) | NO  |    | NULL      |                |

| description | text              | NO  |    | NULL      |                |

| article      | text              | NO  |    | NULL      |                |

| review      | int(11)          | NO  |    | NULL      |                |

| author      | varchar(255) | YES  |    | NULL      |                |

| date        | date              | NO  |    | NULL      |                |

 

 

So I must output data (news) from both tables and result should be ordered by date.

 

First idea putted all in one table but it is so stupid.

Second is creating some intermediary table but how I haven't imagined yet.

 

Thank you in advance!

 

 

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.