|
Neohapsis is currently accepting applications for employment. For more information, please visit our website www.neohapsis.com or email hr@neohapsis.com |
Primary Key question
From: Haisam K. Ido (haisam
ido.org)
Date: Fri Jul 01 2005 - 09:04:01 CDT
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
I've created the following table (server 4.1 in win2k)
CREATE TABLE `os` (
`id` tinyint(10) NOT NULL auto_increment,
`name` varchar(255) NOT NULL default '',
`description` varchar(255) default NULL,
PRIMARY KEY (`id`,`name`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
and was very surprised that I can do the following twice. Should'nt
this be rejected since name is a primary key ad has already been used?
INSERT INTO os (name,description) VALUES ( 'winxp','winxp');
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]