If you have ESQL/C then you should install the
DBI & DBD for informix module. If not, then you could
try unloading to a named pipe, never tried it so I don't
know if it'll work, and then have the perl script read
from the pipe.
Hope that helps,
Douglas Wilson
On Wed, 5 Aug 1998 20:36:02 -0700, "Edward Villalovoz"
<edwardv@jps.net> wrote:
>Hi,
> Can anyone show me how to pass my sql results to an array in perl
>instead of UNLOADing them to a flat file, and then LOAD the array results
>into another informix table? Thanks in advance.
>
>
>#!/usr/local/bin/perl
>
> $hh = 12;
> $filename = "cool.txt";
> $ENV{INFORMIXSERVER} = "n36_shm";
> open DBACCESS, "| dbaccess" or die "Couldn't run dbaccess: $!; aborting";
>
> print DBACCESS qq{
> database pmsys\\@n36;
> UNLOAD TO '$filename' DELIMITER '|'
> SELECT ama_cfc
> FROM tblamah
> GROUP BY ama_direction, ama_cfc
> HAVING ama_direction = "$hh";> };
>
> close DBACCESS or die "Couldn't finish dbaccess: $!; aborting";
>
>
>
>