From: Dan Nelson Date: May 20 2002 5:36am Subject: Re: query - primary key List-Archive: http://lists.mysql.com/mysql/109536 Message-Id: <20020520053606.GM25559@dan.emsphone.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii In the last episode (May 20), Sameer Maggon said: > Hi, > I have a table with four colums > > id > date > time > addr - varchar (used my sql C API) > > I want that when i add an entry, the PRIMARY KEY IS ALL OF THEM > means that no entry should repeat. > > I used ALTER TABLE sss ADD PRIMARY KEY (all four field) > > but not when i add my things, after 104 items, it gives an > error, DUPLICATE ENTRY Paste in the full error message, and if you made 'id' a TINYINT AUTO_INCREMENT, think very very carefully about the rage of a TINYINT. -- Dan Nelson dnelson@stripped