i have a simple form that adds simple text fields to a db to be viewed on another page.
but my question: whats the best way to go around getting getting the date?
so how can you use asp to get the server date and time? and whats the best way to put this in the db
im using an access db
The following will return the current date according to the server.
Yep, its that simple.
MS Access stores dates as a number in the background but will automatically format the entered date for you. So, use a date/time field in your database.
Use an SQL query to insert the data.
INSERT INTO tableName (yourDateField) VALUES ('" & Date & "');"
you could also just add a timestamp field to your database so anytime a record is added to it the database puts the timestamp in
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)