Primary key type question

wxdqz

New Member
Hi There,

I have a MySQL table, MYTABLE, with three columns...

id session pid

All the fields can store duplicates of the same info, except \'id\' and \'session\'. ie:

12 300 444
12 301 238
13 300 444
12 301 111


Notice that rows 2 and 4 have the same values for both \'id\' and \'session\'... I would like to make it so that this can\'t happen.

If someone could post a sql statement to help me out I would appreciate it.

Thanks,

-dr
 
Back
Top