On 2012-03-20 08:24:36 -0400, John Scoles wrote: > > Ran into that one, or nearly like it, a while back. Was not able to find a > OCI/DBD solution so I just modified my code like this > > $sth->execute_array({},\ @undefs, \@undefs, \@data_ids, \@set_ids, $ct_none); > > so I had an array for each param
That was the first workaround I tried. Unfortunately it didn't help. The workaround we use now (well, one could argue that it is actually clearer than the original code) is that we omit columns which aren't needed. So in this in this case we have: my $sth = $dbh->prepare_cached("insert into $table(data_id, set_id, coordtype) values(?, ?, ? )"); $sth->execute_array({}, undef, undef, $data_ids, \@set_ids, $ct_none); instead of my $sth = $dbh->prepare_cached("insert into $table(period_start, period_end, data_id, set_id, coordtype) values(?, ?, ?, ?, ? )"); $sth->execute_array({}, undef, undef, $data_ids, \@set_ids, $ct_none); (One interesting thing is that $ct_none is also undef, but that doesn't seem to be a problem). hp -- _ | Peter J. Holzer | Auf jedem Computer sollte der Satz Ludwigs II |_|_) | Sysadmin WSR | eingeprägt stehen: "Ein ewig Rätsel will ich | | | h...@wsr.ac.at | bleiben, mir und andern." __/ | http://www.hjp.at/ | -- Wolfram Heinrich in desd
signature.asc
Description: Digital signature