As your link suggests, Alexandre, there is no such function, but it
can be done w/ a regex pattern, which postgresql supports.
pramsey=# CREATE FUNCTION isnumeric(text) RETURNS boolean AS 'SELECT
$1 ~ ''^[0-9]+$'' ' LANGUAGE 'sql';
pramsey=# select isnumeric('this');
isnumeric
-----------
f
(1 row)
pramsey=# select isnumeric('34');
isnumeric
-----------
t
(1 row)
On Wed, Jun 10, 2009 at 8:21 AM, Alexandre Dube<[email protected]> wrote:
> Hi,
>
> Still searching for a solution... Any hint ?
>
> Alexandre
>
> Alexandre Dube wrote:
>>
>> Hi,
>>
>> I'm looking for an isnumeric() function in postgresql. I did a quick
>> research and only found this :
>>
>> http://archives.postgresql.org/pgsql-sql/2004-04/msg00336.php
>>
>> Is there still no such function in postgresql ?
>>
>
>
> --
> Alexandre Dubé
> Mapgears
> www.mapgears.com
>
> _______________________________________________
> postgis-users mailing list
> [email protected]
> http://postgis.refractions.net/mailman/listinfo/postgis-users
>
_______________________________________________
postgis-users mailing list
[email protected]
http://postgis.refractions.net/mailman/listinfo/postgis-users