Re: Global Changes With Loop To Allow Nulls In A Table...
| From: | Jay Moore | Date: | Tue, 27 Jan 2009 17:06:52 +0000 |
| Subject: | Re: Global Changes With Loop To Allow Nulls In A Table... | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-287219@lists.php.net to get a copy of this message | ||
revDAVE wrote:
Hi Folks, Newbie question.... I have a mysql table with 100 fields, currently all do not allow nulls. Rather than hand typing in phpMyAdmin, I would like a way to loop through all fields and update them to allow nulls....First I would DESCRIBE the table so you get a list of column names and attributes. Then I would go thru each column and CHANGE it so it has the same attributes, adding the NULL flag if necessary. There may be an easier way however. Jay