On 8/21/05 10:38 PM, [EMAIL PROTECTED] wrote:
> I'm using DBD:DB2.
> Maybe quatation (') rwapping data must be dropped, and
> "CURRENT TIMESTAMP" keyword will be treated.
>
> my @new_values = ();
> my @place_holders =
> map {
> if (/^CURRENT TIMESTAMP$/) {
> $_;
> } else {
> push @new_values => $_;
> "?";
> }
> } @args
> ;
I'm using Informix, which is apparently (and perhaps not surprisingly)
similar to DB2 in this regard. I had to do something similar to what you
describe above in my RDBMS-OO mapper module:
http://search.cpan.org/~jsiracusa/Rose-DB-Object-0.0692/lib/Rose/DB/Object/M
etadata.pm#allow_inline_column_values
It's a bit of a pain, but until DBD::Informix becomes "smart" enough to
detect this on its own (if that's even possible) it's something that has to
be handled by the programmer (or, in my case, by the programmer's library :)
-John