[postgis-users] msPOSTGISLayerRetrievePK

Geodata Analysis info at e-geodata.gr
Thu Sep 22 00:03:12 PDT 2005


Hi List, I have posted the following to the mapservers user list but no 
one was able to answer  :-)
I'm using mapserver 4.6.1, postgis 1.0.3-1,  ms4w and php/mapscript.
I have a postgis layer with gid as primary key. The layer is drawn
correctly and i can acces its shapes via $shp = $layer->getShape(-1, 1).
After that i create a new layer. The new layer is the same with the one
described, except that its data come from :
$layer->set("data", "the_geom from (SELECT * FROM 'mylayerhere' WHERE
gid IN(1,2,3) as foo using unique gid using srid='mysridhere'"
The layer is drawn correctly. The problem is that when i try to access
its features via $shp = $layer->getShape(-1, 1) , i get a boolean value
(false)in $shp. It seems like the layer has no features although they
are drawn correctly!
I also get the following errors from apache error log :
1) scalefactor = 0.0231914\r,
2) msPOSTGISLayerRetrievePK: field length = $imsPOSTGISLayerRetrievePK:
field length = $i

Has anyone experienced a similar problem ?
Does anyone have any idea why this is happening ?

Thanks in advance

-- 
Stathis Stergou
GIS Programmer
GeoDATA Analysis
Greece
www.geodata-analysis.gr







More information about the postgis-users mailing list