Mark, can you provide a sample of a query you're currently using to
retrieve data from this table / joining on this table?

Also, how big is this table?  It may not be worth your time to change
things around as this is a very simple structure and should remain
speedy even if it grows pretty large.

Dan


On 8/10/06, Mark Donovan <[EMAIL PROTECTED]> wrote:
hello all this is my first post...I haven't been able to find a way
to half my table size through a primary key relationship that can
exist once.

If I want to relate "person1 (id = 44444)" to "person2 (id = 11111)"
I have have had good success with the following table below. However,
if it's possible, I'd love to half the table size...

Ideally the look-up table will contain one instance where "person1"
to "person2" exists.
Not two as demonstrated below...Any ideas...

CREATE TABLE `trak_Groups_Member` (
  `relation_id` int(11) unsigned NOT NULL default '0',
   `id` int(11) unsigned NOT NULL default '0',
   PRIMARY KEY  (`relation_id`,`id`),
) ENGINE=MyISAM;

INSERT INTO `trak_Groups_Member` VALUES (44444, 11111);
INSERT INTO `trak_Groups_Member` VALUES (11111, 44444);

Mark Donovan
www.gigtrak.com
Office: (303) 440-0666 x 228



--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]



--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to