Change the Data Type from text to date/time

  • Thread starter Thread starter vikash.verma
  • Start date Start date
V

vikash.verma

Hi All,
I have a table where the Data Type is to get converted frm TEXT to
DATE/TIME.
My requirment is , when i use the Import fn i call the query which changes
the data to the Date / Time format using DateSerial and TimeSerial but the
Data Type is still text .I want to convert this to Date/Time.Is there any
Update query which will do this work.

Hope to hear from you all soon,

Thanks nd Regards
Vikash
 
----- vikash.verma wrote: -----

Hi All,
I have a table where the Data Type is to get converted frm TEXT to
DATE/TIME.
My requirment is , when i use the Import fn i call the query which changes
the data to the Date / Time format using DateSerial and TimeSerial but the
Data Type is still text .I want to convert this to Date/Time.Is there any
Update query which will do this work.

Hope to hear from you all soon,

Thanks nd Regards
Vikash

I would suggest creating the table, empty, with the desired datatypes;
rather than importing into a new table, either import into the
existing empty table or (probably better) use File... Get External
Data... Link to link to the external file, and run an Append query to
move the data into your table.
 
Use the CDate conversion function. Will convert almost anything which looks
like a date in text to a Date/Time variable.

eg in a query

NewDate:CDate(TextDate)

--
Regards,

Adrian Jansen
J & K MicroSystems
Microcomputer solutions for industrial control
 
Back
Top