obtain current date and time to post to database (Full Version)

All Forums >> [Web Development] >> Microsoft FrontPage Help



Message


mstumpo -> obtain current date and time to post to database (2/5/2008 14:22:01)

I am creating a sign in/out site and need to obtain the current date and time so that when the record is updated, it will display the date and time the record was updated in the DRW table.




rdouglass -> RE: obtain current date and time to post to database (2/5/2008 14:38:16)

In ASP you can use the Date() function for the date or the Now() function for the date and time as in:

fp_sQry = "UPDATE myTable SET TheDateRecordUpdatedField = #" & Date() & "# WHERE .....

That help any? (That's an example for Access DBs)




mstumpo -> RE: obtain current date and time to post to database (2/5/2008 19:09:54)

OK, so the code goes in the edit.asp page or the update.asp page generated by the DIW?




rdouglass -> RE: obtain current date and time to post to database (2/6/2008 8:45:55)

The code goes on the page that actually runs the update script. The query should definitely be using the UPDATE syntax. Which page it actually is on, I don't know.

I haven't used the DRW / DIW in quite some time now so I can't be sure but you probably will need to do some Spooky Diet'ing on the DIW. Hope it helps.




Page: [1]

Valid CSS!




Forum Software © ASPPlayground.NET Advanced Edition 2.4.5 ANSI
0.046875