In article <[EMAIL PROTECTED]>, "Scott Fletcher" <[EMAIL PROTECTED]> writes:
> Sorry you didn't understand what's I'm asking for. It take some logical > thought to see the picture. Now I know I will have to enforce it with > the application code (PHP, HTML and JavaScript) with the current two > column model. Not necessarily. I didn't understand what you really want, but if it's uniqueness of all email addresses the answer is simple: create a separate table for them and use foreign keys. Something like that: CREATE TABLE emails ( id INT UNSIGNED NOT NULL AUTO_INCREMENT, email VARCHAR(255) BINARY NOT NULL, PRIMARY KEY (id), UNIQUE KEY (email) ); CREATE TABLE yourtable ( -- other columns email1 INT UNSIGNED NULL, email2 INT UNSIGNED NULL, KEY (email1), FOREIGN KEY (email1) REFERENCES emails, KEY (email2), FOREIGN KEY (email2) REFERENCES emails ); -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]