diego_de_lima has asked for the wisdom of the Perl Monks concerning the following question:

Hello all, not sure if it is postgres or a perl issue, but I´m having a weird behavior on the perl gethostbyname function call on plperlu running on postgresql 8.3.7, perl 5.10.0. Is simply returns "1" instead of the normal array of values.

Everything works fine on a postgres 8.2.x with perl 5.8.8. And, even stranger, gethostbyname works fine in the problematic server IF I run it outside postgresql (in the shell).

Using Fedora 10 on the problematic server.

Does any one have any idea of whats the problem with perl running inside postgresql 8.3.7?

Thanks!
  • Comment on postgres 8.3 plperlu gethostbyname weird behavior

Replies are listed 'Best First'.
Re: postgres 8.3 plperlu gethostbyname weird behavior
by bichonfrise74 (Vicar) on Sep 04, 2009 at 00:29 UTC
    Based on your description, it looks the problem is related to postgresql 8.3.7, because like you said perl works outside of the database.