Hi
I am trying to write an insert statement and have a form with many dates on it.
Not all dates need to be filled in,but when I try to add a record to the database when all the date fields
are empty I an getting a syntax error.
In my table, I have created the date fields as follows (1 sample, I have 8 date fields on form)
......
row1_insltr VARCHAR(4),
row1_addl_ins VARCHAR(4),
row1_policy_number VARCHAR (20),
row1_policy_effective_date DATE DEFAULT NULL,
row1_policy_expiration_date DATE DEFAULT NULL
then when I go to get the date field, ex ample below:
$sR1_Eff_Date = $_POST["R1_Eff_Date"];
$sR1_Exp_Date = $_POST["R1_Exp_Date"];
and the all the date fields are not completed, the sql execution does not work