[thelist] <cfpop> and date formating

rudy limeback r937 at interlog.com
Tue Jul 18 08:11:19 CDT 2000


hi aaron

re: inserting a date into a database -- why go to all the trouble of
converting an external date into a format the database will accept, why not
just ask the database to use its date

instead of passing in the cf server's date

    insert into thetable values ( ...   #Now()# ... )

just use

   insert into thetable values ( ...  current date  ... )

obviously, the reserved word "current date" will vary from database to
database, so you gotta look it up

in ms access, it's Date()

also, you may be off by a few seconds in a timestamp if what you're
capturing is a user event, but in one sense, using the database's timestamp
is better, because the event didn't happen unless/until it's logged in the
database


rudy.limeback
r937.com
evolt.org












More information about the thelist mailing list