chris.gruber:
Alternatively to avoid using any functions, and use the date_order option.set option date_order=‘dmy’;
I am using “set option date_order=‘mdy’” and it is working perfectly [thank you]. However, when the date column is empty an error message appears saying “Cannot convert to a timestamp”, with an option to Continue or Stop. If I continue the record is skipped and the records containing dates are imported.
I would like the records without dates in the date column to also be imported. How can this be accomplished?
The import is being done by executing a bat file that contains:
dbisql -c "eng=contacts;dbn=contacts;uid=useridhere;pwd=passwordhere" -host localhost Expirations.sql
which calls the following Expirations.sql file:
set option date_order='mdy';
INPUT INTO "DBA"."policies"
FROM Expirations.csv
FORMAT ASCII
DELIMITED BY ','
(date_expires,policy_company,policy_description);
Dean Westover
Choices Software, Inc.