[Date Prev][Date Next][Thread Prev][Thread Next][Interchange by date
][Interchange by thread
]
[ic] Column-names part II
"Rene Hertell" <interchange-users@hertell.com> writes:
> > This is basic programming -- you always use arrays. We could build our
> > own array with pointers, but you can even get help from DBI and IC with
> > a hash query type...
> >
> > [perl]
> > my $db = $Db{query};
> > my $q = 'select * from address';
> > my $ary = $db->query( { sql => $q, hashref => 1 });
> > defined $ary
> > or die errmsg("query error for %s!", $q);
> >
> > my @out;
> > foreach my $row (@$ary) {
> > push @out, "Address for $row->{code} is $row->{address}";
> > }
> > return join "<br>", @out;
> > [/perl]
>
> Sorry to bother you again, but I get an error in the catalogs error.log:
> Safe: Can't call method "query" on an undefined value at (eval 181) line 4
[perl tables=address]
>
> I tried to add query to SafeUntrap, but then I couldn't get IC to start...
>
Forget that ...
Ciao
Racke
--
Prolific Interchange Consulting (Excellent German Quality !).
Take a look at Materialboerse (http://www.materialboerse.de/), WITT
(http://www.witt-weiden.de/), Boxmover (http://shop.boxmover.ch/) or
Passionshop (http://www.passionshop.com/racke). Need a shop ? Contact us.