On Tue, Jul 17, 2001 at 03:34:01PM -0500, John Hunter wrote:
> >>>>> "Paul" == Paul DuBois <[EMAIL PROTECTED]> writes:
>
>
> Paul> ALTER IGNORE this_table ADD PRIMARY KEY (name,time)
>
> They are not null so this works well with a slight modification:
>
> ALTER IGNORE TABLE this_table ADD PRIMARY KEY (name,time)
> ^
Oops! My mistake.
> One further question. Will this automatically keep my rows ordered by
> the primary key with future inserts?
Umm... no. It will prevent duplicate records from being created, but
you don't have any control over the order in which records are stored.
That's the server's job.
To retrieve records in the order you want to see them, always use ORDER BY.
>
> Thanks for your help,
> John Hunter
---------------------------------------------------------------------
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
http://lists.mysql.com/ (the list archive)
To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php