On 26-Oct-2001 I wrote: > I have inherited a database built by someone else who was apparently > very > stingy. :-) > > A primary key was set to 'tinyint(4)' limiting the number of records > to 128. > > I've tried: > > alter table my_data modify phyid mediumint unsigned DEFAULT "0"; > > ...but got: > > ERROR 1121: Column 'phyid' is used with UNIQUE or INDEX but is not > defined as NOT NULL >
Thanks to: Don Read <[EMAIL PROTECTED]> Stefan Hinz <[EMAIL PROTECTED]> Aleksandar Bradaric <[EMAIL PROTECTED]> All recommended essentially the same solution; here is Dan's: alter table my_data modify phyid mediumint unsigned NOT NULL DEFAULT "0"; -- Tim Evans | 5 Chestnut Court [EMAIL PROTECTED] | Owings Mills, MD 21117 http://www.tkevans.com/tkevans.html | (443) 394-3864 --------------------------------------------------------------------- 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
