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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Date and Time Formatting together?

Status
Not open for further replies.

ApexSys

Programmer
Jan 10, 2001
15
US
What's the best way to work with a complete date/time field in Access?

Is there a common or standard way to pull a date/time field out of the DB, display it with a date and time formatting functions () and then insert it back into the DB again?

Where does one use CreateODBCDateTime?

Thanks,
-=-=-=-=-=-=-=-=-=-=-=-=-=-
Apex Systems Consulting
e-Solutions for Small Business
 
You do not have to put out a date, display it and insert it again.
You only update a date if you need to change it.

Use CreateODBCDate when you initially insert a data into a database or update it.

e.g

insert in table(mydate)
values(#CreateODBCdate('jul/10/01')#)

Access requires dates be be in a timedate stamp format.

If you want to display a date in a specific format then use the DateFormat function.

Dateformat(mydate, 'mmm-dd-yyyy')

will display JUL-10-2001



Russ Michaels
russ@satachi.com
For my personal book recommendations visit
 
Set up access to use a date/time field probably with the Long date, default value "date()" then with cf/ output it as you please.


CFPROGRAMMER
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top