errore layer postgis-pmapper

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

errore layer postgis-pmapper

Andrea Rosina

ciao a tutti
forse mi sto perdendo in un bicchiere d'acqua
Sto sistemando un map file di pmapper, ma non riesco a visualizzare layer da
postigs
questro è il pezzo del mapfile
#
# Start of Layer laguna
#
LAYER
  NAME "barene"
  TYPE polygon
  STATUS DEFAULT  
  CONNECTIONTYPE postgis
        CONNECTION "user=postgres password=pve_admin dbname=mapfish host=localhost
port=5432"
  DATA "the_geom FROM barene_art USING UNIQUE id USING SRID=3004"
  TRANSPARENCY 30
  METADATA
    "DESCRIPTION" "barene"
    "RESULT_FIELDS" "nome"
    "RESULT_HEADERS" "Name"
  END  # Metadata
  CLASS
    Name 'barene'
    COLOR 115 110 199
    OUTLINECOLOR 0 0 0
    TEMPLATE void
  END  # Class
END  # Layer

mentre questo è l'errore che mi da
[20-Jul-2009 17:03:03] PHP Warning:  [MapServer Error]:
msPOSTGISLayerWhichShapes(): Error executing POSTGIS SQL statement (in FETCH
ALL): DECLARE mycursor BINARY CURSOR FOR SELECT
asbinary(force_collection(force_2d(the_geom)),'NDR'),id::text from
barene_art WHERE the_geom && setSRID('BOX3D(2279491.14294331
5006880,2351118.8570567 5050065)'::BOX3D, 3004 )
-ERROR:  Operation on two geometries with different SRIDs


 in C:\ms4w\apps\pmapper-3.1-beta4\incphp\map.php on line 316
[20-Jul-2009 17:03:03] PHP Fatal error:  Call to a member function
saveImage() on a non-object in
C:\ms4w\apps\pmapper-3.1-beta4\incphp\common.php on line 244

soluzioni?
Il layer viene caricato correttamente da vari gis e la geometry columns in
postgis è corretta
ciao e grazie

--
View this message in context: http://www.nabble.com/errore-layer-postgis-pmapper-tp24571690p24571690.html
Sent from the Gfoss mailing list archive at Nabble.com.

_______________________________________________
Iscriviti all'associazione GFOSS.it: http://www.gfoss.it/drupal/iscrizione
[hidden email]
http://lists.faunalia.it/cgi-bin/mailman/listinfo/gfoss
Questa e' una lista di discussione pubblica aperta a tutti.
I messaggi di questa lista non rispecchiano necessariamente
le posizioni dell'Associazione GFOSS.it.
Reply | Threaded
Open this post in threaded view
|

Re: errore layer postgis-pmapper

Niccolo Rigacci-4
On Mon, Jul 20, 2009 at 08:12:44AM -0700, Andrea R wrote:
>
> ciao a tutti
> forse mi sto perdendo in un bicchiere d'acqua
>
> DECLARE mycursor BINARY CURSOR FOR SELECT
> asbinary(force_collection(force_2d(the_geom)),'NDR'),id::text from
> barene_art WHERE the_geom && setSRID('BOX3D(2279491.14294331
> 5006880,2351118.8570567 5050065)'::BOX3D, 3004 )
> -ERROR:  Operation on two geometries with different SRIDs

La query sul DB fallisce per via dello SRID differente.
Tu fai la query forzando SRID = 3004, ma la tabella che
SRID usa?

--
Niccolo Rigacci
Firenze - Italy
_______________________________________________
Iscriviti all'associazione GFOSS.it: http://www.gfoss.it/drupal/iscrizione
[hidden email]
http://lists.faunalia.it/cgi-bin/mailman/listinfo/gfoss
Questa e' una lista di discussione pubblica aperta a tutti.
I messaggi di questa lista non rispecchiano necessariamente
le posizioni dell'Associazione GFOSS.it.
Reply | Threaded
Open this post in threaded view
|

Re: errore layer postgis-pmapper

Andrea Rosina

Infatti lo strano del messaggio d'errore è che nella
tabella geometry columns in postgis lo srid associato è il 3004
ora provo a reimportarlo e vi so dire


Niccolo Rigacci-3 wrote:

