in reply to dbi fetchrow_array to access a timestamp
$dbh->do(q(ALTER SESSION SET NLS_DATE_FORMAT='YYYY-MM-DD HH24:MI:S +S'); $dbh->do(q(ALTER SESSION SET NLS_TIMESTAMP_FORMAT='YYYY-MM-DD HH24 +:MI:SSxFF'); $dbh->do(q(ALTER SESSION SET NLS_TIMESTAMP_TZ_FORMAT='YYYY-MM-DD H +H24:MI:SSxFF');
That would get you the date and time. If you just want the time, select some function of the datetime that just extracts the time, or do a simple s/.*\s// or something on the datetime returned.
Also, please wrap your code in <code></code> tags. And think about using placeholders and bind values in your SQL instead of injecting variables into your SQL. And no, I'm not going to email you.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: dbi fetchrow_array to access a timestamp
by kennethk (Abbot) on Aug 19, 2009 at 01:23 UTC |