Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Converting a datefield into a SQL recognised format?

Status
Not open for further replies.

ADW

Programmer
Jun 21, 2001
50
GB
Hello again, those who have read my previous threads may know that the majority of my work involves importing data from a unix system. The main problem that I have is with date fields. I have just read a thread mentioning ActiveX scripts to convert fields into a format recognized by SQL. Now the date field in the Unix system, I am told is stored as a textfield, does anyone have any idea what the code would be in an activexscript to convert this?

many thanks in advance
Tony.
 
Hi ADW,
You can use the covert function to accomplish this task.
The only thing is you must be aware of the format of the data i.e. the format (yyyymmdd or mmddyyyy or yyyy/mm/dd or e.t.c). Once you identify the format use the convert function to convert the data into a sql date datatype.

I hope this will move in right direction. If you have any further problem please give the format of the data also (some example data).
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top