"Allen, Anthony" wrote:
>
> Can anyone help out! I have a table with a column that I want to make NOT
> NULL, There are over 475,000 records associated with this table. The
> column in the table was populated with the attribute of being NULL by
> default. I tried to do the following SQL command but it went for over 15
> hours and never completed the task so I killed the process.
>
> ALTER TABLE tablename
> MODIFY column_name
> varchar(255) NOT NULL;
>
> Can someone tell me if this is not the best way to do this. I want to keep
> the integrity of the record info in that column but I just want the default
> to be NOT NULL.
>
> Thanks anyone for a response.
> Tony
Hi Tony
I assume you have a lot of indexes on this table.
You should drop dem first.
Then modify your table specification.
After that add your indexes again.
Tschau
Christian