> alter table hr-data set column Reason4leaving1 char(100)
I thought I knew - but I wanted to play safe. So I went to
http://mysql.com and entered alter table to the search box.
>From the results list I chose ALTER TABLE Syntax:
http://www.mysql.com/doc/A/L/ALTER_TABLE.html
Here I found what I
Hi,
I dont know whats wrong with my mysql but when I add a column with auto_inc
(I just copied and paseted what you did) I got: Primary key cannot be NULL,
so, but I got it working So thanks anyway.
And as I always say... If something works, dont touch int.
So I wont reinstall.
/roger
> my
On 21-Mar-01 roger westin wrote:
> Hi I solved it my self.
> If anyone whats to know the awnser to this it was NOT as easy as the manual
> would have described.
> The only thing I got to work was:
> 1. Drop the index
> 2. create new field (whitout index and auto_inc) if any of them where added
>
On 21-Mar-01 roger westin wrote:
> Hi there,
> Question:
> Whats the Easiest way to insert an AUTO_INCREMENT column into an existing
> table,
> the new field will take over the primary key and the index.
>
>
alter table da_table drop primary key, drop old_id;
alter table da_table add id int
Hi I solved it my self.
If anyone whats to know the awnser to this it was NOT as easy as the manual
would have described.
The only thing I got to work was:
1. Drop the index
2. create new field (whitout index and auto_inc) if any of them where added
I got an error and nothing worked.
3. make the n