>
> On Mon, Jul 20, 2009 at 08:12:44AM -0700, Andrea R wrote:
>>
>> ciao a tutti
>> forse mi sto perdendo in un bicchiere d'acqua
>>
>> DECLARE mycursor BINARY CURSOR FOR SELECT
>> asbinary(force_collection(force_2d(the_geom)),'NDR'),id::text from
>> barene_art WHERE the_geom && setSRID('BOX3D(2279491.14294331
>> 5006880,2351118.8570567 5050065)'::BOX3D, 3004 )
>> -ERROR:  Operation on two geometries with different SRIDs
>
> La query sul DB fallisce per via dello SRID differente.
> Tu fai la query forzando SRID = 3004, ma la tabella che
> SRID usa?
>
> --
> Niccolo Rigacci
> Firenze - Italy
> _______________________________________________
> Iscriviti all'associazione GFOSS.it: http://www.gfoss.it/drupal/iscrizione
> [hidden email]
> http://lists.faunalia.it/cgi-bin/mailman/listinfo/gfoss
> Questa e' una lista di discussione pubblica aperta a tutti.
> I messaggi di questa lista non rispecchiano necessariamente
> le posizioni dell'Associazione GFOSS.it.
>
>

--
View this message in context: http://www.nabble.com/errore-layer-postgis-pmapper-tp24571690p24582832.html
Sent from the Gfoss mailing list archive at Nabble.com.

_______________________________________________
Iscriviti all'associazione GFOSS.it: http://www.gfoss.it/drupal/iscrizione
[hidden email]
http://lists.faunalia.it/cgi-bin/mailman/listinfo/gfoss
Questa e' una lista di discussione pubblica aperta a tutti.
I messaggi di questa lista non rispecchiano necessariamente
le posizioni dell'Associazione GFOSS.it.
Reply | Threaded
Open this post in threaded view
|

Re: errore layer postgis-pmapper

Andrea Rosina
In reply to this post by Andrea Rosina

tutto ok
ho reimportato in postgis con qgis lo shape stando attento ad assegnare i
corretti srid e funziona
grazie lo stesso


Andrea R wrote:

>
> ciao a tutti
> forse mi sto perdendo in un bicchiere d'acqua
> Sto sistemando un map file di pmapper, ma non riesco a visualizzare layer
> da postigs
> questro è il pezzo del mapfile
> #
> # Start of Layer laguna
> #
> LAYER
>   NAME "barene"
>   TYPE polygon
>   STATUS DEFAULT  
>   CONNECTIONTYPE postgis
> CONNECTION "user=postgres password=pve_admin dbname=mapfish
> host=localhost port=5432"
>   DATA "the_geom FROM barene_art USING UNIQUE id USING SRID=3004"
>   TRANSPARENCY 30
>   METADATA
>     "DESCRIPTION" "barene"
>     "RESULT_FIELDS" "nome"
>     "RESULT_HEADERS" "Name"
>   END  # Metadata
>   CLASS
>     Name 'barene'
>     COLOR 115 110 199
>     OUTLINECOLOR 0 0 0
>     TEMPLATE void
>   END  # Class
> END  # Layer
>
> mentre questo è l'errore che mi da
> [20-Jul-2009 17:03:03] PHP Warning:  [MapServer Error]:
> msPOSTGISLayerWhichShapes(): Error executing POSTGIS SQL statement (in
> FETCH ALL): DECLARE mycursor BINARY CURSOR FOR SELECT
> asbinary(force_collection(force_2d(the_geom)),'NDR'),id::text from
> barene_art WHERE the_geom && setSRID('BOX3D(2279491.14294331
> 5006880,2351118.8570567 5050065)'::BOX3D, 3004 )
> -ERROR:  Operation on two geometries with different SRIDs
>
>
>  in C:\ms4w\apps\pmapper-3.1-beta4\incphp\map.php on line 316
> [20-Jul-2009 17:03:03] PHP Fatal error:  Call to a member function
> saveImage() on a non-object in
> C:\ms4w\apps\pmapper-3.1-beta4\incphp\common.php on line 244
>
> soluzioni?
> Il layer viene caricato correttamente da vari gis e la geometry columns in
> postgis è corretta
> ciao e grazie
>
>

--
View this message in context: http://www.nabble.com/errore-layer-postgis-pmapper-tp24571690p24582896.html
Sent from the Gfoss mailing list archive at Nabble.com.

_______________________________________________
Iscriviti all'associazione GFOSS.it: http://www.gfoss.it/drupal/iscrizione
[hidden email]
http://lists.faunalia.it/cgi-bin/mailman/listinfo/gfoss
Questa e' una lista di discussione pubblica aperta a tutti.
I messaggi di questa lista non rispecchiano necessariamente
le posizioni dell'Associazione GFOSS.it.