Home > database >  Database insert a column, then insert the data according to the conditions
Database insert a column, then insert the data according to the conditions

Time:01-09

Now need to insert a list of new data in the database, the column of new data on the basis of the existing conditions is inserted into the

I test: the first step: the alter table table name add column int.
Step 2: Update the table name set column name='bill' where id='001'.
Write has a problem like this

CodePudding user response:

Step 1: insert the list of missing column
The alter table table name add column column int.

The second step: column is a new type int, unable to update the data as a string type 'bill';
  • Related