| Author: amit chaudhary 22 Aug 2008 | Member Level: Silver Points : 1 |
The number of fields in VALUES clause must match the number of columns specified in INSERT statement. If we supply less values than the specified columns in the INSERT Statement.
|
| Author: Nandy 28 Aug 2008 | Member Level: Silver Points : 1 |
you check the number of columns and values. example: INSERT INTO TableName(column1,column2,column3) VALUES('VALUE1','VALUE2','VALUE3')
|
| Author: Prafulla S Shimpi 29 Aug 2008 | Member Level: Gold Points : 2 |
Best way to avoid this to specify column and values eg:
Insert into Table1 (Column1, Column2, Column3, Column4, Column5, Column6) Values ( Value1, Value2, Value3, Value4, Value5, Value6)
This helps to match the values as well as takes value only against specified columns.
|