From: | "Greg Sabino Mullane" <greg(at)turnstep(dot)com> |
---|---|
To: | pgsql-general(at)postgresql(dot)org |
Subject: | Re: determine client os |
Date: | 2011-06-13 12:31:57 |
Message-ID: | 84463a9312e08ce673dccca7422b823e@biglumber.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
-----BEGIN PGP SIGNED MESSAGE-----
Hash: RIPEMD160
> Yep, or you can use a PL/Python, PL/Perl or PL/Java function that makes
> the appropriate calls in that language. Any of these will probably
> require the use of the "untrusted" (superuser-only) version.
Nope, you can do this easily in trusted perl:
CREATE OR REPLACE FUNCTION findos()
RETURNS TEXT
LANGUAGE plperl
AS $$
return $^O;
$$;
SELECT findos();
findos
- --------
linux
- --
Greg Sabino Mullane greg(at)turnstep(dot)com
End Point Corporation http://www.endpoint.com/
PGP Key: 0x14964AC8 201106130831
http://biglumber.com/x/web?pk=2529DF6AB8F79407E94445B4BC9B906714964AC8
-----BEGIN PGP SIGNATURE-----
iEYEAREDAAYFAk32AykACgkQvJuQZxSWSsjA4ACfTAqEYCuNEBgbPizAsZ0CJVlI
TmAAnA73swdgs9eP252umOr+LE5SfNuw
=y07O
-----END PGP SIGNATURE-----
From | Date | Subject | |
---|---|---|---|
Next Message | hubert depesz lubaczewski | 2011-06-13 12:35:17 | Re: determine client os |
Previous Message | Craig Ringer | 2011-06-13 12:25:51 | Re: determine client os |