In article <[EMAIL PROTECTED]>,
boyd <[EMAIL PROTECTED]> wrote:
> I'm pretty sure in 7.0 postgres, (but I may be wrong) you could insert
> directly from a perl script something like this:
>$time = time; # this gives epoch seconds
>$sql = "insert into m
gt; \n";
my $rows = $DBH->do($sql) or dienicely;
print "$rows rows affected\n";
}
$DBH = DBI->connect("dbi:Pg:dbname=boyd","","");
my $info = $DBH->get_info(17) .' '. $DBH->get_info(18);
$info =~ s/0//g; # the get_info add
e DBI call, etc.
When I tried the same script on 7.2, it would not take it. I think I
once found another way to do it in 7.2. Of course, I can create a
formatted string in perl that will be accepted by the insert, but it
seems inefficient to have to do it through strings.
Boyd tbmooreA
|
ipf30 | integer |
select date_part ( 'doy',time ) as jday, max ( time ) from sis group by jday
(doy means day of year, which I called jday)
Boyd
---(end of broadcast)---
TIP 5: Have you checked our extensive FAQ?
http://www.postgresql.org/docs/faqs/FAQ.html