I am having a problem when entering data and I need to leave some fields blank. This is my SQL statement:
strSQL = "INSERT INTO Order (Cust_ID, Size, Class, Manufacturer, Model, Comments) VALUES ('" & [cbcustid] & "','" & [cbsize] & "','" & [cbclass] & "','" & [cbmanufacturer] & "','" & [cbmodel] & "','" & [cmbcomments] & "')"
DoCmd.RunSQL strSQL
I usually have information in all fields, but when I leave one blank my insert statement will not work and the record does not enter. Is there a way to get around this? I'm not sure of any blank default values that will pass to make the statement work.
strSQL = "INSERT INTO Order (Cust_ID, Size, Class, Manufacturer, Model, Comments) VALUES ('" & [cbcustid] & "','" & [cbsize] & "','" & [cbclass] & "','" & [cbmanufacturer] & "','" & [cbmodel] & "','" & [cmbcomments] & "')"
DoCmd.RunSQL strSQL
I usually have information in all fields, but when I leave one blank my insert statement will not work and the record does not enter. Is there a way to get around this? I'm not sure of any blank default values that will pass to make the statement work.