[postgis-users] Insert geometry (error) using PL-SQL

Rosangela Silva rosangela.silva at zenitpolar.com.br
Mon Apr 28 10:05:22 PDT 2003


Hi list,

I'm trying do insert some lines into a spatial table and I don't know how to do it,
Please, what's wrong ??

    My code is: 
     poligono := 'POLYGON(('||x1||' '||y1||','||x2||' '||y1||','||x2||' '||y2||','||x1||' '||y2||','||x1||' '||y1||'))';
     INSERT INTO sp VALUES (geoid,nome,GeometryFromText(poligono,-1));

    The error message is : 
    ERROR:  Function geometryfromtext(character varying, integer) does not exist
     Unable to identify a function that satisfies the given argument types
     You may need to add explicit typecasts

    geoid, nome, x1,y1,x2,y2 are variables of my function

 Thanks,

Rosangela
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20030428/47f7c28c/attachment.html>


More information about the postgis-users mailing list