Link to home
Create AccountLog in
Avatar of rgb192
rgb192Flag for United States of America

asked on

mysql want to put NULL for an int value

SQL query:

INSERT INTO  schedule(

ROW ,
col,
event_id,
checked,
user_id,
schedule_time
)
VALUES ( 0, 2, 1, 1, NULL , '2012-11-18 00:00:00' )

MySQL said: Documentation
#1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '(row,col,event_id,checked,user_id,schedule_time) values (0,2,1,1,NULL,'2012-11-1' at line 1



int  columns which allow null
datetime schedule_time



do not want to user_id int omit column from column list
ASKER CERTIFIED SOLUTION
Avatar of johanntagle
johanntagle
Flag of Philippines image

Link to home
membership
Create an account to see this answer
Signing up is free. No credit card required.
Create Account
Avatar of rgb192

ASKER

thanks