date and time

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have two text fields that indicate the date (yyyymmdd) and time (hhnnss) of
a record. Note that the time data some times has 6 or 5 characters. For
example:
ONCRDT ONCRTM
20060731 144812
20060731 144812
20060731 152532
20060731 152532
20060901 92558
20060901 93445
20060901 92717
20060901 101744
How do I combine the two fields into one so that the format is "mm/dd/yy
hh:nn:ss" or any other format that can then be recognized and used by Access?
 
ty said:
I have two text fields that indicate the date (yyyymmdd) and time
(hhnnss) of a record. Note that the time data some times has 6 or 5
characters. For example:
ONCRDT ONCRTM
20060731 144812
20060731 144812
20060731 152532
20060731 152532
20060901 92558
20060901 93445
20060901 92717
20060901 101744
How do I combine the two fields into one so that the format is
"mm/dd/yy hh:nn:ss" or any other format that can then be recognized
and used by Access?

=CDate(Format([ONCRDT], "0000-00-00") & " " & Format([ONCRTM], "00:00:00"))
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Back
Top