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 > Database Server Software > MySQL > Best approach to relating databases or tables?

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 02-08-10, 05:23
jayp jayp is offline
Registered User
 
Join Date: Feb 2010
Posts: 1
Best approach to relating databases or tables?

Hello everyone,

How are all you fellow programmers on this fine "Monday" morning?

I wonder if anyone can help with a database dilemma that I am having please?

DB: MySQL 5
Platform: Ubuntu

I would really appreciate some advice on the correct avenue to take with a project I am working on.

What I have:
*I have a database that maintains a large table of articles. (similar to wordpress).
*I intend to relate a given article to another set of data. This set of data will be fairly huge.
*There maybe various sets of data that will be related.

The query:
* Is it better to contain these various large sets of data within the same database of articles, which will have a large set of traffic on it.
OR
* Is it better to create different databases (on the same server) that relate by a primary key to the main database with the articles.



I didn't want to plough ahead with this without getting some advice or opinion from the community.

I really appreciate anyone who takes the time to offer some thought on the matter.

Many thanks
Jayp
Reply With Quote
  #2 (permalink)  
Old 02-08-10, 08:24
r937 r937 is online now
SQL Consultant
 
Join Date: Apr 2002
Location: Toronto, Canada
Posts: 19,524
i would leave them in the same database

i'm not sure you can even declare a foreign key across databases -- you might want to set up a quick test to confirm/deny this
__________________
r937.com | rudy.ca
please visit Simply SQL and buy my book
Reply With Quote
Reply

Tags
database, mysql, relation, relationships, tables

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