Re: [MapServer-users] getfeatureinfo works from mapserver but not via mapcache

2023-04-14 Thread Trygve Aspenes via MapServer-users
OK so I was a bit inaccurate. The time value comes from the default 
value in the mapcache xml tileset dimensions config,


I think this is happens here:

https://github.com/MapServer/mapcache/blob/main/lib/service_wms.c#L883-L893

and it looks to me if no value for the dimension is set then the default 
values us used. Seems OK, but why is not my time value not handled.


I guess I need some digging. Is the param and dimmension->name maybe 
case sensitive?


Trygve

Den 2023-04-14 15:51, skrev Trygve Aspenes via MapServer-users:

Hi mapserver users list

I have a mapserver with getfeatureinfo available. This seems to return
the correct value for the selected timestamp for the given layer when
used directly.

But when I try to reach the same info, ie. getfeatureinfo, from
mapcache a wrong timestamp is passed to mapserver and then the wrong
values are returned.

The request received by mapcache(as seen in the logs):
2023-04-14T13:34:20.304781696Z 172.16.16.234 - - [14/Apr/2023:13:34:20
+] "GET /okd-satellite
=WMS=GetFeatureInfo=1.1.1=ash_meteosat_0deg_LAYERS=ash_meteosat_0deg=EPSG%3A3857=-3396560.8725830186,6408480.4514,7422652.026383018,11520588.9031=1782=842=333=704=image/gif_FORMAT=text/html=&=2023-04-11T07%3A15%3A00Z

The request received by mapserver(as seen in the logs):
2023-04-14T13:34:20.303555611Z 172.16.2.224 - - [14/Apr/2023:13:34:20
+] "GET
/okd-satellite?VERSION=1.1.1=GetFeatureInfo=WMS==image%2fpng=ash_meteosat_0deg=%2fconfig%2fmapserver-products.map=-3396560.872583%2c6408480.451400%2c7422652.026383%2c11520588.903100=1782=842=EPSG%3a3857=333=704_FORMAT=text%2fhtml_LAYERS=ash_meteosat_0deg=2023-03-25T16%3a00%3a00Z
HTTP/1.1" 200 743 "-" "mod-mapcache/1.11dev"

So what happens. The mapcache request looks correct with
time=2023-04-11T07:15:00Z, then I guess this request is forwarded to
mapserver, but I think it is without the TIME parameter. Why I think
this is because the request I see in the mapserver logs has the
default time stamp as given in my mapfile.

Are there some configuration I'm missing? I had a look at
https://github.com/MapServer/mapcache/blob/main/mapcache.xml.sample#L753-L763
to see how getfeatureinfo should be configured, but no other
information. My mapcache source config looks like



http://?



image/png
ash_meteosat_0deg




text/html

ash_meteosat_0deg




Any hints are appreciated.

Trygve
___
MapServer-users mailing list
MapServer-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

___
MapServer-users mailing list
MapServer-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo layout in plain text

2016-11-10 Thread Schepers, Benjamin
Hi @all,

thank you for that inspiration, Steve! This shows how valuable this list is...
And sorry, Yves, for giving a wrong hint; but HTML-GFI within ArcGIS 10.2+ 
works, but be careful with embedded javascript and advanced css in 
html-template, ArcGIS doesn't like that much.

Some thoughts on the Template-thing from Steve/Daniel:
Regarding to Daniels reference to wms-server-documentation 
(http://mapserver.org/ogc/wms_server.html#how-does-a-wms-work), GFI-section:
"text/html output using MapServer query templates (see Templating) specified in 
the CLASS TEMPLATE parameter (the filename has to have an .html extension). The 
MIME type returned by the Class templates defaults to text/html and can be 
controlled using the metadata “wms_feature_info_mime_type”.

It looks like there's a "natural" binding between template and html output. As 
Daniel stated, this can be overridden with setting a other " 
wms_feature_info_mime_type" - OK so far.
For example someone would now be using the template for individual text-plain 
output-styling and setting " 'wms_feature_info_mime_type' 'text/plain' ", what 
happens then, if a user requests the FeatureInfo in text/html, which is from my 
point of view the typical format? Mapserver wouldn't produce a valid html 
response anymore (because of the lack of an valid html-template), would it?
Should GFI with HTML then be forbidden or are multiple templates for different 
outputformats possible? How would this work?

Maybe I didn't fully understand Steve's hint and one of you can explain?

Thanks a lot,

Ben

-Ursprüngliche Nachricht-
Von: mapserver-users [mailto:mapserver-users-boun...@lists.osgeo.org] Im 
Auftrag von Lime, Steve D (MNIT)
Gesendet: Donnerstag, 10. November 2016 19:51
An: Yves Jacolin; mapserver-users@lists.osgeo.org
Betreff: Re: [mapserver-users] GetFeatureInfo layout in plain text

This should be possible. Templates are not limited to HTML output, any text 
based format should be able to be created. You do this through output formats. 
Here's an example for plain text:

 OUTPUTFORMAT
NAME 'plain-text'
DRIVER 'TEMPLATE'
MIMETYPE 'text/plain'
FORMATOPTION "FILE=templates/plain.tmpl"
FORMATOPTION 'ATTACHMENT=myfile.txt'
  END

The template file's extension is really irrelevant to what's being delivered 
back to the client - the mimetype sets that. I don't recall of the top of my 
head how you expose this type via WMS but I think that's pretty straight 
forward.

Steve

-Original Message-
From: mapserver-users [mailto:mapserver-users-boun...@lists.osgeo.org] On 
Behalf Of Yves Jacolin
Sent: Thursday, November 10, 2016 4:16 AM
To: mapserver-users@lists.osgeo.org
Subject: [mapserver-users] GetFeatureInfo layout in plain text

Hello,

I have to setup a text format for a WMS' GetFeatureInfo service. I would like 
to know if it is possible to change the layout using a template.

My first test was not working so any feedback is welcome. The documentation 
said that the user should read the templating chapter so I guess this is 
possible.

Any confirmation?

Y.
--
Responsable Formation et Support
Camptocamp France SAS
Savoie Technolac, BP 352
73377 Le Bourget du Lac, Cedex
Tel (France) : +33 4 58 48 20 43 (new !) Tel (Suisse) : +41 21 619 10 43 Mob. : 
+33 6 18 75 42 21 Fax : 04 79 70 15 81 Mail : yves.jaco...@camptocamp.com 
http://www.camptocamp.com ___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] GetFeatureInfo layout in plain text

2016-11-10 Thread Daniel Morissette
To complement what Steve wrote, have a look at the 
wms_getfeatureinfo_formatlist in http://mapserver.org/ogc/wms_server.html


Daniel


On 2016-11-10 1:50 PM, Lime, Steve D (MNIT) wrote:

This should be possible. Templates are not limited to HTML output, any text 
based format should be able to be created. You do this through output formats. 
Here's an example for plain text:

 OUTPUTFORMAT
NAME 'plain-text'
DRIVER 'TEMPLATE'
MIMETYPE 'text/plain'
FORMATOPTION "FILE=templates/plain.tmpl"
FORMATOPTION 'ATTACHMENT=myfile.txt'
  END

The template file's extension is really irrelevant to what's being delivered 
back to the client - the mimetype sets that. I don't recall of the top of my 
head how you expose this type via WMS but I think that's pretty straight 
forward.

Steve

-Original Message-
From: mapserver-users [mailto:mapserver-users-boun...@lists.osgeo.org] On 
Behalf Of Yves Jacolin
Sent: Thursday, November 10, 2016 4:16 AM
To: mapserver-users@lists.osgeo.org
Subject: [mapserver-users] GetFeatureInfo layout in plain text

Hello,

I have to setup a text format for a WMS' GetFeatureInfo service. I would like
to know if it is possible to change the layout using a template.

My first test was not working so any feedback is welcome. The documentation
said that the user should read the templating chapter so I guess this is
possible.

Any confirmation?

Y.




--
Daniel Morissette
http://www.mapgears.com/
T: +1 418-696-5056 #201

http://evouala.com/ - Location Intelligence Made Easy
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] GetFeatureInfo layout in plain text

2016-11-10 Thread Lime, Steve D (MNIT)
This should be possible. Templates are not limited to HTML output, any text 
based format should be able to be created. You do this through output formats. 
Here's an example for plain text:

 OUTPUTFORMAT
NAME 'plain-text'
DRIVER 'TEMPLATE'
MIMETYPE 'text/plain'
FORMATOPTION "FILE=templates/plain.tmpl"
FORMATOPTION 'ATTACHMENT=myfile.txt'
  END

The template file's extension is really irrelevant to what's being delivered 
back to the client - the mimetype sets that. I don't recall of the top of my 
head how you expose this type via WMS but I think that's pretty straight 
forward.

Steve

-Original Message-
From: mapserver-users [mailto:mapserver-users-boun...@lists.osgeo.org] On 
Behalf Of Yves Jacolin
Sent: Thursday, November 10, 2016 4:16 AM
To: mapserver-users@lists.osgeo.org
Subject: [mapserver-users] GetFeatureInfo layout in plain text

Hello,

I have to setup a text format for a WMS' GetFeatureInfo service. I would like 
to know if it is possible to change the layout using a template.

My first test was not working so any feedback is welcome. The documentation 
said that the user should read the templating chapter so I guess this is 
possible.

Any confirmation?

Y.
-- 
Responsable Formation et Support
Camptocamp France SAS
Savoie Technolac, BP 352
73377 Le Bourget du Lac, Cedex
Tel (France) : +33 4 58 48 20 43 (new !)
Tel (Suisse) : +41 21 619 10 43
Mob. : +33 6 18 75 42 21
Fax : 04 79 70 15 81
Mail : yves.jaco...@camptocamp.com
http://www.camptocamp.com
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] GetFeatureInfo layout in plain text

2016-11-10 Thread Schepers, Benjamin
Hi Yves,



from my point of view this isn't possible, templating in mapserver-WMS just 
works for HTML.

You would need an wrapper-script, which does some postprocessing/transforming 
with GFI-response (text) from mapserver - could be done with 
bash/perl/python/php whatever, maybe mapscript-engine (I'm not into this) or 
within Apache-Webserver (mod_sed ;-) ).



Most structured way would be rewriting GFI-request from text-format to 
gml-format within the receiving webserver, directing this request to mapserver 
(which would create gml-response), directing mapserver-response to 
xml-processor and transform to whatever you want and then let webserver deliver 
the response to the client...



Edit:

Jörg was faster, because of having a phonecall from one of his coworkers ;-) 
and also my post was blocked by the mailing-list caused by an attachment ☹ 
,sorry, Jeff.

ArcGIS Desktop 10.x does show html-GFI, see attachment (image is clipped, it is 
a screenshot from within ArcGIS):

http://pasteboard.co/pANcOnMbD.jpg



Ben


Mit freundlichen Grüßen
Im Auftrag

Benjamin Schepers


Luftbild und Geoinformationssysteme
Kronprinzenstraße 6
45128 Essen
Fon: +49 201 2069-232
Fax: +49 201 2069-500
schep...@rvr-online.de

[cid:image001.jpg@01D23B71.BDC6EEC0]

Die Regionaldirektorin
Kronprinzenstraße 35
45128 Essen
Zentrale: +49 (0) 201 2069-0
Fax: +49 (0) 201 2069-500
www.metropoleruhr.de

Postfach 10 32 64
45032 Essen

Steuernummer: RVR 112/5797/0116
USt.-ldNr.: DE 173867500

Diese E-Mail koennte vertrauliche und/oder rechtlich geschuetzte Informationen 
enthalten.
Wenn Sie nicht der richtige Adressat sind oder diese E-Mail irrtuemlich 
erhalten haben, informieren Sie bitte sofort den Absender und vernichten Sie 
diese Mail.
Das unerlaubte Kopieren sowie die unbefugte Weitergabe dieser E-Mail sind nicht 
gestattet.
This e-mail may contain confidential and/or privileged information.
If you are not the intended recipient (or have received this e-mail in error) 
please notify the sender immediately and destroy this e-mail.
Any unauthorised copying, disclosure or distribution of the material in this 
e-mail is strictly forbidden.
Von: mapserver-users [mailto:mapserver-users-boun...@lists.osgeo.org] Im 
Auftrag von Yves Jacolin
Gesendet: Donnerstag, 10. November 2016 13:03
An: Jörg Thomsen (WhereGroup)
Cc: mapserver-users
Betreff: Re: [mapserver-users] GetFeatureInfo layout in plain text

humm, good point, I need to check the output request from ArcGIS. The users 
said that for other service they get a table, so probably an html format.
Thanks,
Y.

2016-11-10 12:59 GMT+01:00 Jörg Thomsen (WhereGroup) 
<joerg.thom...@wheregroup.com<mailto:joerg.thom...@wheregroup.com>>:
so, what do you have to style? Perhaps you could create a text-format
output with templates to create a sort of ascii-tables, you don't have
to use html-tags within the templates. But in this case the request has
to be format=text/html.

Jörg


Am 10.11.2016 um 12:39 schrieb Yves Jacolin:
> Thanks Jörg,
>
> Unfortunately I should use text format as ArcGIS desktop don't support other
> format (to be confirmed).
>
> Y.
> On Thursday, November 10, 2016 11:49:49 Jörg Thomsen wrote:
>> Hi Yves,
>>
>> text/plain is text/plain, no layout. The Mapserver-templates work with
>> html-format. Another way could be using the xml-output and styling it
>> with xslt. But you can enable the html-output using templates with
>> mapserver and it still will be possible to send text/plain requests.
>>
>> Templating ist easy and powerful, so to answer your question: yes, read
>> the templating chapter. You'll find a short introduction in the old
>> tutorial: http://demo.mapserver.org/tutorial/section3.html (example 3.1)
>>
>> Jörg
>>
>> Am 10.11.2016 um 11:16 schrieb Yves Jacolin:
>>> Hello,
>>>
>>> I have to setup a text format for a WMS' GetFeatureInfo service. I would
>>> like to know if it is possible to change the layout using a template.
>>>
>>> My first test was not working so any feedback is welcome. The
>>> documentation
>>> said that the user should read the templating chapter so I guess this is
>>> possible.
>>>
>>> Any confirmation?
>>>
>>> Y.
>>
>> Viele Grüße,
>> Jörg Thomsen
>


Viele Grüße,
Jörg Thomsen

--

Where2B Konferenz 2016
15. Dezember 2016 in Bonn
www.where2b-conference.com<http://www.where2b-conference.com>


---
Jörg Thomsen
WhereGroup GmbH & Co. KG
Gillweg 3
14193 Berlin
Germany

Fon: +49 (0)30 / 5130 278 74<tel:%2B49%20%280%2930%20%2F%205130%20278%2074>
Fax: +49 (0)30 / 89 09 53 11<tel:%2B49%20%280%2930%20%2F%2089%2009%2053%2011>

joerg.thom...@wheregroup.

Re: [mapserver-users] GetFeatureInfo layout in plain text

2016-11-10 Thread Yves Jacolin
humm, good point, I need to check the output request from ArcGIS. The users
said that for other service they get a table, so probably an html format.

Thanks,

Y.

2016-11-10 12:59 GMT+01:00 Jörg Thomsen (WhereGroup) <
joerg.thom...@wheregroup.com>:

> so, what do you have to style? Perhaps you could create a text-format
> output with templates to create a sort of ascii-tables, you don't have
> to use html-tags within the templates. But in this case the request has
> to be format=text/html.
>
> Jörg
>
>
> Am 10.11.2016 um 12:39 schrieb Yves Jacolin:
> > Thanks Jörg,
> >
> > Unfortunately I should use text format as ArcGIS desktop don't support
> other
> > format (to be confirmed).
> >
> > Y.
> > On Thursday, November 10, 2016 11:49:49 Jörg Thomsen wrote:
> >> Hi Yves,
> >>
> >> text/plain is text/plain, no layout. The Mapserver-templates work with
> >> html-format. Another way could be using the xml-output and styling it
> >> with xslt. But you can enable the html-output using templates with
> >> mapserver and it still will be possible to send text/plain requests.
> >>
> >> Templating ist easy and powerful, so to answer your question: yes, read
> >> the templating chapter. You'll find a short introduction in the old
> >> tutorial: http://demo.mapserver.org/tutorial/section3.html (example
> 3.1)
> >>
> >> Jörg
> >>
> >> Am 10.11.2016 um 11:16 schrieb Yves Jacolin:
> >>> Hello,
> >>>
> >>> I have to setup a text format for a WMS' GetFeatureInfo service. I
> would
> >>> like to know if it is possible to change the layout using a template.
> >>>
> >>> My first test was not working so any feedback is welcome. The
> >>> documentation
> >>> said that the user should read the templating chapter so I guess this
> is
> >>> possible.
> >>>
> >>> Any confirmation?
> >>>
> >>> Y.
> >>
> >> Viele Grüße,
> >> Jörg Thomsen
> >
>
>
> Viele Grüße,
> Jörg Thomsen
>
> --
>
> 
> Where2B Konferenz 2016
> 15. Dezember 2016 in Bonn
> www.where2b-conference.com
> 
>
> ---
> Jörg Thomsen
> WhereGroup GmbH & Co. KG
> Gillweg 3
> 14193 Berlin
> Germany
>
> Fon: +49 (0)30 / 5130 278 74
> Fax: +49 (0)30 / 89 09 53 11
>
> joerg.thom...@wheregroup.com
> www.wheregroup.com
> Amtsgericht Bonn, HRA 6788
> ---
> Komplementärin:
> WhereGroup Verwaltungs GmbH
> vertreten durch:
> Olaf Knopp, Peter Stamm
> ---
> Folgen Sie der WhereGroup auf twitter: http://twitter.com/WhereGroup_com
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>



-- 
Responsable Formation et Support
Camptocamp France SAS
Savoie Technolac, BP 352
73377 Le Bourget du Lac, Cedex

Tel (France) : +33 4 58 48 20 43 (new !)
Tel (Suisse) : +41 21 619 10 43
Mob. : +33 6 18 75 42 21
Fax : 04 79 70 15 81

Mail : yves.jaco...@camptocamp.com
http://www.camptocamp.com
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] GetFeatureInfo layout in plain text

2016-11-10 Thread WhereGroup
so, what do you have to style? Perhaps you could create a text-format
output with templates to create a sort of ascii-tables, you don't have
to use html-tags within the templates. But in this case the request has
to be format=text/html.

Jörg


Am 10.11.2016 um 12:39 schrieb Yves Jacolin:
> Thanks Jörg,
> 
> Unfortunately I should use text format as ArcGIS desktop don't support other 
> format (to be confirmed).
> 
> Y.
> On Thursday, November 10, 2016 11:49:49 Jörg Thomsen wrote:
>> Hi Yves,
>>
>> text/plain is text/plain, no layout. The Mapserver-templates work with
>> html-format. Another way could be using the xml-output and styling it
>> with xslt. But you can enable the html-output using templates with
>> mapserver and it still will be possible to send text/plain requests.
>>
>> Templating ist easy and powerful, so to answer your question: yes, read
>> the templating chapter. You'll find a short introduction in the old
>> tutorial: http://demo.mapserver.org/tutorial/section3.html (example 3.1)
>>
>> Jörg
>>
>> Am 10.11.2016 um 11:16 schrieb Yves Jacolin:
>>> Hello,
>>>
>>> I have to setup a text format for a WMS' GetFeatureInfo service. I would
>>> like to know if it is possible to change the layout using a template.
>>>
>>> My first test was not working so any feedback is welcome. The
>>> documentation
>>> said that the user should read the templating chapter so I guess this is
>>> possible.
>>>
>>> Any confirmation?
>>>
>>> Y.
>>
>> Viele Grüße,
>> Jörg Thomsen
> 


Viele Grüße,
Jörg Thomsen

-- 


Where2B Konferenz 2016
15. Dezember 2016 in Bonn
www.where2b-conference.com


---
Jörg Thomsen
WhereGroup GmbH & Co. KG
Gillweg 3
14193 Berlin
Germany

Fon: +49 (0)30 / 5130 278 74
Fax: +49 (0)30 / 89 09 53 11

joerg.thom...@wheregroup.com
www.wheregroup.com
Amtsgericht Bonn, HRA 6788
---
Komplementärin:
WhereGroup Verwaltungs GmbH
vertreten durch:
Olaf Knopp, Peter Stamm
---
Folgen Sie der WhereGroup auf twitter: http://twitter.com/WhereGroup_com
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] GetFeatureInfo layout in plain text

2016-11-10 Thread Yves Jacolin
Thanks Jörg,

Unfortunately I should use text format as ArcGIS desktop don't support other 
format (to be confirmed).

Y.
On Thursday, November 10, 2016 11:49:49 Jörg Thomsen wrote:
> Hi Yves,
> 
> text/plain is text/plain, no layout. The Mapserver-templates work with
> html-format. Another way could be using the xml-output and styling it
> with xslt. But you can enable the html-output using templates with
> mapserver and it still will be possible to send text/plain requests.
> 
> Templating ist easy and powerful, so to answer your question: yes, read
> the templating chapter. You'll find a short introduction in the old
> tutorial: http://demo.mapserver.org/tutorial/section3.html (example 3.1)
> 
> Jörg
> 
> Am 10.11.2016 um 11:16 schrieb Yves Jacolin:
> > Hello,
> > 
> > I have to setup a text format for a WMS' GetFeatureInfo service. I would
> > like to know if it is possible to change the layout using a template.
> > 
> > My first test was not working so any feedback is welcome. The
> > documentation
> > said that the user should read the templating chapter so I guess this is
> > possible.
> > 
> > Any confirmation?
> > 
> > Y.
> 
> Viele Grüße,
> Jörg Thomsen

-- 
Responsable Formation et Support
Camptocamp France SAS
Savoie Technolac, BP 352
73377 Le Bourget du Lac, Cedex
Tel (France) : +33 4 58 48 20 43 (new !)
Tel (Suisse) : +41 21 619 10 43
Mob. : +33 6 18 75 42 21
Fax : 04 79 70 15 81
Mail : yves.jaco...@camptocamp.com
http://www.camptocamp.com
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] GetFeatureInfo layout in plain text

2016-11-10 Thread WhereGroup
Hi Yves,

text/plain is text/plain, no layout. The Mapserver-templates work with
html-format. Another way could be using the xml-output and styling it
with xslt. But you can enable the html-output using templates with
mapserver and it still will be possible to send text/plain requests.

Templating ist easy and powerful, so to answer your question: yes, read
the templating chapter. You'll find a short introduction in the old
tutorial: http://demo.mapserver.org/tutorial/section3.html (example 3.1)

Jörg

Am 10.11.2016 um 11:16 schrieb Yves Jacolin:
> Hello,
> 
> I have to setup a text format for a WMS' GetFeatureInfo service. I would like 
> to know if it is possible to change the layout using a template.
> 
> My first test was not working so any feedback is welcome. The documentation 
> said that the user should read the templating chapter so I guess this is 
> possible.
> 
> Any confirmation?
> 
> Y.
> 


Viele Grüße,
Jörg Thomsen

-- 


Where2B Konferenz 2016
15. Dezember 2016 in Bonn
www.where2b-conference.com


---
Jörg Thomsen
WhereGroup GmbH & Co. KG
Gillweg 3
14193 Berlin
Germany

Fon: +49 (0)30 / 5130 278 74
Fax: +49 (0)30 / 89 09 53 11

joerg.thom...@wheregroup.com
www.wheregroup.com
Amtsgericht Bonn, HRA 6788
---
Komplementärin:
WhereGroup Verwaltungs GmbH
vertreten durch:
Olaf Knopp, Peter Stamm
---
Folgen Sie der WhereGroup auf twitter: http://twitter.com/WhereGroup_com
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] GetFeatureInfo request for multiple times on tileindex raster layer

2016-08-05 Thread Michael Billmire
Thanks for the response, Ben.

What would be the result of an *getmap*-Request

Yes, good point- it appears that if two discrete dates are requested via
GetMap, the result is a merged image (w/ the most recent date getting
precedence):

http://spatial.mtri.org/cgi-bin/mapserv.fcgi?SERVICE=WMS;
VERSION=1.1.1=GetMap=watersensing_map=
chl_erie=2015-09-24,2016-05-23=512=512&
format=image/png=http://spatial.mtri.org/waterremotesensing/SLDs/chl_
erie.xml=EPSG:4326=-83.55,39.45,-78.45,44.55=1

It's hard to tell in the above URL, but if you toggle between a two-date
and one-date request, you can tell that the two-date request has the maps
layered (w/ the map for the most recent date on top).  So it's probably a
good guess that the same logic is applying in the GFI requests.

I'll take a look at the source code to see if there might be a way to
override this logic. To anyone here who is already familiar with the source
code: I welcome any tips about where to look and whether or not my quest
may be futile unless I want to break everything.

On Fri, Aug 5, 2016 at 2:57 AM, Schepers, Benjamin 
wrote:

> Hi Mike,
>
>
>
> just my thoughts:
>
> What would be the result of an *getmap*-Request in your second scenario
> with multiple discrete timestamps?
>
> A getmap-request just can produce one single image – anything else
> wouldn’t make sense to me. So if you request two discrete timestamps, one
> would expect to get two rasters from DB/filesystem and there has to be a
> logic what should be done by mapserver with those two images (choose the
> topmost or the underlying or a merge of them – which merge method? – of
> those pics to get one of two or many)…
>
> Maybe the latest date, as you determined, is the topmost.
>
>
>
> My thought what getfeatureinfo logic does are equivalent to that…
>
> Maybe I’m wrong with that, but that could just be answered by someone who
> can read the sourcecode?!
>
>
>
> If you want to merge rasters on the fly (or their values) COMPOSITE maybe
> could help you: http://mapserver.org/de/mapfile/composite.html
>
>
>
> Sincerely
>
> Ben
>
>
>
>
>
>
>
> *Benjamin Schepers *
> Luftbild und Geoinformationssysteme
> Kronprinzenstraße 35
> 45128 Essen
> Fon: +49 201 2069-232
> Fax: +49 201 2069-500
> schep...@rvr-online.de
>
>
>
>
> *Die Regionaldirektorin *Kronprinzenstraße 35
> 45128 Essen
> Zentrale: +49 (0) 201 2069-0
> Fax: +49 (0) 201 2069-500
> www.metropoleruhr.de
>
> Postfach 10 32 64
> 45032 Essen
>
> Steuernummer: RVR 112/5797/0116
> USt.-ldNr.: DE 173867500
>
> Diese E-Mail koennte vertrauliche und/oder rechtlich geschuetzte
> Informationen enthalten.
> Wenn Sie nicht der richtige Adressat sind oder diese E-Mail irrtuemlich
> erhalten haben, informieren Sie bitte sofort den Absender und vernichten
> Sie diese Mail.
> Das unerlaubte Kopieren sowie die unbefugte Weitergabe dieser E-Mail sind
> nicht gestattet.
> This e-mail may contain confidential and/or privileged information.
> If you are not the intended recipient (or have received this e-mail in
> error) please notify the sender immediately and destroy this e-mail.
> Any unauthorised copying, disclosure or distribution of the material in
> this e-mail is strictly forbidden.
>
> *Von:* mapserver-users [mailto:mapserver-users-boun...@lists.osgeo.org] *Im
> Auftrag von *Michael Billmire
> *Gesendet:* Donnerstag, 4. August 2016 21:53
> *An:* mapserver-users@lists.osgeo.org
> *Betreff:* [mapserver-users] GetFeatureInfo request for multiple times on
> tileindex raster layer
>
>
>
> Hi all,
>
>
>
> I'm serving raster layers as time-series using a PostGIS tile index (
> GetCapabilities
> ,
> for reference).
>
>
>
> GetFeatureInfo is working fine for single timestamp requests, e.g.:
>
> http://spatial.mtri.org/cgi-bin/mapserv.fcgi?SERVICE=WMS;
> VERSION=1.1.1=GetFeatureInfo=watersensing_map_LAYERS=
> chl_erie=chl_erie=2015-09-06=512=
> 512=EPSG:4326=-83.55,39.45,-78.45,44.55=1&
> INFO_FORMAT=text/html=250=250
>
>
>
> However, when requesting *multiple* *discrete* time stamps (e.g.
> time=2015-09-06,2016-05-23), I get multiple results (i.e. a result for each
> timestamp), BUT the pixel value returned is the same for each result,
> representing the raster with the latest date:
>
> http://spatial.mtri.org/cgi-bin/mapserv.fcgi?SERVICE=WMS;
> VERSION=1.1.1=GetFeatureInfo=watersensing_map_LAYERS=
> chl_erie=chl_erie=2015-09-06,2016-05-23=
> 512=512=EPSG:4326=-83.55,39.45,-78.45,44.
> 55=1_FORMAT=text/html=250=250
>
>
>
> In my template, [value_list] returns just the single value (i.e. the value
> of the raster at the latest date), [value_0] returns that same value, and
> [value_1] returns nothing.
>
>
>
> Is there anything obvious here that I'm doing wrong? Is this type of
> multiple timestamp pixel querying even supported?
>
>
>
> thanks!
>
> -Mike
>
>
>
>
>
> --
>
> Michael Billmire, CMS-GIS/LIS
> Research Scientist
> Michigan Tech 

Re: [mapserver-users] GetFeatureInfo request for multiple times on tileindex raster layer

2016-08-05 Thread Schepers, Benjamin
Hi Mike,

just my thoughts:
What would be the result of an getmap-Request in your second scenario with 
multiple discrete timestamps?
A getmap-request just can produce one single image – anything else wouldn’t 
make sense to me. So if you request two discrete timestamps, one would expect 
to get two rasters from DB/filesystem and there has to be a logic what should 
be done by mapserver with those two images (choose the topmost or the 
underlying or a merge of them – which merge method? – of those pics to get one 
of two or many)…
Maybe the latest date, as you determined, is the topmost.

My thought what getfeatureinfo logic does are equivalent to that…
Maybe I’m wrong with that, but that could just be answered by someone who can 
read the sourcecode?!

If you want to merge rasters on the fly (or their values) COMPOSITE maybe could 
help you: http://mapserver.org/de/mapfile/composite.html

Sincerely
Ben



Benjamin Schepers


Luftbild und Geoinformationssysteme
Kronprinzenstraße 35
45128 Essen
Fon: +49 201 2069-232
Fax: +49 201 2069-500
schep...@rvr-online.de

[cid:image001.jpg@01D1EEF2.E97E2630]

Die Regionaldirektorin
Kronprinzenstraße 35
45128 Essen
Zentrale: +49 (0) 201 2069-0
Fax: +49 (0) 201 2069-500
www.metropoleruhr.de

Postfach 10 32 64
45032 Essen

Steuernummer: RVR 112/5797/0116
USt.-ldNr.: DE 173867500

Diese E-Mail koennte vertrauliche und/oder rechtlich geschuetzte Informationen 
enthalten.
Wenn Sie nicht der richtige Adressat sind oder diese E-Mail irrtuemlich 
erhalten haben, informieren Sie bitte sofort den Absender und vernichten Sie 
diese Mail.
Das unerlaubte Kopieren sowie die unbefugte Weitergabe dieser E-Mail sind nicht 
gestattet.
This e-mail may contain confidential and/or privileged information.
If you are not the intended recipient (or have received this e-mail in error) 
please notify the sender immediately and destroy this e-mail.
Any unauthorised copying, disclosure or distribution of the material in this 
e-mail is strictly forbidden.
Von: mapserver-users [mailto:mapserver-users-boun...@lists.osgeo.org] Im 
Auftrag von Michael Billmire
Gesendet: Donnerstag, 4. August 2016 21:53
An: mapserver-users@lists.osgeo.org
Betreff: [mapserver-users] GetFeatureInfo request for multiple times on 
tileindex raster layer

Hi all,

I'm serving raster layers as time-series using a PostGIS tile index 
(GetCapabilities,
 for reference).

GetFeatureInfo is working fine for single timestamp requests, e.g.:
http://spatial.mtri.org/cgi-bin/mapserv.fcgi?SERVICE=WMS=1.1.1=GetFeatureInfo=watersensing_map_LAYERS=chl_erie=chl_erie=2015-09-06=512=512=EPSG:4326=-83.55,39.45,-78.45,44.55=1_FORMAT=text/html=250=250

However, when requesting multiple discrete time stamps (e.g. 
time=2015-09-06,2016-05-23), I get multiple results (i.e. a result for each 
timestamp), BUT the pixel value returned is the same for each result, 
representing the raster with the latest date:
http://spatial.mtri.org/cgi-bin/mapserv.fcgi?SERVICE=WMS=1.1.1=GetFeatureInfo=watersensing_map_LAYERS=chl_erie=chl_erie=2015-09-06,2016-05-23=512=512=EPSG:4326=-83.55,39.45,-78.45,44.55=1_FORMAT=text/html=250=250

In my template, [value_list] returns just the single value (i.e. the value of 
the raster at the latest date), [value_0] returns that same value, and 
[value_1] returns nothing.

Is there anything obvious here that I'm doing wrong? Is this type of multiple 
timestamp pixel querying even supported?

thanks!
-Mike


--
Michael Billmire, CMS-GIS/LIS
Research Scientist
Michigan Tech Research Institute (MTRI)
3600 Green Ct. Suite 100
Ann Arbor, MI 48105

michael.billm...@mtu.edu
work: 734.913.6853
cell: 513.739.0686
fax: 734.913.6880
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] GetFeatureInfo error with native vector tileindex

2014-08-12 Thread Rahkonen Jukka (Tike)
Even Rouault wrote:

 Le lundi 11 août 2014 15:13:47, Rahkonen Jukka (Tike) a écrit :
  Hi,
 
  I have something like 1 shapefiles which I have combined to one
  layer with a tileindex shapefile which is created with ogrtindex
  utility. I can make WMS to render the layer fine both with the native
  Mapserver tileindex connection and by reading the tileindex with OGR
  by using CONNECTIONTYPE OGR.  However, GetFeatureInfo works well only
  with OGR connection to tileindex. The native tileindex throws
  occasionally this error (record number varies, naturally).
 
  msDBFReadAttribute(): DBASE file error. Invalid record number 231855.
 
 Is the error always the same or changing for the exact same GetFeatureInfo
 request ?
 Are you able to determine which shape is at that location and find how many
 records are there in the .DBF ? (what ogrinfo should report) That error is
 returned when :
 if( hEntity  0 || hEntity = psDBF-nRecords ) So it would mean that there 
 is an
 attempt of reading more records than there are actually. Which could happen if
 the DBF would be truncated. But I'm not clear why you wouldn't see the error
 through OGR.
 Difficult to know without being able to reproduce...


Hi,

At least I can reproduce something odd now with a minimal setup which I can 
share.
 
I use a trimmed MS4W version with fresh Mapserver 6.5-dev binaries from 
gisinternals.

The test package is in http://latuviitta.org/downloads/vectortileindex_map.zip
The package contains:
- mapfile in \apps
- one shapefile in \apps\data
- ogrtindex index shap in \apps
- GetFeatureInfo templates for text/html output in \apps\templates

Mapfile has section:
 CONNECTIONTYPE OGR
 TILEINDEX c:\ms4w\apps\debug.shp
 TILEITEM location

When tileindex is read like this through OGR GetFeatureInfo works but not if 
CONNECTIONTYPE OGR is commented out. Rendering works fine with both settings.

Here is a request to test with. It should find data as
KALTEVUUS   ALA NOPEUS  EROOSIO
0.400.6316.00   0

http://localhost:8060/cgi-bin/mapserv.exe?map=/ms4w/apps/vectortileindex.mapSERVICE=WMSVERSION=1.3.0REQUEST=GetFeatureInfoBBOX=322114.29698474460747093,6747927.06825653277337551,322258.16823926079086959,6748042.80528055597096682CRS=EPSG:3067WIDTH=1079HEIGHT=868LAYERS=SMK_uoma-analyysi_alaSTYLES=FORMAT=image/pngQUERY_LAYERS=SMK_uoma-analyysi_alaINFO_FORMAT=text/htmlI=813J=483FEATURE_COUNT=10
 
With DEBUG 5 and when having a correctly working OGR connection into tileindex 
I get all this into MS_ERRORFILE after successful GetFeatureInfo

[Tue Aug 12 14:11:33 2014].119000 msOGRFileOpen(c:\ms4w\apps\debug.shp)...
[Tue Aug 12 14:11:33 2014].119000 OGROPen(c:\ms4w\apps\debug.shp)
[Tue Aug 12 14:11:33 2014].119000 
msConnPoolRegister(SMK_uoma-analyysi_ala,(null),019956E0)
[Tue Aug 12 14:11:33 2014].119000 
msOGRFileOpen(c:/ms4w/apps/data/vesiensuojelu_teema_ii.shp,0)...
[Tue Aug 12 14:11:33 2014].119000 
OGROPen(c:/ms4w/apps/data/vesiensuojelu_teema_ii.shp)
[Tue Aug 12 14:11:33 2014].119000 
msConnPoolRegister(SMK_uoma-analyysi_ala,(null),019C3638)
[Tue Aug 12 14:11:33 2014].119000 msOGRFileWhichShapes: Setting spatial filter 
to 3322545.770087 6750733.636809 3322548.437923 6750736.304646
[Tue Aug 12 14:11:33 2014].119000 
msOGRFileClose(c:/ms4w/apps/data/vesiensuojelu_teema_ii.shp,0).
[Tue Aug 12 14:11:33 2014].119000 
msConnPoolRelease(SMK_uoma-analyysi_ala,(null),019C3638)
[Tue Aug 12 14:11:33 2014].119000 
msOGRFileOpen(c:/ms4w/apps/data/vesiensuojelu_teema_ii.shp,0)...
[Tue Aug 12 14:11:33 2014].119000 
OGROPen(c:/ms4w/apps/data/vesiensuojelu_teema_ii.shp)
[Tue Aug 12 14:11:33 2014].129000 
msConnPoolRegister(SMK_uoma-analyysi_ala,(null),019CACC0)
[Tue Aug 12 14:11:33 2014].129000 msOGRFileWhichShapes: Setting spatial filter 
to 3322545.770087 6750733.636809 3322548.437923 6750736.304646
[Tue Aug 12 14:11:33 2014].129000 msOGRFileNextShape: Returning shape=130023, 
tile=0
[Tue Aug 12 14:11:33 2014].129000 msOGRFileNextShape: Returning MS_DONE (no 
more shapes)
[Tue Aug 12 14:11:33 2014].129000 
msOGRFileClose(c:/ms4w/apps/data/vesiensuojelu_teema_ii.shp,0).
[Tue Aug 12 14:11:33 2014].129000 
msConnPoolRelease(SMK_uoma-analyysi_ala,(null),019CACC0)
[Tue Aug 12 14:11:33 2014].129000 
msOGRFileOpen(c:/ms4w/apps/data/vesiensuojelu_teema_ii.shp,0)...
[Tue Aug 12 14:11:33 2014].129000 
OGROPen(c:/ms4w/apps/data/vesiensuojelu_teema_ii.shp)
[Tue Aug 12 14:11:33 2014].139000 
msConnPoolRegister(SMK_uoma-analyysi_ala,(null),019CADA0)
[Tue Aug 12 14:11:33 2014].139000 msOGRFileWhichShapes: Setting spatial filter 
to 3322545.770087 6750733.636809 3322548.437923 6750736.304646
[Tue Aug 12 14:11:33 2014].139000 freeLayer(): freeing layer at 0198D638.
[Tue Aug 12 14:11:33 2014].139000 msOGRLayerClose((null)).
[Tue Aug 12 14:11:33 2014].139000 msOGRFileClose(c:\ms4w\apps\debug.shp,0).
[Tue Aug 12 14:11:33 2014].139000 
msConnPoolRelease(SMK_uoma-analyysi_ala,(null),019956E0)
[Tue Aug 12 14:11:33 2014].139000 

Re: [mapserver-users] GetFeatureInfo error with native vector tileindex

2014-08-11 Thread Even Rouault
Le lundi 11 août 2014 15:13:47, Rahkonen Jukka (Tike) a écrit :
 Hi,
 
 I have something like 1 shapefiles which I have combined to one layer
 with a tileindex shapefile which is created with ogrtindex utility. I can
 make WMS to render the layer fine both with the native Mapserver tileindex
 connection and by reading the tileindex with OGR by using CONNECTIONTYPE
 OGR.  However, GetFeatureInfo works well only with OGR connection to
 tileindex. The native tileindex throws occasionally this error (record
 number varies, naturally).
 
 msDBFReadAttribute(): DBASE file error. Invalid record number 231855.

Is the error always the same or changing for the exact same GetFeatureInfo 
request ?
Are you able to determine which shape is at that location and find how many 
records are there in the .DBF ? (what ogrinfo should report)
That error is returned when :
if( hEntity  0 || hEntity = psDBF-nRecords )
So it would mean that there is an attempt of reading more records than there 
are actually. Which could happen if the DBF would be truncated. But I'm not 
clear why you wouldn't see the error through OGR.
Difficult to know without being able to reproduce...

 
 Have anybody else experienced something similar? I know that all the
 shapefiles in the data directory are a bit faulty because they are written
 with an old shapelib version, see GDAL ticket
 http://trac.osgeo.org/gdal/ticket/5608. However, Mapserver in this case
 gives an error from msDBFReadAttribute() and I do not know if it can have
 to do with the content length field of the .shx file. Another detail is
 that the shapefiles in my data directory do not overlap but the bounding
 boxes stored into the vector tileindex file do overlap. I also tried to
 make a small sample for demonstrating the issue but unfortunately
 Mapserver works correctly with this dataset both through the native and
 OGR tileindexes.
 
 -Jukka Rahkonen-
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users

-- 
Spatialys - Geospatial professional services
http://www.spatialys.com
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo encoding with HTML template...

2013-04-24 Thread Rahkonen Jukka
Hi,

The same http header works for me as
  !-- MapServer Template --
  html
  head
  link rel=stylesheet href=style.css type=text/css /
meta http-equiv=content-type content=text/html; charset=ISO-8859-1/meta

I do not understand why it does not work for you. What Mapserver do you use? 
Are you sure that you edit the right file? May sound stupid but it has happened 
to me often.

-Jukka Rahkonen-


Paul james wrote:

Hello...

I´m using a SQL Server 2008 database and I´m having problem with GetFeatureInfo 
accents using HTML templates...
I need to set encoding to UTF-8...

I added that to header.html template:

   meta http-equiv=content-type content=text/html; charset=UTF-8/meta

No success at all... Tried to force html response header on IIS to UTF-8, no 
success as well...

How can I solve that problem?

Thanks


___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo encoding with HTML template...

2013-04-24 Thread Paul james
Tried ISO-8859-1 encondig and it worked fine!

Thanks


On Wed, Apr 24, 2013 at 9:21 AM, Rahkonen Jukka
jukka.rahko...@mmmtike.fiwrote:

  Hi,

 ** **

 The same http header works for me as

   !-- MapServer Template --

   html

   head

   link rel=stylesheet href=style.css type=text/css /

 meta http-equiv=content-type content=text/html;
 charset=ISO-8859-1/meta

 ** **

 I do not understand why it does not work for you. What Mapserver do you
 use? Are you sure that you edit the right file? May sound stupid but it has
 happened to me often.

 ** **

 -Jukka Rahkonen-

 ** **

 ** **

 Paul james wrote:

 ** **

 Hello...

  

 I´m using a SQL Server 2008 database and I´m having problem with
 GetFeatureInfo accents using HTML templates... 

 I need to set encoding to UTF-8...

  

 I added that to header.html template:

  

meta http-equiv=content-type content=text/html;
 charset=UTF-8/meta

  

 No success at all... Tried to force html response header on IIS to UTF-8,
 no success as well...

  

 How can I solve that problem?

  

 Thanks

  

  

 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users


___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo GML

2013-03-25 Thread Mark Davidson
Hi Stefan,

Thanks for the suggestion, I've tried that but still getting the same
output as before.
Any other suggestions?

Thanks again,

Mark

On 25 March 2013 11:41, Stefan Schantz sscha...@bfs.de wrote:

  Hi Mark,
 I use gml_include_items 'all'

 Best regards
 Stefan

 Am 25.03.2013 11:44, schrieb Mark Davidson:

  Hi All,

 I'm trying to do a GetFeaureInfo on my layer and return it in GML format.
 The request works fine but I can't seem to get any data to come back apart
 from the point bounds.

 ?xml version=1.0 encoding=ISO-8859-1?

  msGMLOutput
  xmlns:gml=http://www.opengis.net/gml;
  xmlns:xlink=http://www.w3.org/1999/xlink;
  xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
  test_layer
  gml:nameTest Points/gml:name
  test_feature
  gml:boundedBy
  gml:Box srsName=EPSG:900913
  gml:coordinates-269220.293738,6545357.533946
 -269220.293738,6545357.533946/gml:coordinates
  /gml:Box
  /gml:boundedBy
  /test_feature
  test_feature
  gml:boundedBy
  gml:Box srsName=EPSG:900913
  gml:coordinates-253276.741855,6554416.311795
 -253276.741855,6554416.311795/gml:coordinates
  /gml:Box
  /gml:boundedBy
  /test_feature /test_layer /msGMLOutput

 What I would like to be able to do is get the feature id as what happends
 with the plain output

 GetFeatureInfo results:

  Layer 'test'
  Feature 326:
  Feature 327:

 I've set `gml_include_items` to * and `wms_include_item` to * as well but
 still not having any luck.

 Could someone point me in the direction of doing this?

 Many thanks,

 Mark





 ___
 mapserver-users mailing 
 listmapserver-users@lists.osgeo.orghttp://lists.osgeo.org/mailman/listinfo/mapserver-users


 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users


___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo GML

2013-03-25 Thread Kralidis,Tom [Ontario]
Mark: try (in LAYER) DUMP TRUE?  Can you post the layer definition snippet from 
your mapfile?

From: mapserver-users-boun...@lists.osgeo.org 
[mailto:mapserver-users-boun...@lists.osgeo.org] On Behalf Of Mark Davidson
Sent: Monday, March 25, 2013 09:30
To: Stefan Schantz
Cc: mapserver-users@lists.osgeo.org
Subject: Re: [mapserver-users] GetFeatureInfo GML

Hi Stefan,

Thanks for the suggestion, I've tried that but still getting the same output as 
before.
Any other suggestions?

Thanks again,

Mark
On 25 March 2013 11:41, Stefan Schantz sscha...@bfs.de wrote:
Hi Mark,
I use gml_include_items 'all'

Best regards
Stefan

Am 25.03.2013 11:44, schrieb Mark Davidson: 
 Hi All,

I'm trying to do a GetFeaureInfo on my layer and return it in GML format. The 
request works fine but I can't seem to get any data to come back apart from the 
point bounds.
?xml version=1.0 encoding=ISO-8859-1?

msGMLOutput 
xmlns:gml=http://www.opengis.net/gml;
xmlns:xlink=http://www.w3.org/1999/xlink;
xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
test_layer
gml:nameTest Points/gml:name
test_feature
gml:boundedBy
gml:Box srsName=EPSG:900913
gml:coordinates-269220.293738,6545357.533946 
-269220.293738,6545357.533946/gml:coordinates
/gml:Box
/gml:boundedBy
/test_feature
test_feature
gml:boundedBy
gml:Box srsName=EPSG:900913
gml:coordinates-253276.741855,6554416.311795 
-253276.741855,6554416.311795/gml:coordinates
/gml:Box
/gml:boundedBy
/test_feature /test_layer /msGMLOutput

What I would like to be able to do is get the feature id as what happends with 
the plain output
GetFeatureInfo results:

Layer 'test'
Feature 326: 
Feature 327:

I've set `gml_include_items` to * and `wms_include_item` to * as well but still 
not having any luck. 

Could someone point me in the direction of doing this? 

Many thanks,

Mark
 



___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo GML

2013-03-25 Thread Mark Davidson
Here is my entire map file just in-case I’ve done something stupid.

MAP
PROJECTION
init=epsg:4326
END

FONTSET fonts.list
NAME TEST
STATUS ON
SIZE 1000 1000
MAXSIZE 3000
EXTENT -180 -90 180 90
UNITS DD

WEB
METADATA
ows_enable_request *
wms_title   Testing
wms_onlineresource  
http://localhost/cgi-bin/mapserv?map=test2.map;
wms_srs EPSG:900913
END
END
SYMBOL
NAME circle
TYPE ellipse
FILLED true
POINTS
 1 1
END
END

LAYER
NAME test
METADATA
wms_titleTest Points  ##required
END
TEMPLATE blank.html
TOLERANCE 10
TYPE POINT
CONNECTIONTYPE postgis
CONNECTION 
DATA position from datatable
DEBUG TRUE

CLASS
STYLE
SIZE 10
SYMBOL circle
COLOR 255 0 0
END
END
END
END

On 25 March 2013 13:42, Kralidis,Tom [Ontario] tom.krali...@ec.gc.cawrote:

 Mark: try (in LAYER) DUMP TRUE?  Can you post the layer definition snippet
 from your mapfile?

 From: mapserver-users-boun...@lists.osgeo.org [mailto:
 mapserver-users-boun...@lists.osgeo.org] On Behalf Of Mark Davidson
 Sent: Monday, March 25, 2013 09:30
 To: Stefan Schantz
 Cc: mapserver-users@lists.osgeo.org
 Subject: Re: [mapserver-users] GetFeatureInfo GML

 Hi Stefan,

 Thanks for the suggestion, I've tried that but still getting the same
 output as before.
 Any other suggestions?

 Thanks again,

 Mark
 On 25 March 2013 11:41, Stefan Schantz sscha...@bfs.de wrote:
 Hi Mark,
 I use gml_include_items 'all'

 Best regards
 Stefan

 Am 25.03.2013 11:44, schrieb Mark Davidson:
  Hi All,

 I'm trying to do a GetFeaureInfo on my layer and return it in GML format.
 The request works fine but I can't seem to get any data to come back apart
 from the point bounds.
 ?xml version=1.0 encoding=ISO-8859-1?

 msGMLOutput
 xmlns:gml=http://www.opengis.net/gml;
 xmlns:xlink=http://www.w3.org/1999/xlink;
 xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
 test_layer
 gml:nameTest Points/gml:name
 test_feature
 gml:boundedBy
 gml:Box srsName=EPSG:900913
 gml:coordinates-269220.293738,6545357.533946
 -269220.293738,6545357.533946/gml:coordinates
 /gml:Box
 /gml:boundedBy
 /test_feature
 test_feature
 gml:boundedBy
 gml:Box srsName=EPSG:900913
 gml:coordinates-253276.741855,6554416.311795
 -253276.741855,6554416.311795/gml:coordinates
 /gml:Box
 /gml:boundedBy
 /test_feature /test_layer /msGMLOutput

 What I would like to be able to do is get the feature id as what happends
 with the plain output
 GetFeatureInfo results:

 Layer 'test'
 Feature 326:
 Feature 327:

 I've set `gml_include_items` to * and `wms_include_item` to * as well but
 still not having any luck.

 Could someone point me in the direction of doing this?

 Many thanks,

 Mark




 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users

 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users


___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo GML

2013-03-25 Thread Stefan Schantz

Hi Mark,
I show you my layer definition, which works.
As I understand, the bold parameters in the metadata section are missing 
in your mapfile...

(...)
LAYER
NAME odl_einstundenmittel
TYPE POINT
STATUS ON
MINSCALEDENOM 11

METADATA
WMS_TITLE blabla
WMS_ABSTRACT blabla
WMS_ENABLE_REQUEST *
INCLUDE ../../include/general/standard_extent_germany_4326.map
*GML_INCLUDE_ITEMS name,datum,WERT
GML_name_ALIAS Station
GML_datum_ALIAS Messende
GML_WERT_ALIAS Messwert*
END

TEMPLATE blank.gml
INCLUDE ../../include/general/db_mysql_connect_odl_result.map
DATA blöbla

TOLERANCE 6
TOLERANCEUNITS pixels
INCLUDE ../../include/classes/class_odl_rb_nolabel.map
END

Regards,
Stefan


Am 25.03.2013 14:50, schrieb Mark Davidson:

Here is my entire map file just in-case I’ve done something stupid.

MAP
PROJECTION
init=epsg:4326
END

FONTSET fonts.list
NAME TEST
STATUS ON
SIZE 1000 1000
MAXSIZE 3000
EXTENT -180 -90 180 90
UNITS DD

WEB
METADATA
ows_enable_request *
wms_title   Testing
wms_onlineresource  
http://localhost/cgi-bin/mapserv?map=test2.map; 
http://localhost/cgi-bin/mapserv?map=test2.map;

wms_srs EPSG:900913
END
END
SYMBOL
NAME circle
TYPE ellipse
FILLED true
POINTS
 1 1
END
END

LAYER
NAME test
METADATA
wms_titleTest Points  ##required
END
TEMPLATE blank.html
TOLERANCE 10
TYPE POINT
CONNECTIONTYPE postgis
CONNECTION 
DATA position from datatable
DEBUG TRUE

CLASS
STYLE
SIZE 10
SYMBOL circle
COLOR 255 0 0
END
END
END
END

On 25 March 2013 13:42, Kralidis,Tom [Ontario] tom.krali...@ec.gc.ca 
mailto:tom.krali...@ec.gc.ca wrote:


Mark: try (in LAYER) DUMP TRUE?  Can you post the layer definition
snippet from your mapfile?

From: mapserver-users-boun...@lists.osgeo.org
mailto:mapserver-users-boun...@lists.osgeo.org
[mailto:mapserver-users-boun...@lists.osgeo.org
mailto:mapserver-users-boun...@lists.osgeo.org] On Behalf Of
Mark Davidson
Sent: Monday, March 25, 2013 09:30
To: Stefan Schantz
Cc: mapserver-users@lists.osgeo.org
mailto:mapserver-users@lists.osgeo.org
Subject: Re: [mapserver-users] GetFeatureInfo GML

Hi Stefan,

Thanks for the suggestion, I've tried that but still getting the
same output as before.
Any other suggestions?

Thanks again,

Mark
On 25 March 2013 11:41, Stefan Schantz sscha...@bfs.de
mailto:sscha...@bfs.de wrote:
Hi Mark,
I use gml_include_items 'all'

Best regards
Stefan

Am 25.03.2013 11 tel:25.03.2013%2011:44, schrieb Mark Davidson:
 Hi All,

I'm trying to do a GetFeaureInfo on my layer and return it in GML
format. The request works fine but I can't seem to get any data to
come back apart from the point bounds.
?xml version=1.0 encoding=ISO-8859-1?

msGMLOutput
xmlns:gml=http://www.opengis.net/gml;
xmlns:xlink=http://www.w3.org/1999/xlink;
xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
test_layer
gml:nameTest Points/gml:name
test_feature
gml:boundedBy
gml:Box srsName=EPSG:900913
gml:coordinates-269220.293738,6545357.533946
-269220.293738,6545357.533946/gml:coordinates
/gml:Box
/gml:boundedBy
/test_feature
test_feature
gml:boundedBy
gml:Box srsName=EPSG:900913
gml:coordinates-253276.741855,6554416.311795
-253276.741855,6554416.311795/gml:coordinates
/gml:Box
/gml:boundedBy
/test_feature /test_layer /msGMLOutput

What I would like to be able to do is get the feature id as what
happends with the plain output
GetFeatureInfo results:

Layer 'test'
Feature 326:
Feature 327:

I've set `gml_include_items` to * and `wms_include_item` to * as
well but still not having any luck.

Could someone point me in the direction of doing this?

Many thanks,

Mark




___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
mailto:mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
mailto:mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo results: Search returned no results

2012-04-10 Thread Rahkonen Jukka
Hi,

Perhaps you do not hit the points? See tolerance and toleranceunits in 
http://mapserver.org/mapfile/layer.html and set tolerance to quite many pixels 
for eliminating the possibility that your click just does not hit the target.

If that does not help I would have another try by copying the data from PostGIS 
ínto shapefile and dublicating the layer. If GetFeatureInfo works with 
shapefile then the trouble must have something to do with communication with 
PostGIS.

I wonder why do you have layer status=OFF instead of ON.

-Jukka Rahkonen-

Neelima Emmani  wrote:

Hi All,

I  am having a problem in retrieving getfeatureinfo. Result in the browser is

GetFeatureInfo results:  Search returned no results.

  *   Below is the url, i am accessing to get feature info -

http://localhost/cgi-bin/mapserv.exe?map=C:/ms4w/apps/openlayers-2.10/examples/mh.mapSERVICE=WMSVERSION=1.1.1REQUEST=GetFeatureInfoLayers=mapsSRS=EPSG:4326BBOX=-83.61145,24.726875,-78.118286,27.196014X=529Y=228WIDTH=1000HEIGHT=500QUERY_LAYERS=maps


  *   Map file -

MAP
  NAME MH
  # Map image size
  SIZE 600 600
  UNITS meters
  EXTENT -86.731680 24.422064 -76.149835 30.424575
  FONTSET './etc/fonts.txt'
  SYMBOLSET './etc/symbols.txt'
  CONFIG PROJ_LIB C:/ms4w/httpd.d/proj/nad/

  PROJECTION
'proj=longlat'
'ellps=WGS84'
'towgs84=0,0,0,0,0,0,0'
'no_defs'
  END

  # Background color for the map canvas -- change as desired
  IMAGECOLOR 255 255 255
  IMAGEQUALITY 95
  IMAGETYPE agg

  OUTPUTFORMAT
NAME agg
DRIVER AGG/PNG
IMAGEMODE RGB
  END

  # Legend
  LEGEND
  IMAGECOLOR 255 255 255
STATUS ON
KEYSIZE 18 12
LABEL
  TYPE BITMAP
  SIZE MEDIUM
  COLOR 0 0 89
END
  END

  # Web interface definition. Only the template parameter
  # is required to display a map. See MapServer documentation
  WEB
# Set IMAGEPATH to the path where MapServer should
# write its output.
IMAGEPATH '/ms4w/tmp/ms_tmp/'

# Set IMAGEURL to the url that points to IMAGEPATH
# as defined in your web server configuration
IMAGEURL '/ms_tmp/'

# WMS server settings
METADATA
  'ows_title'   'MH'
  'ows_onlineresource'  
'http://localhost/cgi-bin/mapserv.exe?map=C:/ms4w/apps/openlayers-2.10/examples/mh.map;'
  'ows_srs' 'EPSG:4326 EPSG:900913'
  'ows_enable_request'  'GetMap GetFeature GetFeatureInfo *'   ##necessary
  wms_feature_info_mime_type text/html
  wms_getfeatureinfo
http://localhost/cgi-bin/mapserv.exe?map=C:/ms4w/apps/openlayers-2.10/examples/mh.map;
  wms_featureinfoformat text/html
  wfs_abstract   This text describes my WFS service.

END

#Scale range at which web interface will operate
# Template and header/footer settings
# Only the template parameter is required to display a map. See MapServer 
documentation
TEMPLATE 'template.html'
  END

  LAYER
NAME 'maps'
TYPE POINT
DUMP true
TEMPLATE  'template.html'
HEADER 'header.html'
FOOTER 'footer.html'
EXTENT -86.731680 24.422064 -76.149835 30.424575
CONNECTIONTYPE postgis
CONNECTION dbname='postgis' host=localhost port=5432 user='postgres' 
password='xx' sslmode=disable
DATA 'the_geom FROM maps USING UNIQUE id USING srid=4326'
FILTER ( geometrytype(the_geom) IN ('POINT','MULTIPOINT') )
METADATA
  'ows_title' 'maps'
  'wfs_typename' 'maps'
  'wfs_version' '1.0.0'
  'wfs_connectiontimeout' '60'
  'wfs_maxfeatures' '150'
  'wfs_filter' 'GET'
  'wms_include_items' 'all'
  'wfs_featureid' 'the_geom'
  'gml_include_items' 'all'

END
STATUS OFF
TRANSPARENCY 100
PROJECTION
'proj=longlat'
'ellps=WGS84'
'towgs84=0,0,0,0,0,0,0'
'no_defs'
END
CLASS
   NAME 'maps'
   STYLE
 SYMBOL circle
 SIZE 7.0
 OUTLINECOLOR 0 0 0
 COLOR 170 211 227
   END
END
  END

END


Template.html --
!-- MapServer Template --
trtd[lrn]/tdtd[NAME]/tdtd[LAT]/tdtd[LON]/tdtd[ELEVATION]/tdtd[QUADNAME]/td/tr

header.html--
!-- MapServer Template --
font size+1bLayer: airports/b/fontp
table cellpadding=5 cellspacing=2 border=0
tr bgcolor=#CCtd 
bgcolor=#ffnbsp;/tdthname/ththlatitude/ththlongitude/ththaddress/ththdescription/th/tr

footer.html --
!-- MapServer Template --
/tablep

If any finds any fault with my code or anything that should be added to get 
feature info then please let me know.
Awaiting reply.

With Regards,
Neelima Emmani
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


RE: [mapserver-users] GetFeatureInfo results: Search returned no results

2012-04-10 Thread Neelima Emmani
Hi Rahkonen,

Tried giving Tolerance as 3 and it's units as meters , but it did not work. 
Also tried with the mapfile that has shapefile layer. The case is same.
Do you any other idea that can solve my problem. And if you have already worked 
on this can you please send a piece of code that works.

With Regards,
Neelima Emmani

From: mapserver-users-boun...@lists.osgeo.org 
[mapserver-users-boun...@lists.osgeo.org] on behalf of Rahkonen Jukka 
[jukka.rahko...@mmmtike.fi]
Sent: Tuesday, April 10, 2012 12:29 PM
To: 'mapserver-users@lists.osgeo.org'
Subject: Re: [mapserver-users] GetFeatureInfo results: Search returned no 
results

Hi,

Perhaps you do not hit the points? See tolerance and toleranceunits in 
http://mapserver.org/mapfile/layer.html and set tolerance to quite many pixels 
for eliminating the possibility that your click just does not hit the target.

If that does not help I would have another try by copying the data from PostGIS 
ínto shapefile and dublicating the layer. If GetFeatureInfo works with 
shapefile then the trouble must have something to do with communication with 
PostGIS.

I wonder why do you have layer status=OFF instead of ON.

-Jukka Rahkonen-

Neelima Emmani  wrote:

Hi All,

I  am having a problem in retrieving getfeatureinfo. Result in the browser is

GetFeatureInfo results:  Search returned no results.

  *   Below is the url, i am accessing to get feature info -

http://localhost/cgi-bin/mapserv.exe?map=C:/ms4w/apps/openlayers-2.10/examples/mh.mapSERVICE=WMSVERSION=1.1.1REQUEST=GetFeatureInfoLayers=mapsSRS=EPSG:4326BBOX=-83.61145,24.726875,-78.118286,27.196014X=529Y=228WIDTH=1000HEIGHT=500QUERY_LAYERS=maps


  *   Map file -

MAP
  NAME MH
  # Map image size
  SIZE 600 600
  UNITS meters
  EXTENT -86.731680 24.422064 -76.149835 30.424575
  FONTSET './etc/fonts.txt'
  SYMBOLSET './etc/symbols.txt'
  CONFIG PROJ_LIB C:/ms4w/httpd.d/proj/nad/

  PROJECTION
'proj=longlat'
'ellps=WGS84'
'towgs84=0,0,0,0,0,0,0'
'no_defs'
  END

  # Background color for the map canvas -- change as desired
  IMAGECOLOR 255 255 255
  IMAGEQUALITY 95
  IMAGETYPE agg

  OUTPUTFORMAT
NAME agg
DRIVER AGG/PNG
IMAGEMODE RGB
  END

  # Legend
  LEGEND
  IMAGECOLOR 255 255 255
STATUS ON
KEYSIZE 18 12
LABEL
  TYPE BITMAP
  SIZE MEDIUM
  COLOR 0 0 89
END
  END

  # Web interface definition. Only the template parameter
  # is required to display a map. See MapServer documentation
  WEB
# Set IMAGEPATH to the path where MapServer should
# write its output.
IMAGEPATH '/ms4w/tmp/ms_tmp/'

# Set IMAGEURL to the url that points to IMAGEPATH
# as defined in your web server configuration
IMAGEURL '/ms_tmp/'

# WMS server settings
METADATA
  'ows_title'   'MH'
  'ows_onlineresource'  
'http://localhost/cgi-bin/mapserv.exe?map=C:/ms4w/apps/openlayers-2.10/examples/mh.map;'
  'ows_srs' 'EPSG:4326 EPSG:900913'
  'ows_enable_request'  'GetMap GetFeature GetFeatureInfo *'   ##necessary
  wms_feature_info_mime_type text/html
  wms_getfeatureinfo
http://localhost/cgi-bin/mapserv.exe?map=C:/ms4w/apps/openlayers-2.10/examples/mh.map;
  wms_featureinfoformat text/html
  wfs_abstract   This text describes my WFS service.

END

#Scale range at which web interface will operate
# Template and header/footer settings
# Only the template parameter is required to display a map. See MapServer 
documentation
TEMPLATE 'template.html'
  END

  LAYER
NAME 'maps'
TYPE POINT
DUMP true
TEMPLATE  'template.html'
HEADER 'header.html'
FOOTER 'footer.html'
EXTENT -86.731680 24.422064 -76.149835 30.424575
CONNECTIONTYPE postgis
CONNECTION dbname='postgis' host=localhost port=5432 user='postgres' 
password='xx' sslmode=disable
DATA 'the_geom FROM maps USING UNIQUE id USING srid=4326'
FILTER ( geometrytype(the_geom) IN ('POINT','MULTIPOINT') )
METADATA
  'ows_title' 'maps'
  'wfs_typename' 'maps'
  'wfs_version' '1.0.0'
  'wfs_connectiontimeout' '60'
  'wfs_maxfeatures' '150'
  'wfs_filter' 'GET'
  'wms_include_items' 'all'
  'wfs_featureid' 'the_geom'
  'gml_include_items' 'all'

END
STATUS OFF
TRANSPARENCY 100
PROJECTION
'proj=longlat'
'ellps=WGS84'
'towgs84=0,0,0,0,0,0,0'
'no_defs'
END
CLASS
   NAME 'maps'
   STYLE
 SYMBOL circle
 SIZE 7.0
 OUTLINECOLOR 0 0 0
 COLOR 170 211 227
   END
END
  END

END


Template.html --
!-- MapServer Template --
trtd[lrn]/tdtd[NAME]/tdtd[LAT]/tdtd[LON]/tdtd[ELEVATION]/tdtd[QUADNAME]/td/tr

header.html--
!-- MapServer Template --
font size+1bLayer: airports/b/fontp
table cellpadding=5 cellspacing=2 border=0
tr bgcolor=#CCtd 
bgcolor=#ffnbsp;/tdthname/ththlatitude/ththlongitude/ththaddress/ththdescription/th/tr

footer.html --
!-- MapServer

Re: [mapserver-users] GetFeatureInfo using MySQL join - additional info about segmentation fault

2011-09-14 Thread Dejan Gambin
I tried debugging with gdb but only get this:

Program received signal SIGTRAP, Trace/breakpoint trap.
0x7f8b8d76c8b7 in ?? () from /lib64/ld-linux-x86-64.so.2

and with backtrace (bt):

#0  0x7f8b8d76c8b7 in ?? () from /lib64/ld-linux-x86-64.so.2
#1  0x7f8b8d75b1bc in ?? () from /lib64/ld-linux-x86-64.so.2
#2  0x7f8b8d76bb35 in ?? () from /lib64/ld-linux-x86-64.so.2
#3  0x7f8b8d75931b in ?? () from /lib64/ld-linux-x86-64.so.2
#4  0x7f8b8d758a68 in ?? () from /lib64/ld-linux-x86-64.so.2
#5  0x0002 in ?? ()
#6  0x7fff531bc8e2 in ?? ()
#7  0x in ?? ()

regards, dejan

On 14. ruj. 2011., at 12:33, Dejan Gambin wrote:

 I have found Segmentation fault message in apache error.log each time I run 
 GetFeatureInfo with MySQL join. No problem with PostgreSQL :-(
 
 Any clue? Should I report it as a bug?
 
 dejan
 On 13. ruj. 2011., at 22:51, Dejan Gambin wrote:
 
 Of course. And everything works when using ogrinfo for example
 
 dejan
 On 13. ruj. 2011., at 20:19, Carlos Ruiz wrote:
 
 Dejan,
 
 One question: If you look at the OGR supported formats, does MySQL appears ?
 
 Cheers from México
 
 IC Carlos Ruiz
 
 From: Dejan Gambin dejan.gam...@coin.hr
 To: mapserver-users@lists.osgeo.org
 Sent: Tuesday, September 13, 2011 8:13 AM
 Subject: Re: [mapserver-users] GetFeatureInfo using MySQL join - additional 
 info
 
 I was finally successful with getting data from joined table through 
 GetFeatureInfo. But:
 
 1. It works only for PostgreSQL connection, not with MySQL - is it supposed 
 to be so in MapServer 6? I saw the JOIN documentation changed and there is 
 no MySQL mentioned any more/
 2. I get nicely returned data from one-to-many join, using templates 
 (thanks to Ted Spradley post). But gml returns only the main data, not the 
 joined data. Is it supposed to be so?
 
 Thanks very much
 
 regards, dejan
 On 13. ruj. 2011., at 09:00, Dejan Gambin wrote:
 
 Some additional info:
 
 Since I need this data only for GetFeatureRequest, it seems like I should 
 use JOIN within a LAYER object. So I did the following:
 
 LAYER
 ...
   DATA my
   ...
   ...
   DUMP TRUE
   TEMPLATE template.html
   HEADER template_header.html
   FOOTER template_footer.html
   JOIN
 NAME test
 CONNECTION 
 MySQL:gis,host=localhost,user=gis,password=gis,tables=katastar_vodnjan
 #CONNECTION PG:host=localhost user=postgres password=runda711 
 dbname=vodnjan port=5432 
 CONNECTIONTYPE ogr
 TABLE katastar_vodnjan
 FROM KO_KC
 TO broj_ko_kc
 TYPE ONE-TO-MANY
 TEMPLATE template_join.html
 #  HEADER template_header.html
 #  FOOTER template_footer.html
   END  
 
 I tried this with joined data from MySQL and from Postgres. No success. 
 The interesting thing is, when I do:
 
 shp2img -m my.map -o image.png -l mylayer -all_debug 3
 
 I get:
 
 [Tue Sep 13 08:58:04 2011].271467 msLoadMap(): 0.029s
 [Tue Sep 13 08:58:04 2011].356888 msDrawMap(): Layer 0 
 (katastar_vodnjan_poligon), 0.083s
 [Tue Sep 13 08:58:04 2011].356943 msDrawMap(): Drawing Label Cache, 0.000s
 [Tue Sep 13 08:58:04 2011].356956 msDrawMap() total time: 0.085s
 [Tue Sep 13 08:58:04 2011].399386 msSaveImage() total time: 0.042s
 [Tue Sep 13 08:58:04 2011].402773 msPOSTGRESQLJoinClose() already close or 
 never opened.
 [Tue Sep 13 08:58:04 2011].402821 shp2img total time: 0.161s
 
 Does anybody  know what is it? It happens for MySQL and Postgres database 
 join
 
 thanks very much
 
 dejan
 
 
 On 12. ruj. 2011., at 14:03, Dejan Gambin wrote:
 
 Hi,
 
 After solving my compile problem (thanks to thomas), I need to do 
 GetFeatureInfo to a shape layer joined to MySQL table (non-spatial join).
 
 I compiled MapServer with MySQL support and everything seems ok, but 
 mapserv -v doesn't return INPUT=MYSQL. Is it supposed to anyway? Or 
 it is enough to be compiled with gdal/ogr that supports MySQL?
 
 Because - when I do this:
 
 ogrinfo -sql SELECT * FROM my LEFT JOIN 
 'MYSQL:gis,host=localhost,user=gis,password=gis'.katastar_vodnjan ON 
 my.KO_KC=katastar_vodnjan.broj_ko_kc /var/www/data/vodnjan/my.shp
 
 I get all the attributes from shape (dbf) and MySQL, so everything seems 
 fine
 
 But using thi:
 
 LAYER # katastar vodnjan poligoni
   NAME mylayer
   STATUS ON
   CONNECTIONTYPE ogr  
   CONNECTION /var/www/data/vodnjan/my.shp
   DATA SELECT * FROM my LEFT JOIN 
 'MYSQL:gis,host=localhost,user=gis,password=gis'.katastar_vodnjan ON 
 my.KO_KC=katastar_vodnjan.broj_ko_kc
   TYPE POLYGON  
 ...
 
 I don't get any information with GetFeatureInfo. The request is like:
 
 http://www.coin.hr/cgi-bin/mywms61?SERVICE=WMSVERSION=1.1.1REQUEST=GetFeatureInfoBBOX=5403800,4981350,5403980,4981460SRS=EPSG:31275WIDTH=400HEIGHT=300LAYERS=katastar_vodnjan_poligonSTYLES=FORMAT=image/pngTRANSPARENT=trueQUERY_LAYERS=mylayerINFO_FORMAT=gmlX=200Y=100
 
 Using the same request with regular mapfile:
 
 LAYER # katastar vodnjan poligoni
   NAME mylayer
   STATUS ON
   DATA my
   TYPE POLYGON

Re: [mapserver-users] GetFeatureInfo using MySQL join - additional info about segmentation fault

2011-09-14 Thread Dejan Gambin
Another thing - I tried this on another machine. I get this:

Program received signal EXC_BAD_ACCESS, Could not access memory.
Reason: KERN_INVALID_ADDRESS at address: 0x
0x7fff88337c00 in strlen ()
(gdb) bt
#0  0x7fff88337c00 in strlen ()
#1  0x0001cf77aa67 in msPOSTGRESQLJoinConnect ()
#2  0x0001cf6b578b in msReturnNestedTemplateQuery ()
#3  0x0001cf70bbd9 in msWMSFeatureInfo ()
#4  0x0001cf710584 in msWMSDispatch ()
#5  0x0001cf7389e3 in msOWSDispatch ()
#6  0x0001cf67728d in main ()


My question is - why msPOSTGRESQLJoinConnect is called if join is defined for 
MySQL:

  JOIN
NAME test
CONNECTIONTYPE ogr
CONNECTION MySQL:gis,user=gis,password=gis,port=3306
TABLE katastar_vodnjan
FROM KO_KC
TO broj_ko_kc
TYPE ONE-TO-MANY
TEMPLATE template_join.html
  END  

regards, dejan
On 14. ruj. 2011., at 13:05, Dejan Gambin wrote:

 I tried debugging with gdb but only get this:
 
 Program received signal SIGTRAP, Trace/breakpoint trap.
 0x7f8b8d76c8b7 in ?? () from /lib64/ld-linux-x86-64.so.2
 
 and with backtrace (bt):
 
 #0  0x7f8b8d76c8b7 in ?? () from /lib64/ld-linux-x86-64.so.2
 #1  0x7f8b8d75b1bc in ?? () from /lib64/ld-linux-x86-64.so.2
 #2  0x7f8b8d76bb35 in ?? () from /lib64/ld-linux-x86-64.so.2
 #3  0x7f8b8d75931b in ?? () from /lib64/ld-linux-x86-64.so.2
 #4  0x7f8b8d758a68 in ?? () from /lib64/ld-linux-x86-64.so.2
 #5  0x0002 in ?? ()
 #6  0x7fff531bc8e2 in ?? ()
 #7  0x in ?? ()
 
 regards, dejan
 
 On 14. ruj. 2011., at 12:33, Dejan Gambin wrote:
 
 I have found Segmentation fault message in apache error.log each time I 
 run GetFeatureInfo with MySQL join. No problem with PostgreSQL :-(
 
 Any clue? Should I report it as a bug?
 
 dejan
 On 13. ruj. 2011., at 22:51, Dejan Gambin wrote:
 
 Of course. And everything works when using ogrinfo for example
 
 dejan
 On 13. ruj. 2011., at 20:19, Carlos Ruiz wrote:
 
 Dejan,
 
 One question: If you look at the OGR supported formats, does MySQL appears 
 ?
 
 Cheers from México
 
 IC Carlos Ruiz
 
 From: Dejan Gambin dejan.gam...@coin.hr
 To: mapserver-users@lists.osgeo.org
 Sent: Tuesday, September 13, 2011 8:13 AM
 Subject: Re: [mapserver-users] GetFeatureInfo using MySQL join - 
 additional info
 
 I was finally successful with getting data from joined table through 
 GetFeatureInfo. But:
 
 1. It works only for PostgreSQL connection, not with MySQL - is it 
 supposed to be so in MapServer 6? I saw the JOIN documentation changed and 
 there is no MySQL mentioned any more/
 2. I get nicely returned data from one-to-many join, using templates 
 (thanks to Ted Spradley post). But gml returns only the main data, not the 
 joined data. Is it supposed to be so?
 
 Thanks very much
 
 regards, dejan
 On 13. ruj. 2011., at 09:00, Dejan Gambin wrote:
 
 Some additional info:
 
 Since I need this data only for GetFeatureRequest, it seems like I should 
 use JOIN within a LAYER object. So I did the following:
 
 LAYER
 ...
   DATA my
   ...
   ...
   DUMP TRUE
   TEMPLATE template.html
   HEADER template_header.html
   FOOTER template_footer.html
   JOIN
 NAME test
 CONNECTION 
 MySQL:gis,host=localhost,user=gis,password=gis,tables=katastar_vodnjan
 #CONNECTION PG:host=localhost user=postgres password=runda711 
 dbname=vodnjan port=5432 
 CONNECTIONTYPE ogr
 TABLE katastar_vodnjan
 FROM KO_KC
 TO broj_ko_kc
 TYPE ONE-TO-MANY
 TEMPLATE template_join.html
 # HEADER template_header.html
 # FOOTER template_footer.html
   END  
 
 I tried this with joined data from MySQL and from Postgres. No success. 
 The interesting thing is, when I do:
 
 shp2img -m my.map -o image.png -l mylayer -all_debug 3
 
 I get:
 
 [Tue Sep 13 08:58:04 2011].271467 msLoadMap(): 0.029s
 [Tue Sep 13 08:58:04 2011].356888 msDrawMap(): Layer 0 
 (katastar_vodnjan_poligon), 0.083s
 [Tue Sep 13 08:58:04 2011].356943 msDrawMap(): Drawing Label Cache, 0.000s
 [Tue Sep 13 08:58:04 2011].356956 msDrawMap() total time: 0.085s
 [Tue Sep 13 08:58:04 2011].399386 msSaveImage() total time: 0.042s
 [Tue Sep 13 08:58:04 2011].402773 msPOSTGRESQLJoinClose() already close 
 or never opened.
 [Tue Sep 13 08:58:04 2011].402821 shp2img total time: 0.161s
 
 Does anybody  know what is it? It happens for MySQL and Postgres database 
 join
 
 thanks very much
 
 dejan
 
 
 On 12. ruj. 2011., at 14:03, Dejan Gambin wrote:
 
 Hi,
 
 After solving my compile problem (thanks to thomas), I need to do 
 GetFeatureInfo to a shape layer joined to MySQL table (non-spatial join).
 
 I compiled MapServer with MySQL support and everything seems ok, but 
 mapserv -v doesn't return INPUT=MYSQL. Is it supposed to anyway? Or 
 it is enough to be compiled with gdal/ogr that supports MySQL?
 
 Because - when I do this:
 
 ogrinfo -sql SELECT * FROM my LEFT JOIN 
 'MYSQL:gis,host=localhost,user=gis,password=gis'.katastar_vodnjan ON 
 my.KO_KC

Re: [mapserver-users] GetFeatureInfo using MySQL join - additional info

2011-09-13 Thread Dejan Gambin
Some additional info:

Since I need this data only for GetFeatureRequest, it seems like I should use 
JOIN within a LAYER object. So I did the following:

LAYER
...
  DATA my
  ...
  ...
  DUMP TRUE
  TEMPLATE template.html
  HEADER template_header.html
  FOOTER template_footer.html
  JOIN
NAME test
CONNECTION 
MySQL:gis,host=localhost,user=gis,password=gis,tables=katastar_vodnjan
#CONNECTION PG:host=localhost user=postgres password=runda711 
dbname=vodnjan port=5432 
CONNECTIONTYPE ogr
TABLE katastar_vodnjan
FROM KO_KC
TO broj_ko_kc
TYPE ONE-TO-MANY
TEMPLATE template_join.html
#   HEADER template_header.html
#   FOOTER template_footer.html
  END  

I tried this with joined data from MySQL and from Postgres. No success. The 
interesting thing is, when I do:

shp2img -m my.map -o image.png -l mylayer -all_debug 3

I get:

[Tue Sep 13 08:58:04 2011].271467 msLoadMap(): 0.029s
[Tue Sep 13 08:58:04 2011].356888 msDrawMap(): Layer 0 
(katastar_vodnjan_poligon), 0.083s
[Tue Sep 13 08:58:04 2011].356943 msDrawMap(): Drawing Label Cache, 0.000s
[Tue Sep 13 08:58:04 2011].356956 msDrawMap() total time: 0.085s
[Tue Sep 13 08:58:04 2011].399386 msSaveImage() total time: 0.042s
[Tue Sep 13 08:58:04 2011].402773 msPOSTGRESQLJoinClose() already close or 
never opened.
[Tue Sep 13 08:58:04 2011].402821 shp2img total time: 0.161s

Does anybody  know what is it? It happens for MySQL and Postgres database join

thanks very much

dejan


On 12. ruj. 2011., at 14:03, Dejan Gambin wrote:

 Hi,
 
 After solving my compile problem (thanks to thomas), I need to do 
 GetFeatureInfo to a shape layer joined to MySQL table (non-spatial join).
 
 I compiled MapServer with MySQL support and everything seems ok, but mapserv 
 -v doesn't return INPUT=MYSQL. Is it supposed to anyway? Or it is enough 
 to be compiled with gdal/ogr that supports MySQL?
 
 Because - when I do this:
 
 ogrinfo -sql SELECT * FROM my LEFT JOIN 
 'MYSQL:gis,host=localhost,user=gis,password=gis'.katastar_vodnjan ON 
 my.KO_KC=katastar_vodnjan.broj_ko_kc /var/www/data/vodnjan/my.shp
 
 I get all the attributes from shape (dbf) and MySQL, so everything seems fine
 
 But using thi:
 
 LAYER # katastar vodnjan poligoni
   NAME mylayer
   STATUS ON
   CONNECTIONTYPE ogr  
   CONNECTION /var/www/data/vodnjan/my.shp
   DATA SELECT * FROM my LEFT JOIN 
 'MYSQL:gis,host=localhost,user=gis,password=gis'.katastar_vodnjan ON 
 my.KO_KC=katastar_vodnjan.broj_ko_kc
   TYPE POLYGON  
 ...
 
 I don't get any information with GetFeatureInfo. The request is like:
 
 http://www.coin.hr/cgi-bin/mywms61?SERVICE=WMSVERSION=1.1.1REQUEST=GetFeatureInfoBBOX=5403800,4981350,5403980,4981460SRS=EPSG:31275WIDTH=400HEIGHT=300LAYERS=katastar_vodnjan_poligonSTYLES=FORMAT=image/pngTRANSPARENT=trueQUERY_LAYERS=mylayerINFO_FORMAT=gmlX=200Y=100
 
 Using the same request with regular mapfile:
 
 LAYER # katastar vodnjan poligoni
   NAME mylayer
   STATUS ON
   DATA my
   TYPE POLYGON  
 ...
 
 returns one feature and its attributes from the dbf (tha is OK)
 
 I have also tried with JOIN clause in LAYER part, but this doesn't work 
 either. Do I have to use owf? Am I doing something wrong?
 
 regards, dejan
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo using MySQL join - additional info

2011-09-13 Thread Dejan Gambin
I was finally successful with getting data from joined table through 
GetFeatureInfo. But:

1. It works only for PostgreSQL connection, not with MySQL - is it supposed to 
be so in MapServer 6? I saw the JOIN documentation changed and there is no 
MySQL mentioned any more/
2. I get nicely returned data from one-to-many join, using templates (thanks to 
Ted Spradley post). But gml returns only the main data, not the joined data. Is 
it supposed to be so?

Thanks very much

regards, dejan
On 13. ruj. 2011., at 09:00, Dejan Gambin wrote:

 Some additional info:
 
 Since I need this data only for GetFeatureRequest, it seems like I should use 
 JOIN within a LAYER object. So I did the following:
 
 LAYER
 ...
   DATA my
   ...
   ...
   DUMP TRUE
   TEMPLATE template.html
   HEADER template_header.html
   FOOTER template_footer.html
   JOIN
 NAME test
 CONNECTION 
 MySQL:gis,host=localhost,user=gis,password=gis,tables=katastar_vodnjan
 #CONNECTION PG:host=localhost user=postgres password=runda711 
 dbname=vodnjan port=5432 
 CONNECTIONTYPE ogr
 TABLE katastar_vodnjan
 FROM KO_KC
 TO broj_ko_kc
 TYPE ONE-TO-MANY
 TEMPLATE template_join.html
 # HEADER template_header.html
 # FOOTER template_footer.html
   END  
 
 I tried this with joined data from MySQL and from Postgres. No success. The 
 interesting thing is, when I do:
 
 shp2img -m my.map -o image.png -l mylayer -all_debug 3
 
 I get:
 
 [Tue Sep 13 08:58:04 2011].271467 msLoadMap(): 0.029s
 [Tue Sep 13 08:58:04 2011].356888 msDrawMap(): Layer 0 
 (katastar_vodnjan_poligon), 0.083s
 [Tue Sep 13 08:58:04 2011].356943 msDrawMap(): Drawing Label Cache, 0.000s
 [Tue Sep 13 08:58:04 2011].356956 msDrawMap() total time: 0.085s
 [Tue Sep 13 08:58:04 2011].399386 msSaveImage() total time: 0.042s
 [Tue Sep 13 08:58:04 2011].402773 msPOSTGRESQLJoinClose() already close or 
 never opened.
 [Tue Sep 13 08:58:04 2011].402821 shp2img total time: 0.161s
 
 Does anybody  know what is it? It happens for MySQL and Postgres database join
 
 thanks very much
 
 dejan
 
 
 On 12. ruj. 2011., at 14:03, Dejan Gambin wrote:
 
 Hi,
 
 After solving my compile problem (thanks to thomas), I need to do 
 GetFeatureInfo to a shape layer joined to MySQL table (non-spatial join).
 
 I compiled MapServer with MySQL support and everything seems ok, but 
 mapserv -v doesn't return INPUT=MYSQL. Is it supposed to anyway? Or it 
 is enough to be compiled with gdal/ogr that supports MySQL?
 
 Because - when I do this:
 
 ogrinfo -sql SELECT * FROM my LEFT JOIN 
 'MYSQL:gis,host=localhost,user=gis,password=gis'.katastar_vodnjan ON 
 my.KO_KC=katastar_vodnjan.broj_ko_kc /var/www/data/vodnjan/my.shp
 
 I get all the attributes from shape (dbf) and MySQL, so everything seems fine
 
 But using thi:
 
 LAYER # katastar vodnjan poligoni
   NAME mylayer
   STATUS ON
   CONNECTIONTYPE ogr  
   CONNECTION /var/www/data/vodnjan/my.shp
   DATA SELECT * FROM my LEFT JOIN 
 'MYSQL:gis,host=localhost,user=gis,password=gis'.katastar_vodnjan ON 
 my.KO_KC=katastar_vodnjan.broj_ko_kc
   TYPE POLYGON  
 ...
 
 I don't get any information with GetFeatureInfo. The request is like:
 
 http://www.coin.hr/cgi-bin/mywms61?SERVICE=WMSVERSION=1.1.1REQUEST=GetFeatureInfoBBOX=5403800,4981350,5403980,4981460SRS=EPSG:31275WIDTH=400HEIGHT=300LAYERS=katastar_vodnjan_poligonSTYLES=FORMAT=image/pngTRANSPARENT=trueQUERY_LAYERS=mylayerINFO_FORMAT=gmlX=200Y=100
 
 Using the same request with regular mapfile:
 
 LAYER # katastar vodnjan poligoni
   NAME mylayer
   STATUS ON
   DATA my
   TYPE POLYGON  
 ...
 
 returns one feature and its attributes from the dbf (tha is OK)
 
 I have also tried with JOIN clause in LAYER part, but this doesn't work 
 either. Do I have to use owf? Am I doing something wrong?
 
 regards, dejan
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users
 
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo using MySQL join - additional info

2011-09-13 Thread Dejan Gambin
Of course. And everything works when using ogrinfo for example

dejan
On 13. ruj. 2011., at 20:19, Carlos Ruiz wrote:

 Dejan,
 
 One question: If you look at the OGR supported formats, does MySQL appears ?
 
 Cheers from México
 
 IC Carlos Ruiz
 
 From: Dejan Gambin dejan.gam...@coin.hr
 To: mapserver-users@lists.osgeo.org
 Sent: Tuesday, September 13, 2011 8:13 AM
 Subject: Re: [mapserver-users] GetFeatureInfo using MySQL join - additional 
 info
 
 I was finally successful with getting data from joined table through 
 GetFeatureInfo. But:
 
 1. It works only for PostgreSQL connection, not with MySQL - is it supposed 
 to be so in MapServer 6? I saw the JOIN documentation changed and there is no 
 MySQL mentioned any more/
 2. I get nicely returned data from one-to-many join, using templates (thanks 
 to Ted Spradley post). But gml returns only the main data, not the joined 
 data. Is it supposed to be so?
 
 Thanks very much
 
 regards, dejan
 On 13. ruj. 2011., at 09:00, Dejan Gambin wrote:
 
 Some additional info:
 
 Since I need this data only for GetFeatureRequest, it seems like I should 
 use JOIN within a LAYER object. So I did the following:
 
 LAYER
 ...
   DATA my
   ...
   ...
   DUMP TRUE
   TEMPLATE template.html
   HEADER template_header.html
   FOOTER template_footer.html
   JOIN
 NAME test
 CONNECTION 
 MySQL:gis,host=localhost,user=gis,password=gis,tables=katastar_vodnjan
 #CONNECTION PG:host=localhost user=postgres password=runda711 
 dbname=vodnjan port=5432 
 CONNECTIONTYPE ogr
 TABLE katastar_vodnjan
 FROM KO_KC
 TO broj_ko_kc
 TYPE ONE-TO-MANY
 TEMPLATE template_join.html
 #HEADER template_header.html
 #FOOTER template_footer.html
   END  
 
 I tried this with joined data from MySQL and from Postgres. No success. The 
 interesting thing is, when I do:
 
 shp2img -m my.map -o image.png -l mylayer -all_debug 3
 
 I get:
 
 [Tue Sep 13 08:58:04 2011].271467 msLoadMap(): 0.029s
 [Tue Sep 13 08:58:04 2011].356888 msDrawMap(): Layer 0 
 (katastar_vodnjan_poligon), 0.083s
 [Tue Sep 13 08:58:04 2011].356943 msDrawMap(): Drawing Label Cache, 0.000s
 [Tue Sep 13 08:58:04 2011].356956 msDrawMap() total time: 0.085s
 [Tue Sep 13 08:58:04 2011].399386 msSaveImage() total time: 0.042s
 [Tue Sep 13 08:58:04 2011].402773 msPOSTGRESQLJoinClose() already close or 
 never opened.
 [Tue Sep 13 08:58:04 2011].402821 shp2img total time: 0.161s
 
 Does anybody  know what is it? It happens for MySQL and Postgres database 
 join
 
 thanks very much
 
 dejan
 
 
 On 12. ruj. 2011., at 14:03, Dejan Gambin wrote:
 
 Hi,
 
 After solving my compile problem (thanks to thomas), I need to do 
 GetFeatureInfo to a shape layer joined to MySQL table (non-spatial join).
 
 I compiled MapServer with MySQL support and everything seems ok, but 
 mapserv -v doesn't return INPUT=MYSQL. Is it supposed to anyway? Or it 
 is enough to be compiled with gdal/ogr that supports MySQL?
 
 Because - when I do this:
 
 ogrinfo -sql SELECT * FROM my LEFT JOIN 
 'MYSQL:gis,host=localhost,user=gis,password=gis'.katastar_vodnjan ON 
 my.KO_KC=katastar_vodnjan.broj_ko_kc /var/www/data/vodnjan/my.shp
 
 I get all the attributes from shape (dbf) and MySQL, so everything seems 
 fine
 
 But using thi:
 
 LAYER # katastar vodnjan poligoni
   NAME mylayer
   STATUS ON
   CONNECTIONTYPE ogr  
   CONNECTION /var/www/data/vodnjan/my.shp
   DATA SELECT * FROM my LEFT JOIN 
 'MYSQL:gis,host=localhost,user=gis,password=gis'.katastar_vodnjan ON 
 my.KO_KC=katastar_vodnjan.broj_ko_kc
   TYPE POLYGON  
 ...
 
 I don't get any information with GetFeatureInfo. The request is like:
 
 http://www.coin.hr/cgi-bin/mywms61?SERVICE=WMSVERSION=1.1.1REQUEST=GetFeatureInfoBBOX=5403800,4981350,5403980,4981460SRS=EPSG:31275WIDTH=400HEIGHT=300LAYERS=katastar_vodnjan_poligonSTYLES=FORMAT=image/pngTRANSPARENT=trueQUERY_LAYERS=mylayerINFO_FORMAT=gmlX=200Y=100
 
 Using the same request with regular mapfile:
 
 LAYER # katastar vodnjan poligoni
   NAME mylayer
   STATUS ON
   DATA my
   TYPE POLYGON  
 ...
 
 returns one feature and its attributes from the dbf (tha is OK)
 
 I have also tried with JOIN clause in LAYER part, but this doesn't work 
 either. Do I have to use owf? Am I doing something wrong?
 
 regards, dejan
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users
 
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users
 
 
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users
 
 

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetfeatureInfo-Request in an UTF-8 environment with shapfile in cp-1252

2011-02-09 Thread Milo van der Linden
Hello Andreas;

What return type of getfeatureinfo are you using?
There are three possibilities: http://mapserver.org/ogc/wms_server.html

1. text/plain
2. text/html
3. gml

If you use text/html; you can set the character encoding to windows ansi:

http://www.w3.org/International/questions/qa-html-encoding-declarations#quicklookup

If you use GML, because it is a flavour of XML, mapserver MUST serve
UNICODE:(UTF-8 or UTF-16);http://www.w3.org/TR/REC-xml/#sec-well-formed  So
if the gml output is not converted to unicode; please file a ticket for this
matter in the osgeo trac database.


2011/2/8 Tom van der Putte t...@vdputte.nl

 Hi Andreas,

 i looked it up, you can find it here:

 http://resources.arcgis.com/content/kbase?fa=articleShowd=21106

 Unfortunately I'm not aware of any means to automate the process of
 exporting the shapefiles, so you'd have to do it by hand.

 Tom

 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users


___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetfeatureInfo-Request in an UTF-8 environment with shapfile in cp-1252

2011-02-09 Thread Milo van der Linden
I found a ticket that is related to this issue:
http://trac.osgeo.org/gdal/wiki/rfc23_ogr_unicode


2011/2/9 Milo van der Linden m...@dogodigi.net

 Hello Andreas;

 What return type of getfeatureinfo are you using?
 There are three possibilities: http://mapserver.org/ogc/wms_server.html

 1. text/plain
 2. text/html
 3. gml

 If you use text/html; you can set the character encoding to windows ansi:


 http://www.w3.org/International/questions/qa-html-encoding-declarations#quicklookup

 If you use GML, because it is a flavour of XML, mapserver MUST serve
 UNICODE:(UTF-8 or UTF-16);http://www.w3.org/TR/REC-xml/#sec-well-formed
 So if the gml output is not converted to unicode; please file a ticket for
 this matter in the osgeo trac database.


 2011/2/8 Tom van der Putte t...@vdputte.nl

  Hi Andreas,

 i looked it up, you can find it here:

 http://resources.arcgis.com/content/kbase?fa=articleShowd=21106

 Unfortunately I'm not aware of any means to automate the process of
 exporting the shapefiles, so you'd have to do it by hand.

 Tom

 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users



___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


RE: [mapserver-users] GetfeatureInfo-Request in an UTF-8 environment with shapfile in cp-1252

2011-02-09 Thread Siegel Andreas
Hi Tom.
 
Thanks for your reply. But no, it is not an issue with ArcGIS.
The link you sent me may prove useful anyway since we rely heavy on shapefiles 
and ArcGIS ist used by several of our colleges and contributors.
 
My issue is this line of code:
meta http-equiv=Content-Type content=text/html; charset=MacThai/meta
Please note the charset MacThai. 
This charset should render my results illegible but it has no effect at all.
 
I test it by using a browser:
http://vogis.cnv.at/mapserver/mapserv?map=a.mapLAYERS=umlauttestSERVICE=WMSVERSION=1.1.1REQUEST=GetFeatureInfoSTYLES=EXCEPTIONS=application/vnd.ogc.se_xmlFORMAT=image/jpegSRS=EPSG:31254BBOX=-49500,246750,-49000,247250X=250Y=250INFO_FORMAT=text/htmlQUERY_LAYERS=umlauttestWIDTH=650HEIGHT=650FEATURE_COUNT=30
 
 and the commandline.
./mapserv -nh 
QUERY_STRING=map=a.mapLAYERS=umlauttestSERVICE=WMSVERSION=1.1.1REQUEST=GetFeatureInfoSTYLES=EXCEPTIONS=application/vnd.ogc.se_xmlFORMAT=image/jpegSRS=EPSG:31254BBOX=-49500,246750,-49000,247250X=250Y=250INFO_FORMAT=text/htmlQUERY_LAYERS=umlauttestWIDTH=650HEIGHT=650FEATURE_COUNT=30

The commandline output can be inspected by hexdump -C
 
./mapserv -nh 
QUERY_STRING=map=a.mapLAYERS=umlauttestSERVICE=WMSVERSION=1.1.1REQUEST=GetFeatureInfoSTYLES=EXCEPTIONS=application/vnd.ogc.se_xmlFORMAT=image/jpegSRS=EPSG:31254BBOX=-49500,246750,-49000,247250X=250Y=250INFO_FORMAT=text/htmlQUERY_LAYERS=umlauttestWIDTH=650HEIGHT=650FEATURE_COUNT=30
 | hexdump -c
 
This allows to inspect the result without some unwanted/unnoticed code 
translations when using an editor or the browser,

This are the HTML-Templates:
Header:
!-- MapServer Template --
 
!DOCTYPE HTML PUBLIC -//W3C//DTD HTML 4.01 Transitional//EN 
http://www.w3.org/TR/html4/transitional.dtd 
http://www.w3.org/TR/html4/transitional.dtd 
 
html
 
head
 
 !-- enforce the client to display result html as UTF-8 encoding --
 meta http-equiv=Content-Type content=text/html; charset=MacThai/meta
 
 style type=text/css
 
  table, th, td {
   border:1px solid #e5e5e5;
   border-collapse:collapse;
   font-family: arial;
   font-size: 80%;
   color: #33
  }
 
  th, td {
   valign: top;
   text-align: center;
  }
 
 th {
  background-color: #aed7ff
 }
 
 caption {
  border:1px solid #e5e5e5;
  border-collapse:collapse;
  font-family: arial;
  font-weight: bold;
  font-size: 80%;
  text-align: left;
  color: #33;
 }
 
 /style
 titleGetFeatureInfo Response/title
/head
 
body
 table
 
  captionWidmungsart Zeichensatztest ae ä oe ö ue ü AE Ä OE Ö UE Ü scharfes s 
ß Ende/caption
 
 tbody
  thKuerzel/th
  thWidmungsart/th
  thFlaeche/th
  thText/th
 
 
TEMPLATE:
 !-- MapServer Template --
 tr
   td[item name=WI_EM_KN format=$value escape=none]/td
   td[item name=WI_EM_TXT format=$value escape=none]/td
   td[item name=Flaeche format=$value escape=none]/td
   td[item name=FS_TXT  format=$value escape=none]/td
 /tr
 
 
FOOTER:
 !-- MapServer Template --
   /tbody
 /table
 br/
   /body
/html
 
 
 
 
 


 
 
 
 
 
 
 
Mag Andreas Siegel
Landesvermessungsamt Feldkirch
Johannitergasse 6, A-6800 Feldkirch
Tel: +43(0) 5522 / 75482 - 60227
Fax: +43(0) 5522 / 75482 - 6
E-Mail: andreas.sie...@vorarlberg.at 
mailto:andreas.andreas.sandreas.sie...@vorarlberg.at 
http://www.vorarlberg.at/lva
 
Rechtsverbindlichen Schriftverkehr
(zB Anträge, Rechtsmittel) richten Sie an:
E-Mail: landesvermessungs...@vorarlberg.at
Fax: +43(0)5522/75482-6
 
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetfeatureInfo-Request in an UTF-8 environment with shapfile in cp-1252

2011-02-09 Thread Milo van der Linden
There are errors in the usage of 

I think that:

meta http-equiv=Content-Type content=text/html;
charset=x-mac-thai/meta

is the correct one.


http://www.w3.org/International/O-HTTP-charset


2011/2/9 Siegel Andreas andreas.sie...@vorarlberg.at

  Hi Tom.

 Thanks for your reply. But no, it is not an issue with ArcGIS.
 The link you sent me may prove useful anyway since we rely heavy on
 shapefiles and ArcGIS ist used by several of our colleges and contributors.

 My issue is this line of code:
 meta http-equiv=Content-Type content=text/html;
 charset=MacThai/meta
 Please note the charset MacThai.
 This charset should render my results illegible but it has no effect at
 all.

 I test it by using a browser:

 http://vogis.cnv.at/mapserver/mapserv?map=a.mapLAYERS=umlauttestSERVICE=WMSVERSION=1.1.1REQUEST=GetFeatureInfoSTYLES=EXCEPTIONS=application/vnd.ogc.se_xmlFORMAT=image/jpegSRS=EPSG:31254BBOX=-49500,246750,-49000,247250X=250Y=250INFO_FORMAT=text/htmlQUERY_LAYERS=umlauttestWIDTH=650HEIGHT=650FEATURE_COUNT=30

  and the commandline.
 ./mapserv -nh
 QUERY_STRING=map=a.mapLAYERS=umlauttestSERVICE=WMSVERSION=1.1.1REQUEST=GetFeatureInfoSTYLES=EXCEPTIONS=application/vnd.ogc.se_xmlFORMAT=image/jpegSRS=EPSG:31254BBOX=-49500,246750,-49000,247250X=250Y=250INFO_FORMAT=text/htmlQUERY_LAYERS=umlauttestWIDTH=650HEIGHT=650FEATURE_COUNT=30
  The commandline output can be inspected by hexdump -C

 ./mapserv -nh
 QUERY_STRING=map=a.mapLAYERS=umlauttestSERVICE=WMSVERSION=1.1.1REQUEST=GetFeatureInfoSTYLES=EXCEPTIONS=application/vnd.ogc.se_xmlFORMAT=image/jpegSRS=EPSG:31254BBOX=-49500,246750,-49000,247250X=250Y=250INFO_FORMAT=text/htmlQUERY_LAYERS=umlauttestWIDTH=650HEIGHT=650FEATURE_COUNT=30
 | hexdump -c

 This allows to inspect the result without some unwanted/unnoticed code
 translations when using an editor or the browser,

 This are the HTML-Templates:
 Header:
 !-- MapServer Template --

 !DOCTYPE HTML PUBLIC -//W3C//DTD HTML 4.01 Transitional//EN 
 http://www.w3.org/TR/html4/transitional.dtd;

 html

 head

  !-- enforce the client to display result html as UTF-8 encoding --
  meta http-equiv=Content-Type content=text/html;
 charset=MacThai/meta

  style type=text/css

   table, th, td {
border:1px solid #e5e5e5;
border-collapse:collapse;
font-family: arial;
font-size: 80%;
color: #33
   }

   th, td {
valign: top;
text-align: center;
   }

  th {
   background-color: #aed7ff
  }

  caption {
   border:1px solid #e5e5e5;
   border-collapse:collapse;
   font-family: arial;
   font-weight: bold;
   font-size: 80%;
   text-align: left;
   color: #33;
  }

  /style
  titleGetFeatureInfo Response/title
 /head

 body
  table

   captionWidmungsart Zeichensatztest ae ä oe ö ue ü AE Ä OE Ö UE Ü
 scharfes s ß Ende/caption

  tbody
   thKuerzel/th
   thWidmungsart/th
   thFlaeche/th
   thText/th


 TEMPLATE:
  !-- MapServer Template --
  tr
td[item name=WI_EM_KN format=$value escape=none]/td
td[item name=WI_EM_TXT format=$value escape=none]/td
td[item name=Flaeche format=$value escape=none]/td
td[item name=FS_TXT  format=$value escape=none]/td
  /tr


 FOOTER:
  !-- MapServer Template --
/tbody
  /table
  br/
/body
 /html














  *Mag Andreas Siegel*
 Landesvermessungsamt Feldkirch
 Johannitergasse 6, A-6800 Feldkirch
 Tel: +43(0) 5522 / 75482 - 60227
 Fax: +43(0) 5522 / 75482 - 6
  E-Mail: 
 andreas.sie...@vorarlberg.atandreas.andreas.sandreas.sie...@vorarlberg.at
 http://www.vorarlberg.at/lva

 Rechtsverbindlichen Schriftverkehr
 (zB Anträge, Rechtsmittel) richten Sie an:
 E-Mail: landesvermessungs...@vorarlberg.at
 Fax: +43(0)5522/75482-6


 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users


___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetfeatureInfo-Request in an UTF-8 environmentwith shapfile in cp-1252

2011-02-09 Thread Rahkonen Jukka
Hi,
 
For those willing to change shapefile character encoding physically, OpenJUMP 
(www.openjump.org) is nowadays a handy tool for changing the codepages.  Just 
select the codepage to use when opening the shapefile, and similarly codepage 
to use when saving shapefile through Save Dataset As  Version 1.4.x of 
OpenJUMP is needed and codepage query must be activated first from the 
Customize - Options menu item.
 
-Jukka Rahkonen-
 
 





Lähettäjä: mapserver-users-boun...@lists.osgeo.org 
[mailto:mapserver-users-boun...@lists.osgeo.org] Puolesta Siegel Andreas
Lähetetty: 9. helmikuuta 2011 11:20
Vastaanottaja: mapserver-users@lists.osgeo.org
Aihe: RE: [mapserver-users] GetfeatureInfo-Request in an UTF-8 
environmentwith shapfile in cp-1252


Hi Tom.
 
Thanks for your reply. But no, it is not an issue with ArcGIS.
The link you sent me may prove useful anyway since we rely heavy on 
shapefiles and ArcGIS ist used by several of our colleges and contributors.
 
 

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetfeatureInfo-Request in an UTF-8 environment with shapfile in cp-1252

2011-02-09 Thread Daniel Morissette

On 11-02-08 09:37 AM, Siegel Andreas wrote:

Hi.
Our mapserver-eniromnent entirely works in utf-8 (mapfiles, webserver,
postgres, ..) with one exception, that is, all of our shapefiles.
The shapfiles are created/updated in an Windows-environment by several,
external contributors.
Hence they are encoded in Wiindows-ANSI (cp: 1252).
If i do an GetFeatureInfo-Request on the attibutes of the shapefiles all
special characters (umlauts) are garbled.
This is no wonder since the content of the shapefile-attributes must be
recoded to utf-8 prior to insertion in the template.html.
How can this be acomplished? I could not find anything useful in the
documentation or with google.


The short answer is that there is no mechanism in MapServer at the 
moment to convert encoding of attributes displayed in a query template, 
so your only options are to either change the encoding of the data files 
to UTF-8, or change the template.html and its header to match the 
encoding of the data. (The only place where MapServer supports encoding 
conversion at the moment is in map labels, see the ENCODING keyword in 
the LABEL docs.)


Of course this could be a nice enhancement to MapServer if there was a 
group interested in funding it.


Daniel
--
Daniel Morissette
http://www.mapgears.com/
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetfeatureInfo-Request in an UTF-8 environment with shapfile in cp-1252

2011-02-09 Thread Yewondwossen Assefa

On 09/02/2011 7:34 AM, Daniel Morissette wrote:

On 11-02-08 09:37 AM, Siegel Andreas wrote:

Hi.
Our mapserver-eniromnent entirely works in utf-8 (mapfiles, webserver,
postgres, ..) with one exception, that is, all of our shapefiles.
The shapfiles are created/updated in an Windows-environment by several,
external contributors.
Hence they are encoded in Wiindows-ANSI (cp: 1252).
If i do an GetFeatureInfo-Request on the attibutes of the shapefiles all
special characters (umlauts) are garbled.
This is no wonder since the content of the shapefile-attributes must be
recoded to utf-8 prior to insertion in the template.html.
How can this be acomplished? I could not find anything useful in the
documentation or with google.


The short answer is that there is no mechanism in MapServer at the 
moment to convert encoding of attributes displayed in a query 
template, so your only options are to either change the encoding of 
the data files to UTF-8, or change the template.html and its header to 
match the encoding of the data. (The only place where MapServer 
supports encoding conversion at the moment is in map labels, see the 
ENCODING keyword in the LABEL docs.)


Of course this could be a nice enhancement to MapServer if there was a 
group interested in funding it.


Daniel


Sorry to jump late on this. This issue I believe was identified and 
described in the trac bug [1]. An incomplete solutions was proposed in 
there but It definitely need more thinking.


[1] http://trac.osgeo.org/mapserver/ticket/3297

Assefa

--

Assefa Yewondwossen
Software Analyst

Email: yass...@dmsolutions.ca
http://www.dmsolutions.ca/

Phone: (613) 565-5056 (ext 14)
Fax:   (613) 565-0925



___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetfeatureInfo-Request in an UTF-8 environment with shapfile in cp-1252

2011-02-08 Thread Jeff McKenna

Hello,

A quick thought that I had when I read your issue, is that I recently 
came across a similar issue when I was working with Japanese data.  In 
that case for MapServer to display query results in my template 
properly, I had to change the character set in the HTML template file, 
otherwise the characters would be garbled:


!-- MapServer Template --
html
head
meta http-equiv=Content-Type content=text/html; charset=Shift_JIS
title照会/title
...

I'm not sure if that is related to your exact issue, but those are my 
quick thoughts.


-jeff


--
Jeff McKenna
MapServer Consulting and Training Services
http://www.gatewaygeomatics.com/




On 11-02-08 10:37 AM, Siegel Andreas wrote:

Hi.
Our mapserver-eniromnent entirely works in utf-8 (mapfiles, webserver,
postgres, ..) with one exception, that is, all of our shapefiles.
The shapfiles are created/updated in an Windows-environment by several,
external contributors.
Hence they are encoded in Wiindows-ANSI (cp: 1252).
If i do an GetFeatureInfo-Request on the attibutes of the shapefiles all
special characters (umlauts) are garbled.
This is no wonder since the content of the shapefile-attributes must be
recoded to utf-8 prior to insertion in the template.html.
How can this be acomplished? I could not find anything useful in the
documentation or with google.
*Mag Andreas Siegel*

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


RE: [mapserver-users] GetfeatureInfo-Request in an UTF-8 environment with shapfile in cp-1252

2011-02-08 Thread Tom van der Putte
Hi
Andreas,
 i looked it up, you can find it here:
 http://resources.arcgis.com/content/kbase?fa=articleShowd=21106
 Unfortunately I'm not aware of any means to automate the process of
exporting the shapefiles, so you'd have to do it by hand.
 Tom
  ___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


RE: [mapserver-users] GetFeatureInfo

2010-12-17 Thread David Hildebrand
The tolerance parameter was the trick, Jeff.  Thanks.

===
David V. Hildebrand
Agriculture Financial Services Corporation
(403) 782-8239   

www.afsc.ca http://www.afsc.ca
This communication is intended for the use of the recipient to which it
is addressed, and may contain confidential, personal and/or privileged
information. Please contact Agriculture Financial Services Corporation
immediately if you are not the intended recipient of this communication,
and do not copy, distribute, or take action relying on it. Any
communication received in error, or subsequent reply, should be deleted
or destroyed. Please consider the environment before printing this
email.

-Original Message-
From: mapserver-users-boun...@lists.osgeo.org
[mailto:mapserver-users-boun...@lists.osgeo.org] On Behalf Of Jeff
McKenna
Sent: Thursday, December 16, 2010 1:57 PM
To: mapserver-users@lists.osgeo.org
Subject: Re: [mapserver-users] GetFeatureInfo

On 10-12-16 4:41 PM, David Hildebrand wrote:
 I have several WMS layers. One is a polygon layer and the other two
are
 line and point layer. I have HTML templates for each layer which are
 very similar. All the layers are being drawn but when I run a
 REQUEST=GetFeatureInfo on a location which has features from all three
 layers I only get a return from the polygon layer. I have the
following
 debug statements in my mapfile.


Hi,

Just a quick note, that the WMS Server doc gives a working example of a 
GetFeatureInfo request on a point layer: 
http://demo.mapserver.org/cgi-bin/wms?SERVICE=WMSVERSION=1.1.1REQUEST=
GetFeatureInfoBBOX=-11.332970,24.121208,47.584718,57.965035SRS=EPSG:43
26WIDTH=1001HEIGHT=575LAYERS=citiesSTYLES=FORMAT=image/pngTRANSPAR
ENT=trueQUERY_LAYERS=citiesINFO_FORMAT=text/plainX=229Y=280

I would make sure your layers have a template set, as well as modify the

tolerance parameter possibly.

-jeff



-- 
Jeff McKenna
MapServer Consulting and Training Services
http://www.gatewaygeomatics.com/


___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo

2010-12-16 Thread Jeff McKenna

On 10-12-16 4:41 PM, David Hildebrand wrote:

I have several WMS layers. One is a polygon layer and the other two are
line and point layer. I have HTML templates for each layer which are
very similar. All the layers are being drawn but when I run a
REQUEST=GetFeatureInfo on a location which has features from all three
layers I only get a return from the polygon layer. I have the following
debug statements in my mapfile.



Hi,

Just a quick note, that the WMS Server doc gives a working example of a 
GetFeatureInfo request on a point layer: 
http://demo.mapserver.org/cgi-bin/wms?SERVICE=WMSVERSION=1.1.1REQUEST=GetFeatureInfoBBOX=-11.332970,24.121208,47.584718,57.965035SRS=EPSG:4326WIDTH=1001HEIGHT=575LAYERS=citiesSTYLES=FORMAT=image/pngTRANSPARENT=trueQUERY_LAYERS=citiesINFO_FORMAT=text/plainX=229Y=280


I would make sure your layers have a template set, as well as modify the 
tolerance parameter possibly.


-jeff



--
Jeff McKenna
MapServer Consulting and Training Services
http://www.gatewaygeomatics.com/


___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo - get wms_title

2010-12-15 Thread Daniel Morissette
steve.tout...@inspq.qc.ca wrote:
 
 Hi,
 I use INFO_FORMAT=gml for a GetFeatureInfo request. It works, but I
 would like to get the wms_title instead of the layers name.
 
 In the UI people are seeing the title not the name. Showing the name of
 a layer is useless in our context.
 Is it possible to retreive the wms_title if it exists?


It seems that there is a nice undocumented feature to do what you want
(I found it in the code just now):

Add a wms_layername metadata to your layer definition and this value
will be used as the layer name in the GetFeatureInfo GML output. (The
default is to use the layer name + _layer (e.g. parks_layer for a
layer named parks)

Daniel
-- 
Daniel Morissette
http://www.mapgears.com/
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo - get wms_title

2010-12-15 Thread Steve . Toutant
Hi daniel,
It seems that only the parameter NAME of the LAYER key is used by 
getFeatureInfo. the wms_name of the METADATA is not used.
I tried to set wms_layername in the METADATA but I get an error and no 
response. I tried with wms_layer_name and the query's result still returns 
LAYER NAME

Steve




Daniel Morissette dmorisse...@mapgears.com@lists.osgeo.org 
Envoyé par : mapserver-users-boun...@lists.osgeo.org
2010-12-15 12:16

A
mapserver-users@lists.osgeo.org
cc

Objet
Re: [mapserver-users] GetFeatureInfo - get wms_title








steve.tout...@inspq.qc.ca wrote:
 
 Hi,
 I use INFO_FORMAT=gml for a GetFeatureInfo request. It works, but I
 would like to get the wms_title instead of the layers name.
 
 In the UI people are seeing the title not the name. Showing the name of
 a layer is useless in our context.
 Is it possible to retreive the wms_title if it exists?


It seems that there is a nice undocumented feature to do what you want
(I found it in the code just now):

Add a wms_layername metadata to your layer definition and this value
will be used as the layer name in the GetFeatureInfo GML output. (The
default is to use the layer name + _layer (e.g. parks_layer for a
layer named parks)

Daniel
-- 
Daniel Morissette
http://www.mapgears.com/
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users



___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo - get wms_title

2010-12-15 Thread Steve . Toutant
wms_layername works. 
the given name should not have spaces in it. Otherwise the MGL is not 
valid.
Steve




Daniel Morissette dmorisse...@mapgears.com@lists.osgeo.org 
Envoyé par : mapserver-users-boun...@lists.osgeo.org
2010-12-15 12:16

A
mapserver-users@lists.osgeo.org
cc

Objet
Re: [mapserver-users] GetFeatureInfo - get wms_title








steve.tout...@inspq.qc.ca wrote:
 
 Hi,
 I use INFO_FORMAT=gml for a GetFeatureInfo request. It works, but I
 would like to get the wms_title instead of the layers name.
 
 In the UI people are seeing the title not the name. Showing the name of
 a layer is useless in our context.
 Is it possible to retreive the wms_title if it exists?


It seems that there is a nice undocumented feature to do what you want
(I found it in the code just now):

Add a wms_layername metadata to your layer definition and this value
will be used as the layer name in the GetFeatureInfo GML output. (The
default is to use the layer name + _layer (e.g. parks_layer for a
layer named parks)

Daniel
-- 
Daniel Morissette
http://www.mapgears.com/
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users



___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo over OGR OCI Layer

2010-10-06 Thread Sebastian E. Ovide
does

ogrinfo OCI:admcarto/admca...@ora10gex GV_SIGPAC_REC_ED50

work ?

On Fri, Oct 1, 2010 at 12:25 PM, David Alda Fernandez de Lezea da...@ikt.es
 wrote:

 Hi list,

 I'm trying to execute a GetFeatureInfo request over an Oracle layer via
 OGR. I can view the content of the layer, but when I make the request I
 don't get any result. I mean, I receive an empty GML. My layer config:

 LAYER
STATUS ON
CONNECTION OCI:admcarto/admca...@ora10gex
CONNECTIONTYPE OGR
DATA GV_SIGPAC_REC_ED50 #todo el sigpac
NAME RecintosSigpacOGR
PROJECTION
init=epsg:23030
END
DUMP TRUE
TYPE POLYGON
METADATA
wms_title   Recintos Sigpac
 2009
wms_srs EPSG:23030
wms_nameRecintosSigpacOGR
wms_server_version  1.1.1
wms_format  image/gif
wms_transparent true
wms_extent  46 469 61
 482
wms_include_items   all
gml_include_items all
END
MAXSCALE 1

TEMPLATE ms_template.html
PROCESSING LABEL_NO_CLIP=ON
PROCESSING CLOSE_CONNECTION=DEFER
SYMBOLSCALE 5000

#Simbologia
CLASSGROUP Simbologia_Recintos
CLASS
TEXT ([PARCELA]:[RECINTO])
STYLE
OUTLINECOLOR 0 234 0
END
LABEL
COLOR 254 254 255
OUTLINECOLOR 0 0 0
TYPE truetype
FONT sans
SIZE 6
POSITION cc
PARTIALS TRUE
END
NAME RecintosSigPac
GROUP Referencia_Sigpac
END

CLASS
STYLE
OUTLINECOLOR 0 234 0
WIDTH 1
END
NAME RecintosSigPac
GROUP Predeterminado
END

END

 Resultant file

 ?xml version=1.0 encoding=ISO-8859-1?

 msGMLOutput
 xmlns:gml=http://www.opengis.net/gml;
 xmlns:xlink=http://www.w3.org/1999/xlink;
 xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
 /msGMLOutput

 Any ideas? Something wrong configured?

 Thanks.


 Un saludo,


 ··

 David Alda Fernández de Lezea
 Lurralde eta Biodibertsitate Saila / Dpto. de Territorio y Biodiversidad

 IKT
 Granja Modelo s/n · 01192 · Arkaute (Araba)


 ··
 Tlfnos.: 945-00-32-95 Fax: 945-00.32.90

 ··
 email: da...@ikt.esweb: www.ikt.es

 ··
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users




-- 
Sebastian E. Ovide
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


RE: [mapserver-users] GetFeatureInfo from a JavaScript client [SOLVED]

2010-06-10 Thread David Alda Fernandez de Lezea
Hi Jukka,

Definetaly you're a Master!! That pointed me the right way. The asp web proxy 
was truncating the url passed as parameter to him, so I made some changes and 
it worked.

Thanks man, what a relief...

Regards,
 
Un saludo,
 
··

David Alda Fernández de Lezea
Lurralde eta Biodibertsitate Saila / Dpto. de Territorio y Biodiversidad
 
IKT
Granja Modelo s/n · 01192 · Arkaute (Araba)

··
Tlfnos.: 945-00-32-95 Fax: 945-00.32.90
··
email: da...@ikt.esweb: www.ikt.es
··

-Mensaje original-
De: Rahkonen Jukka [mailto:jukka.rahko...@mmmtike.fi] 
Enviado el: jueves, 10 de junio de 2010 12:15
Para: David Alda Fernandez de Lezea; mapserver-users@lists.osgeo.org
Asunto: Re: [mapserver-users] GetFeatureInfo from a JavaScript client

Hi,

Mapserver does probably not receive a valid GetFeatureInfo request. Open the 
Apache access log file and see what is coming in. You can also test the request 
from browser.

-Jukka Rahkonen-

David Alda Fernandez de Lezea wrote: 


 Hi folks,

 My situation: We've developed a GIS web viewer based on OpenLayers, with some 
 particular configurations, and is located in a server, let's called Server 
 A, and we also have some other web applications that include this viewer to 
 show some information and they're located in Server B. The thing is that to 
 avoid the cross-domain problem we've created an ASP script located in Server 
 B that calls mapserver to receive the getfeatureinfo request, but when I try 
 it in my web browser I get the following message:

 mapserv(): Web application error. Traditional BROWSE mode requires a TEMPLATE 
 in the WEB section, but none was provided.

MapFile:

MAP
NAME WMSSERVER
STATUS ON   
EXTENT 46 469 61 482 # Euskadi

SHAPEPATH shapes_estaticos/
FONTSET misc/fonts/fonts.txt

UNITS METERS

DEBUG ON
CONFIG MS_ERRORFILE C:/ms4w/Apache/htdocs/MFD/tmp/ms_wms.log
DEBUG 5

OUTPUTFORMAT
   NAME gif
   DRIVER GD/GIF
   MIMETYPE image/gif
   IMAGEMODE PC256
   EXTENSION gif
END
WEB
IMAGEPATH C:/ms4w/Apache/htdocs/MFD/tmp/
IMAGEURL tmp/
METADATA  
wms_name  IKT WMS Server
wms_server_version  1.1.1
wms_title Servidor WMS IKT
wms_onlineresource
http://192.168.1.65/cgi-bin/mapserv.exe?map=../htdocs/MFD/ejemplo_wms.map;
wms_srs   EPSG:23030 EPSG:4326
wms_transparent   true
wms_abstract  Servicio de mapas WMS 
de IKT Nekazal Teknologia. Powered by Apache and UMN MapServer
wms_keywordlist   IKT,Euskadi,Mapas 
Euskadi
wms_feature_info_mime_type   application/vnd.ogc.gml
labelcache_map_edge_buffer -10 
END
END

PROJECTION
init=epsg:23030
END

LAYER
STATUS ON
CONNECTIONTYPE oraclespatial
CONNECTION admcarto/admca...@ora10gex
NAME RecintosSigpac
PROJECTION
init=epsg:23030
END
DUMP TRUE
TYPE POLYGON
METADATA
wms_title Recintos Sigpac 2009
wms_srs EPSG:23030
wms_nameRecintosSigpac
wms_server_version  1.1.1
wms_format  image/gif
wms_transparent true
END 
MAXSCALE 25000
DATA GEOMETRY FROM (SELECT * FROM GT_SIGPAC_REC_2010_ED50) 
USING UNIQUE gid SRID 82337 #todo el sigpac

CLASS
NAME Recintos
STYLE
OUTLINECOLOR 0 234 0
END
TEMPLATE ms_template.html
END
END
END

I've got ms_template.html created with the magic string. 

What I'm doing wrong??

Thanks.
 
 
Un saludo

RE: [mapserver-users] GetFeatureInfo request doubts

2010-05-24 Thread David Alda Fernandez de Lezea
Hello Jukka, 

I think now I've understood how getFeatureInfo works in mapserver.

Thanks.

-Mensaje original-
De: Rahkonen Jukka [mailto:jukka.rahko...@mmmtike.fi] 
Enviado el: viernes, 21 de mayo de 2010 14:18
Para: David Alda Fernandez de Lezea; mapserver-users@lists.osgeo.org
Asunto: Re: [mapserver-users] GetFeatureInfo request doubts

Hi,

This is indeed a little bit odd.

This is captured from http://mapserver.org/ogc/wms_server.html

# GetFeatureInfo: return info about feature(s) at a query (mouse click) 
location. MapServer supports 3 types of responses to this request:

* text/plain output with attribute info.
* text/html output using MapServer query templates specified in the CLASS 
template parameter. The MIME type returned by the Class templates defaults to 
text/html and can be controlled using the metadata wms_feature_info_mime_type.
* application/vnd.ogc.gml, GML.1 or GML for GML features.



For making the layer queryable at all there must have a TEMPLATE line in LAYER 
definitions.
TEMPLATE d:/program files/ms4w/apps/template.html

The template file must exist and it must validate the security test Templates 
must contain the magic string 'mapserver template' in the first line of the 
template.

Now when you have TEMPLATE set and valid template file on disk your server 
should support GetFeatureInfo. The only supported info_format now it 
text/plain. However, it does not give any other info about features than a 
feature ID.
You must add first a line into LAYER-METADATA wms_include_items all starts 
to sent all the attributes wms_include_items SPA,SCI,SCI2  selects the 
named attributes. Attributes must be comma separated but there must not be any 
white space characters.

Now you should be able to get results as plain text.  Adding support for gml 
output is done by adding DUMP TRUE into LAYER definitions.  Now 
INFO_FORMAT=application/vnd.ogc.gml  However, you will need to define what will 
be includen in the output by adding gml_include_items all or something.

If you want to give also output as text/html you must do two further things:
- add to LAYER wms_feature_info_mime_type text/html
- creare valid template, header and footer documents on server. You did have a 
template file already, that is compulsory for making GetFeatureInfo work at 
all, but until now it could be just a fake file.

There is some extra magic with metadata inputs, for example ows_include_items 
should be enought instead of using both the wms_include_items and gml_include 
items.  But by remembering these four things, reading the documentation and 
experimenting you will do it.

TEMPLATE - to turn it on
DUMP TRUE - to make it support gml
wms_feature_info_mime_type - to make it support text/html ***_include_items 
- to make is send some usable info

I hope I have understood it right, I have not used GetFeatureInfo very often.

-Jukka Rahkonen-




 -Alkuperäinen viesti-
 Lähettäjä: mapserver-users-boun...@lists.osgeo.org
 [mailto:mapserver-users-boun...@lists.osgeo.org] Puolesta David Alda 
 Fernandez de Lezea
 Lähetetty: 21. toukokuuta 2010 14:29
 Vastaanottaja: mapserver-users@lists.osgeo.org
 Aihe: [mapserver-users] GetFeatureInfo request doubts
 
 Hi,
 
 I've got a WMS service through MapServer, and I want that the layers 
 served in it be queryable through Desktop GIS software. How many ways 
 are there to present the information?? I'm going crazy because of the 
 documentation, I don't understand the differences between using 
 wms_feture_info_mime_type or DUMP TRUE, etc.
 
 Can someone help me?
 
 Thanks. 
  
 Un saludo,
  
 ··
 
 
 David Alda Fernández de Lezea
 Lurralde eta Biodibertsitate Saila / Dpto. de Territorio y 
 Biodiversidad
  
 IKT
 Granja Modelo s/n · 01192 · Arkaute (Araba)
 
 ··
 
 Tlfnos.: 945-00-32-95 Fax: 945-00.32.90
 ··
 
 email: da...@ikt.esweb: www.ikt.es
 ··
 
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users
 
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo request doubts

2010-05-21 Thread Rahkonen Jukka
Hi,

This is indeed a little bit odd.

This is captured from http://mapserver.org/ogc/wms_server.html

# GetFeatureInfo: return info about feature(s) at a query (mouse click) 
location. MapServer supports 3 types of responses to this request:

* text/plain output with attribute info.
* text/html output using MapServer query templates specified in the CLASS 
template parameter. The MIME type returned by the Class templates defaults to 
text/html and can be controlled using the metadata wms_feature_info_mime_type.
* application/vnd.ogc.gml, GML.1 or GML for GML features.



For making the layer queryable at all there must have a TEMPLATE line in LAYER 
definitions.
TEMPLATE d:/program files/ms4w/apps/template.html

The template file must exist and it must validate the security test
Templates must contain the magic string 'mapserver template' in the first line 
of the template.

Now when you have TEMPLATE set and valid template file on disk your server 
should support GetFeatureInfo. The only supported info_format now it 
text/plain. However, it does not give any other info about features than a 
feature ID.
You must add first a line into LAYER-METADATA
wms_include_items all starts to sent all the attributes
wms_include_items SPA,SCI,SCI2  selects the named attributes. Attributes 
must be comma separated but there must not be any white space characters.

Now you should be able to get results as plain text.  Adding support for gml 
output is done by adding DUMP TRUE into LAYER definitions.  Now 
INFO_FORMAT=application/vnd.ogc.gml  However, you will need to define what will 
be includen in the output by adding gml_include_items all or something.

If you want to give also output as text/html you must do two further things:
- add to LAYER wms_feature_info_mime_type text/html
- creare valid template, header and footer documents on server. You did have a 
template file already, that is compulsory for making GetFeatureInfo work at 
all, but until now it could be just a fake file.

There is some extra magic with metadata inputs, for example ows_include_items 
should be enought instead of using both the wms_include_items and gml_include 
items.  But by remembering these four things, reading the documentation and 
experimenting you will do it.

TEMPLATE - to turn it on
DUMP TRUE - to make it support gml
wms_feature_info_mime_type - to make it support text/html
***_include_items - to make is send some usable info

I hope I have understood it right, I have not used GetFeatureInfo very often.

-Jukka Rahkonen-




 -Alkuperäinen viesti-
 Lähettäjä: mapserver-users-boun...@lists.osgeo.org 
 [mailto:mapserver-users-boun...@lists.osgeo.org] Puolesta 
 David Alda Fernandez de Lezea
 Lähetetty: 21. toukokuuta 2010 14:29
 Vastaanottaja: mapserver-users@lists.osgeo.org
 Aihe: [mapserver-users] GetFeatureInfo request doubts
 
 Hi, 
 
 I've got a WMS service through MapServer, and I want that the 
 layers served in it be queryable through Desktop GIS 
 software. How many ways are there to present the 
 information?? I'm going crazy because of the documentation, I 
 don't understand the differences between using 
 wms_feture_info_mime_type or DUMP TRUE, etc.
 
 Can someone help me?
 
 Thanks. 
  
 Un saludo,
  
 ··
 
 
 David Alda Fernández de Lezea
 Lurralde eta Biodibertsitate Saila / Dpto. de Territorio y 
 Biodiversidad
  
 IKT
 Granja Modelo s/n · 01192 · Arkaute (Araba)
 
 ··
 
 Tlfnos.: 945-00-32-95 Fax: 945-00.32.90
 ··
 
 email: da...@ikt.esweb: www.ikt.es
 ··
 
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users
 
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo returns no results. Why?

2010-05-18 Thread Rahkonen Jukka
Hi,
 
First, the image coordinates x=9.5y=50 do not hit Germany.  Try with 475,98 
and you will get something back but I am not sure if it is Germany either.  To 
get what you want you must also tell in the mapfile what attributes should be 
included in the response with wms_include_items
 
-Jukka Rahkonen-




Lähettäjä: mapserver-users-boun...@lists.osgeo.org 
[mailto:mapserver-users-boun...@lists.osgeo.org] Puolesta Stefan Schwarzer
Lähetetty: 18. toukokuuta 2010 9:57
Vastaanottaja: mapserver-users@lists.osgeo.org
Aihe: [mapserver-users] GetFeatureInfo returns no results. Why?


Hi there,

I am having problems getting a correct GetFeatureInfo from my WMS. 
The URL looks fine, but I get this message:
GetFeatureInfo results:

  Search returned no results.

The WMS works well: 

http://metafunctions.grid.unep.ch/cgi-bin/mapserv?map=/www/geodataportal/htdocs/mod_map/geo_wms_complete_last_year.map;
service=wms
version=1.1.1
request=getmap
format=image/png
width=900
height=450
srs=EPSG:4326
bbox=-180,-90,180,90
layers=co2_gdp

The GetFeatureInfo looks like this: 

http://metafunctions.grid.unep.ch/cgi-bin/mapserv?map=/www/geodataportal/htdocs/mod_map/geo_wms_complete_last_year.map;
version=1.1.1
request=getfeatureinfo
width=900
height=450
srs=EPSG:4326
bbox=-180,-90,180,90
x=9.5y=50
query_layers=co2_gdp
layers=co2_gdp

It should return the value for Germany. Here is the MAPserver code:
   LAYER
NAME co2_gdp  
METADATA 
'wms_title' 'Emissions of CO2 per 
GDP (PPP)'
'wms_timeextent'  '2006'
'wms_extent' '-180 -90 180 90'
   END # METADATA
PROJECTION
'init=epsg:4326'
END
STATUS OFF
CONNECTIONTYPE postgis
CONNECTION 'xxx'  
TYPE POLYGON
DATA the_geom FROM  
TEMPLATE 'dummy'
DUMP TRUE
CLASSITEM 'value'
..

Do I need to add something? Thanks for any adivce,

Stefan



___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Getfeatureinfo and MSsql 2008 server

2010-02-26 Thread Tamas Szekeres
How about setting the TOLERANCE parameter for the layer in the mapfile?

Best regards,

Tamas

2010/2/26 Afroz K afr...@gmail.com

 Dear Tamaz,
 I guess this cannot be done as I am not using QuerybyPoint.
 I just use the GetfeatureInfo from my html page.

 Thanks
 Afroz

 On Fri, Feb 26, 2010 at 2:06 AM, Tamas Szekeres szeker...@gmail.comwrote:

 Afroz,

 This error message says you must specify a search shape with area  0
 during the query. Assuming you use a queryByPoint operation, either the
 buffer parameter of the tolerance of the layer should be specified as a
 positive number.

 Best regards,

 Tamas



 2010/2/25 Afroz Kannancheri afr...@gmail.com


 Hi All,

 I have a layer drawn from the shape information stored in MSSQL 2008
 server.
 The layer has around 300 polygons which are drawn perfectly on a world
 base
 map.
 When i try to get the details for each polygon using the Getfeatureinfo
 during the click event, i get the following error from MSSQL 2008 server.

 msMSSQL2008LayerGetShape(): Query error. Error executing MSSQL2008 SQL
 statement: SELECT convert(varchar(max), numb1),convert(varchar(max),
 poprate),geom.STAsBinary(),convert(varchar(20), ID) from table1 WHERE
 geom.STIntersects(Geometry::STGeomFromText('POLYGON((-16.4101563310658
 17.724609875,-16.4101563310658 17.724609875,-16.4101563310658
 17.724609875,-16.4101563310658 17.724609875,-16.4101563310658
 17.724609875))',0)) = 1 -[Microsoft][ODBC SQL Server Driver][SQL Server]A
 .NET Framework error occurred during execution of user defined routine or
 aggregate 'geometry': System.FormatException: 24118: The Polygon input is
 not valid because the exterior ring does not have enough points. Each
 ring
 of a polygon must contain at least three distinct points.
 System.FormatException: at
 Microsoft.SqlServer.Types.GeometryDataBuilder.EndFigure() at

 Microsoft.SqlServer.Types.OpenGisWktReader.ParseLineStringText(FigureAttributes
 attributes) at
 Microsoft.SqlServer.Types.OpenGisWktReader.ParsePolygonText()
 at Microsoft.SqlServer.Types.OpenGisWktReader.ParsePolygonTaggedText() at
 Microsoft.SqlServer.Types.OpenGisWktReader.ParseGeometryTaggedText() at
 Microsoft.SqlServer.Types.OpenGisWktReader.ReadGeometry() at
 Microsoft.SqlServer.Types.SqlGeometry.STGeomFromText(SqlChars
 geometryTaggedText, Int32 srid)


 Has anyone faced such an issue before.


 Thanks and regards
 AFroz Kannancheri
 --
 View this message in context:
 http://n2.nabble.com/Getfeatureinfo-and-MSsql-2008-server-tp4631717p4631717.html
 Sent from the Mapserver - User mailing list archive at Nabble.com.
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users




___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Getfeatureinfo and MSsql 2008 server

2010-02-25 Thread Paul james
The Mssql2008 driver is incomplete...
GetFeatureInfo, Nquery, Query doesnt work at all...

http://trac.osgeo.org/mapserver/ticket/3058

Paul

On Thu, Feb 25, 2010 at 7:57 AM, Afroz Kannancheri afr...@gmail.com wrote:


 Hi All,

 I have a layer drawn from the shape information stored in MSSQL 2008
 server.
 The layer has around 300 polygons which are drawn perfectly on a world base
 map.
 When i try to get the details for each polygon using the Getfeatureinfo
 during the click event, i get the following error from MSSQL 2008 server.

 msMSSQL2008LayerGetShape(): Query error. Error executing MSSQL2008 SQL
 statement: SELECT convert(varchar(max), numb1),convert(varchar(max),
 poprate),geom.STAsBinary(),convert(varchar(20), ID) from table1 WHERE
 geom.STIntersects(Geometry::STGeomFromText('POLYGON((-16.4101563310658
 17.724609875,-16.4101563310658 17.724609875,-16.4101563310658
 17.724609875,-16.4101563310658 17.724609875,-16.4101563310658
 17.724609875))',0)) = 1 -[Microsoft][ODBC SQL Server Driver][SQL Server]A
 .NET Framework error occurred during execution of user defined routine or
 aggregate 'geometry': System.FormatException: 24118: The Polygon input is
 not valid because the exterior ring does not have enough points. Each ring
 of a polygon must contain at least three distinct points.
 System.FormatException: at
 Microsoft.SqlServer.Types.GeometryDataBuilder.EndFigure() at

 Microsoft.SqlServer.Types.OpenGisWktReader.ParseLineStringText(FigureAttributes
 attributes) at
 Microsoft.SqlServer.Types.OpenGisWktReader.ParsePolygonText()
 at Microsoft.SqlServer.Types.OpenGisWktReader.ParsePolygonTaggedText() at
 Microsoft.SqlServer.Types.OpenGisWktReader.ParseGeometryTaggedText() at
 Microsoft.SqlServer.Types.OpenGisWktReader.ReadGeometry() at
 Microsoft.SqlServer.Types.SqlGeometry.STGeomFromText(SqlChars
 geometryTaggedText, Int32 srid)


 Has anyone faced such an issue before.


 Thanks and regards
 AFroz Kannancheri
 --
 View this message in context:
 http://n2.nabble.com/Getfeatureinfo-and-MSsql-2008-server-tp4631781p4631781.html
 Sent from the Mapserver - User mailing list archive at Nabble.com.
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Getfeatureinfo and MSsql 2008 server

2010-02-25 Thread James Perrins
.queryByPoint works OK for me from C# mapscript




On Thu, Feb 25, 2010 at 11:51 AM, Paul james paulj...@gmail.com wrote:
 The Mssql2008 driver is incomplete...
 GetFeatureInfo, Nquery, Query doesnt work at all...

 http://trac.osgeo.org/mapserver/ticket/3058

 Paul

 On Thu, Feb 25, 2010 at 7:57 AM, Afroz Kannancheri afr...@gmail.com wrote:

 Hi All,

 I have a layer drawn from the shape information stored in MSSQL 2008
 server.
 The layer has around 300 polygons which are drawn perfectly on a world
 base
 map.
 When i try to get the details for each polygon using the Getfeatureinfo
 during the click event, i get the following error from MSSQL 2008 server.

 msMSSQL2008LayerGetShape(): Query error. Error executing MSSQL2008 SQL
 statement: SELECT convert(varchar(max), numb1),convert(varchar(max),
 poprate),geom.STAsBinary(),convert(varchar(20), ID) from table1 WHERE
 geom.STIntersects(Geometry::STGeomFromText('POLYGON((-16.4101563310658
 17.724609875,-16.4101563310658 17.724609875,-16.4101563310658
 17.724609875,-16.4101563310658 17.724609875,-16.4101563310658
 17.724609875))',0)) = 1 -[Microsoft][ODBC SQL Server Driver][SQL Server]A
 .NET Framework error occurred during execution of user defined routine or
 aggregate 'geometry': System.FormatException: 24118: The Polygon input is
 not valid because the exterior ring does not have enough points. Each ring
 of a polygon must contain at least three distinct points.
 System.FormatException: at
 Microsoft.SqlServer.Types.GeometryDataBuilder.EndFigure() at

 Microsoft.SqlServer.Types.OpenGisWktReader.ParseLineStringText(FigureAttributes
 attributes) at
 Microsoft.SqlServer.Types.OpenGisWktReader.ParsePolygonText()
 at Microsoft.SqlServer.Types.OpenGisWktReader.ParsePolygonTaggedText() at
 Microsoft.SqlServer.Types.OpenGisWktReader.ParseGeometryTaggedText() at
 Microsoft.SqlServer.Types.OpenGisWktReader.ReadGeometry() at
 Microsoft.SqlServer.Types.SqlGeometry.STGeomFromText(SqlChars
 geometryTaggedText, Int32 srid)


 Has anyone faced such an issue before.


 Thanks and regards
 AFroz Kannancheri
 --
 View this message in context:
 http://n2.nabble.com/Getfeatureinfo-and-MSsql-2008-server-tp4631781p4631781.html
 Sent from the Mapserver - User mailing list archive at Nabble.com.
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users


 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users





-- 
Dr James Perrins
exeGesIS SDM Ltd
Great House Barn
New Street, Talgarth
Powys LD3 0AH.
Direct Line: 01646 686650
Tel: 01874 711145
Fax: 01874 711156
Email: jam...@esdm.co.uk

This E-mail and any files transmitted with it are private and intended
solely for the use of the individual or entity to whom they are
addressed. If you are not the intended recipient, the E-mail and any
files have been transmitted to you in error and any copying,
distribution or other use of the information contained in them is
strictly prohibited.

Nothing in this E-mail message amounts to a contractual or other legal
commitment on the part of exeGesIS SDM Ltd unless confirmed by a
signed communication.

exeGesIS SDM Ltd will make every effort to keep its network free of
viruses. However, the recipient of this message will need to scan this
message, and any attachments, for viruses, as exeGesIS SDM Ltd can
take no responsibility for any computer virus that might be
transferred by this e-mail.
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Getfeatureinfo and MSsql 2008 server

2010-02-25 Thread Tamas Szekeres
 Afroz,

This error message says you must specify a search shape with area  0 during
the query. Assuming you use a queryByPoint operation, either the buffer
parameter of the tolerance of the layer should be specified as a positive
number.

Best regards,

Tamas



2010/2/25 Afroz Kannancheri afr...@gmail.com


 Hi All,

 I have a layer drawn from the shape information stored in MSSQL 2008
 server.
 The layer has around 300 polygons which are drawn perfectly on a world base
 map.
 When i try to get the details for each polygon using the Getfeatureinfo
 during the click event, i get the following error from MSSQL 2008 server.

 msMSSQL2008LayerGetShape(): Query error. Error executing MSSQL2008 SQL
 statement: SELECT convert(varchar(max), numb1),convert(varchar(max),
 poprate),geom.STAsBinary(),convert(varchar(20), ID) from table1 WHERE
 geom.STIntersects(Geometry::STGeomFromText('POLYGON((-16.4101563310658
 17.724609875,-16.4101563310658 17.724609875,-16.4101563310658
 17.724609875,-16.4101563310658 17.724609875,-16.4101563310658
 17.724609875))',0)) = 1 -[Microsoft][ODBC SQL Server Driver][SQL Server]A
 .NET Framework error occurred during execution of user defined routine or
 aggregate 'geometry': System.FormatException: 24118: The Polygon input is
 not valid because the exterior ring does not have enough points. Each ring
 of a polygon must contain at least three distinct points.
 System.FormatException: at
 Microsoft.SqlServer.Types.GeometryDataBuilder.EndFigure() at

 Microsoft.SqlServer.Types.OpenGisWktReader.ParseLineStringText(FigureAttributes
 attributes) at
 Microsoft.SqlServer.Types.OpenGisWktReader.ParsePolygonText()
 at Microsoft.SqlServer.Types.OpenGisWktReader.ParsePolygonTaggedText() at
 Microsoft.SqlServer.Types.OpenGisWktReader.ParseGeometryTaggedText() at
 Microsoft.SqlServer.Types.OpenGisWktReader.ReadGeometry() at
 Microsoft.SqlServer.Types.SqlGeometry.STGeomFromText(SqlChars
 geometryTaggedText, Int32 srid)


 Has anyone faced such an issue before.


 Thanks and regards
 AFroz Kannancheri
 --
 View this message in context:
 http://n2.nabble.com/Getfeatureinfo-and-MSsql-2008-server-tp4631717p4631717.html
 Sent from the Mapserver - User mailing list archive at Nabble.com.
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Getfeatureinfo and MSsql 2008 server

2010-02-25 Thread Tamas Szekeres
Paul,

I don't see any compelling reason why these use cases wouldn't work. Could
you provide a sample data/mapfile/example URL to reproduce this?

Best regards,

Tamas



2010/2/25 Paul james paulj...@gmail.com

 The Mssql2008 driver is incomplete...
 GetFeatureInfo, Nquery, Query doesnt work at all...

 http://trac.osgeo.org/mapserver/ticket/3058

 Paul


 On Thu, Feb 25, 2010 at 7:57 AM, Afroz Kannancheri afr...@gmail.comwrote:


 Hi All,

 I have a layer drawn from the shape information stored in MSSQL 2008
 server.
 The layer has around 300 polygons which are drawn perfectly on a world
 base
 map.
 When i try to get the details for each polygon using the Getfeatureinfo
 during the click event, i get the following error from MSSQL 2008 server.

 msMSSQL2008LayerGetShape(): Query error. Error executing MSSQL2008 SQL
 statement: SELECT convert(varchar(max), numb1),convert(varchar(max),
 poprate),geom.STAsBinary(),convert(varchar(20), ID) from table1 WHERE
 geom.STIntersects(Geometry::STGeomFromText('POLYGON((-16.4101563310658
 17.724609875,-16.4101563310658 17.724609875,-16.4101563310658
 17.724609875,-16.4101563310658 17.724609875,-16.4101563310658
 17.724609875))',0)) = 1 -[Microsoft][ODBC SQL Server Driver][SQL Server]A
 .NET Framework error occurred during execution of user defined routine or
 aggregate 'geometry': System.FormatException: 24118: The Polygon input is
 not valid because the exterior ring does not have enough points. Each ring
 of a polygon must contain at least three distinct points.
 System.FormatException: at
 Microsoft.SqlServer.Types.GeometryDataBuilder.EndFigure() at

 Microsoft.SqlServer.Types.OpenGisWktReader.ParseLineStringText(FigureAttributes
 attributes) at
 Microsoft.SqlServer.Types.OpenGisWktReader.ParsePolygonText()
 at Microsoft.SqlServer.Types.OpenGisWktReader.ParsePolygonTaggedText() at
 Microsoft.SqlServer.Types.OpenGisWktReader.ParseGeometryTaggedText() at
 Microsoft.SqlServer.Types.OpenGisWktReader.ReadGeometry() at
 Microsoft.SqlServer.Types.SqlGeometry.STGeomFromText(SqlChars
 geometryTaggedText, Int32 srid)


 Has anyone faced such an issue before.


 Thanks and regards
 AFroz Kannancheri
 --
 View this message in context:
 http://n2.nabble.com/Getfeatureinfo-and-MSsql-2008-server-tp4631781p4631781.html
 Sent from the Mapserver - User mailing list archive at Nabble.com.
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users



 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users


___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Getfeatureinfo and MSsql 2008 server

2010-02-25 Thread afrozk
Dear tamas, 
I'll try the buffer  parameter that u have mentioned once I m back in office on 
sunday and update u guys about the output.

Thanks a lot guys..
Sent from my BlackBerry® smartphone from du

-Original Message-
From: Tamas Szekeres szeker...@gmail.com
Date: Thu, 25 Feb 2010 23:06:47 
To: Afroz Kannancheriafr...@gmail.com
Cc: mapserver-users@lists.osgeo.org
Subject: Re: [mapserver-users] Getfeatureinfo and MSsql 2008 server

 Afroz,

This error message says you must specify a search shape with area  0 during
the query. Assuming you use a queryByPoint operation, either the buffer
parameter of the tolerance of the layer should be specified as a positive
number.

Best regards,

Tamas



2010/2/25 Afroz Kannancheri afr...@gmail.com


 Hi All,

 I have a layer drawn from the shape information stored in MSSQL 2008
 server.
 The layer has around 300 polygons which are drawn perfectly on a world base
 map.
 When i try to get the details for each polygon using the Getfeatureinfo
 during the click event, i get the following error from MSSQL 2008 server.

 msMSSQL2008LayerGetShape(): Query error. Error executing MSSQL2008 SQL
 statement: SELECT convert(varchar(max), numb1),convert(varchar(max),
 poprate),geom.STAsBinary(),convert(varchar(20), ID) from table1 WHERE
 geom.STIntersects(Geometry::STGeomFromText('POLYGON((-16.4101563310658
 17.724609875,-16.4101563310658 17.724609875,-16.4101563310658
 17.724609875,-16.4101563310658 17.724609875,-16.4101563310658
 17.724609875))',0)) = 1 -[Microsoft][ODBC SQL Server Driver][SQL Server]A
 .NET Framework error occurred during execution of user defined routine or
 aggregate 'geometry': System.FormatException: 24118: The Polygon input is
 not valid because the exterior ring does not have enough points. Each ring
 of a polygon must contain at least three distinct points.
 System.FormatException: at
 Microsoft.SqlServer.Types.GeometryDataBuilder.EndFigure() at

 Microsoft.SqlServer.Types.OpenGisWktReader.ParseLineStringText(FigureAttributes
 attributes) at
 Microsoft.SqlServer.Types.OpenGisWktReader.ParsePolygonText()
 at Microsoft.SqlServer.Types.OpenGisWktReader.ParsePolygonTaggedText() at
 Microsoft.SqlServer.Types.OpenGisWktReader.ParseGeometryTaggedText() at
 Microsoft.SqlServer.Types.OpenGisWktReader.ReadGeometry() at
 Microsoft.SqlServer.Types.SqlGeometry.STGeomFromText(SqlChars
 geometryTaggedText, Int32 srid)


 Has anyone faced such an issue before.


 Thanks and regards
 AFroz Kannancheri
 --
 View this message in context:
 http://n2.nabble.com/Getfeatureinfo-and-MSsql-2008-server-tp4631717p4631717.html
 Sent from the Mapserver - User mailing list archive at Nabble.com.
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users


___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Getfeatureinfo and MSsql 2008 server

2010-02-25 Thread Afroz K
Dear Tamaz,
I guess this cannot be done as I am not using QuerybyPoint.
I just use the GetfeatureInfo from my html page.

Thanks
Afroz

On Fri, Feb 26, 2010 at 2:06 AM, Tamas Szekeres szeker...@gmail.com wrote:

 Afroz,

 This error message says you must specify a search shape with area  0
 during the query. Assuming you use a queryByPoint operation, either the
 buffer parameter of the tolerance of the layer should be specified as a
 positive number.

 Best regards,

 Tamas



 2010/2/25 Afroz Kannancheri afr...@gmail.com


 Hi All,

 I have a layer drawn from the shape information stored in MSSQL 2008
 server.
 The layer has around 300 polygons which are drawn perfectly on a world
 base
 map.
 When i try to get the details for each polygon using the Getfeatureinfo
 during the click event, i get the following error from MSSQL 2008 server.

 msMSSQL2008LayerGetShape(): Query error. Error executing MSSQL2008 SQL
 statement: SELECT convert(varchar(max), numb1),convert(varchar(max),
 poprate),geom.STAsBinary(),convert(varchar(20), ID) from table1 WHERE
 geom.STIntersects(Geometry::STGeomFromText('POLYGON((-16.4101563310658
 17.724609875,-16.4101563310658 17.724609875,-16.4101563310658
 17.724609875,-16.4101563310658 17.724609875,-16.4101563310658
 17.724609875))',0)) = 1 -[Microsoft][ODBC SQL Server Driver][SQL Server]A
 .NET Framework error occurred during execution of user defined routine or
 aggregate 'geometry': System.FormatException: 24118: The Polygon input is
 not valid because the exterior ring does not have enough points. Each ring
 of a polygon must contain at least three distinct points.
 System.FormatException: at
 Microsoft.SqlServer.Types.GeometryDataBuilder.EndFigure() at

 Microsoft.SqlServer.Types.OpenGisWktReader.ParseLineStringText(FigureAttributes
 attributes) at
 Microsoft.SqlServer.Types.OpenGisWktReader.ParsePolygonText()
 at Microsoft.SqlServer.Types.OpenGisWktReader.ParsePolygonTaggedText() at
 Microsoft.SqlServer.Types.OpenGisWktReader.ParseGeometryTaggedText() at
 Microsoft.SqlServer.Types.OpenGisWktReader.ReadGeometry() at
 Microsoft.SqlServer.Types.SqlGeometry.STGeomFromText(SqlChars
 geometryTaggedText, Int32 srid)


 Has anyone faced such an issue before.


 Thanks and regards
 AFroz Kannancheri
 --
 View this message in context:
 http://n2.nabble.com/Getfeatureinfo-and-MSsql-2008-server-tp4631717p4631717.html
 Sent from the Mapserver - User mailing list archive at Nabble.com.
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users



___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo-Capabilites of WMS-mapfiles

2009-12-08 Thread Bart van den Eijnden
Why do you want to remove it? It just shows that the service is capable of 
handling that request. If there are no queryable layers I client won't attempt 
the request.

Best regards,
Bart

On Dec 8, 2009, at 5:18 PM, Stephan Holl wrote:

 Dear mapserver-users,
 
 I am inspecting the Capabilities-document of my WMS-Server-mapfile.
 
 None of my layers do have GetFeatureInfo-possibilities (queryable=0),
 but my Capabilities also contain the following passage:
 
 GetFeatureInfo
  Formattext/plain/Format
  Formatapplication/vnd.ogc.gml/Format
  DCPType
HTTP
  Get
OnlineResource
 xmlns:xlink=http://www.w3.org/1999/xlink;
 xlink:href=http://sercer.tld?;
 xlink:type=simple/ /Get
  Post
OnlineResource
 xmlns:xlink=http://www.w3.org/1999/xlink;
 xlink:href=http://server.tld?;
 xlink:type=simple/ /Post
/HTTP
  /DCPType
/GetFeatureInfo
 
 which is IMO useless.
 
 Is there a possibility to reduce this if no queryable layers are there?
 I cannot find any configuration hints right now. Thanks for any hints.
 
 TIA.
 
 Best
 
   Stephan
 
 -- 
 Stephan Holl stephan.h...@intevation.de | Tel.: +49 (0)541-33 508 3663
 Intevation GmbH, Neuer Graben 17, 49074 OS  |  AG Osnabrück - HR B 18998
 Geschäftsführer:  Frank Koormann, Bernhard Reiter, Dr. Jan-Oliver Wagner
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo request documentation

2009-12-08 Thread Daniel Morissette

Ted Spradley wrote:

Hi all,

I have a working GetFeatureInfo request thanks to posts here on the list.  I
notice various posts referring to documentation I am unable to find however. 
In particular, one post referred to wms_include|exclude_items and for

the life of me I can not find any documentation referring to the particular
wms_include_items metadata parameter.  


Am I missing something?  About the only detailed documentation I can find on
the subject is http://mapserver.org/ogc/wms_server.html



The wms_include|exclude_items metadata are actually the same as the 
gml_include|exclude_items, just with a different prefix which means 
that they are specific to the WMS protocol (applied to GetFeatureInfo in 
GML format in this case) and not applied to GML generation in general. 
You'll find docs for gml_include_items and gml_exclude_items in the same 
document at:


http://www.mapserver.org/ogc/wms_server.html#layer-object-metadata

Daniel
--
Daniel Morissette
http://www.mapgears.com/
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo request documentation

2009-12-08 Thread Ted Spradley

Thanks much for the explanation Daniel!
  - Original Message - 
  From: Daniel Morissette [via OSGeo.org] 
  To: Ted Spradley 
  Sent: Tuesday, December 08, 2009 3:32 PM
  Subject: Re: [mapserver-users] GetFeatureInfo request documentation


  Ted Spradley wrote: 

   Hi all, 
   
   I have a working GetFeatureInfo request thanks to posts here on the list.  
I 
   notice various posts referring to documentation I am unable to find 
however. 
   In particular, one post referred to wms_include|exclude_items and for 
   the life of me I can not find any documentation referring to the particular 
   wms_include_items metadata parameter.   
   
   Am I missing something?  About the only detailed documentation I can find 
on 
   the subject is http://mapserver.org/ogc/wms_server.html
   

  The wms_include|exclude_items metadata are actually the same as the 
  gml_include|exclude_items, just with a different prefix which means 
  that they are specific to the WMS protocol (applied to GetFeatureInfo in 
  GML format in this case) and not applied to GML generation in general. 
  You'll find docs for gml_include_items and gml_exclude_items in the same 
  document at: 

  http://www.mapserver.org/ogc/wms_server.html#layer-object-metadata

  Daniel 
  -- 
  Daniel Morissette 
  http://www.mapgears.com/
  ___ 
  mapserver-users mailing list 
  [hidden email] 
  http://lists.osgeo.org/mailman/listinfo/mapserver-users



--

  View message @ 
http://n2.nabble.com/GetFeatureInfo-request-documentation-tp4134366p4135526.html
 
  To unsubscribe from GetFeatureInfo request documentation, click here. 


-- 
View this message in context: 
http://n2.nabble.com/GetFeatureInfo-request-documentation-tp4134366p4135741.html
Sent from the Mapserver - User mailing list archive at Nabble.com.
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] getFeatureInfo from Postgis

2009-10-23 Thread Dan Little
Does the PostGIS layer Map correctly?


From: Iratxe Lejarreta iratxe.lejarr...@axios.es
To: mapserver-users@lists.osgeo.org
Sent: Fri, October 23, 2009 5:34:44 AM
Subject: [mapserver-users] getFeatureInfo from Postgis

Hi,


I can't get the information (getFeatureInfo) of the features from Postgis with 
EPSG:23030, but the same request from a shapefile gives me the info.
I can get info from another layer with EPSG:4326, but not with EPSG:23030.
Is it some bug in MapServer?
Thanks!


-- 
Iratxe Lejarreta
www.axios.es


  ___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] getFeatureInfo from Postgis

2009-10-23 Thread Iratxe Lejarreta
On Friday 23 October 2009 12:34:44 pm Iratxe Lejarreta wrote:
 Hi,

 I can't get the information (getFeatureInfo) of the features from Postgis
 with EPSG:23030, but the same request from a shapefile gives me the info. I
 can get info from another layer with EPSG:4326, but not with EPSG:23030. Is
 it some bug in MapServer?
 Thanks!

Hi,
I solved my problem. 
I tried with another layer with the same proyection and I can get the info. 
Maybe my data have errors in database...
Thanks!

-- 
Iratxe Lejarreta
www.axios.es
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo

2009-10-06 Thread Iratxe Lejarreta
On Monday 05 October 2009 09:26:35 pm Rahkonen Jukka wrote:
 Hi,

 X and y in GetFeatureInfo request are image pixel coordinates, not
 geographic ones.  See how ESRI describes it
 http://webhelp.esri.com/arcims/9.2/general/mergedProjects/wms_connect/wms_c
onnector/get_featureinfo.htm

 -Jukka Rahkonen-



 Iratxe Lejarreta wrote:

 Hi,

 When I execute the following command, Postfix return the correct result:
 select * from building where
 ST_INTERSECTS(geom,'SRID=23030;POINT(579389.40625 4795144.78125)');

 But when I execute GetFeatureInfo request in MapServer with the same
 point(x,y), the response doesn't return any result:
 http://localhost/cgi-
 
bin/test?SERVICE=wmsVERSION=1.1.1REQUEST=getfeatureinfoLAYERS=mylayerQ
UERY_LAYERS=mylayerx=579389.40625y=479511.78125INFO_FORMAT=text/htmlSRS=
EPSG:23030BBOX=532666.0,4749720.0,603151.0,4805350.0WIDTH=512HEIGHT=512

 My map file:

 MAP
 NAME TEST
 STATUS ON
 SIZE 400 300
 SYMBOLSET symbols.sym
 EXTENT 53 474 61 482
 UNITS METERS
 SHAPEPATH data
 IMAGECOLOR 255 255 255
 FONTSET fonts.txt

 WEB
 IMAGEPATH /tmp/
 IMAGEURL /tmp/
 HEADER ../templates/test_header.html
 FOOTER ../templates/test_footer.html
 METADATA
 wms_title Test
 wms_onlineresourcehttp://localhost/cgi-bin/test?;
 wms_srs   EPSG:23030
 wms_feature_info_mime_typetext/html
 END
 END

 PROJECTION
 init=epsg:23030
 END

 LAYER
 NAME mylayer
 PROJECTION
 init=epsg:23030
 END
 TYPE POLYGON
 STATUS ON
 DUMP TRUE
 UNITS METERS
 TEMPLATE ../templates/mylayer_body.html
 CONNECTIONTYPE postgis
 CONNECTION host=localhost port=5432 dbname=mydb user=postgres
 password=**
 DATA the_geom from mylayer
 METADATA
 wms_title mylayer
 wms_srs   EPSG:23030
 wms_extent532666 4749720 603151 4805350
 wms_feature_info_mime_typetext/html
 wms_include_items all
 END
 TOLERANCE 5
 CLASS
 NAME building
 STYLE
 COLOR 200 255 0
 OUTLINECOLOR 120 120 120
 END
   END
 END

 END


 I tried the same map configuration with another layer but with SRS:4326 and
 the result of GetFeatureInfo request is ok.
 If the difference is the projection and extent, where is the error?

 Thanks in advance!

Ok, I changed X and Y but the result is null.
The same request with shapefile gives me the result that I want, but with 
postgis I don't receive any result.
Is there any bug with MapServer and Postgis in a different projection than 
4326?
Thanks!
-- 
Iratxe Lejarreta
www.axios.es
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo

2009-10-05 Thread Rahkonen Jukka
Hi,

X and y in GetFeatureInfo request are image pixel coordinates, not geographic 
ones.  See how ESRI describes it
http://webhelp.esri.com/arcims/9.2/general/mergedProjects/wms_connect/wms_connector/get_featureinfo.htm

-Jukka Rahkonen-



Iratxe Lejarreta wrote:
 
Hi,

When I execute the following command, Postfix return the correct result:
select * from building where ST_INTERSECTS(geom,'SRID=23030;POINT(579389.40625 
4795144.78125)');

But when I execute GetFeatureInfo request in MapServer with the same 
point(x,y), the response doesn't return any result:
http://localhost/cgi-
bin/test?SERVICE=wmsVERSION=1.1.1REQUEST=getfeatureinfoLAYERS=mylayerQUERY_LAYERS=mylayerx=579389.40625y=479511.78125INFO_FORMAT=text/htmlSRS=EPSG:23030BBOX=532666.0,4749720.0,603151.0,4805350.0WIDTH=512HEIGHT=512

My map file:

MAP
NAME TEST
STATUS ON
SIZE 400 300
SYMBOLSET symbols.sym
EXTENT 53 474 61 482
UNITS METERS
SHAPEPATH data
IMAGECOLOR 255 255 255
FONTSET fonts.txt

WEB
IMAGEPATH /tmp/
IMAGEURL /tmp/
HEADER ../templates/test_header.html
FOOTER ../templates/test_footer.html
METADATA
wms_title Test
wms_onlineresourcehttp://localhost/cgi-bin/test?;
wms_srs   EPSG:23030
wms_feature_info_mime_typetext/html
END
END

PROJECTION
init=epsg:23030
END

LAYER
NAME mylayer
PROJECTION
init=epsg:23030
END
TYPE POLYGON
STATUS ON
DUMP TRUE
UNITS METERS
TEMPLATE ../templates/mylayer_body.html
CONNECTIONTYPE postgis
CONNECTION host=localhost port=5432 dbname=mydb user=postgres 
password=**
DATA the_geom from mylayer
METADATA
wms_title mylayer
wms_srs   EPSG:23030
wms_extent532666 4749720 603151 4805350
wms_feature_info_mime_typetext/html
wms_include_items all
END
TOLERANCE 5
CLASS
NAME building
STYLE
COLOR 200 255 0
OUTLINECOLOR 120 120 120
END
END
END

END


I tried the same map configuration with another layer but with SRS:4326 and the 
result of GetFeatureInfo request is ok. 
If the difference is the projection and extent, where is the error?

Thanks in advance!

-- 
Iratxe Lejarreta
www.axios.es

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


RE: [mapserver-users] GetFeatureInfo - something not adding up

2009-07-02 Thread Fawcett, David
It may be the case that MapServer isn't recognizing the variables
because they are in the wrong case.  I believe that when the columns
come from a shapefile, the column names are all upper case.  Try
changing all of the substitution vars in your template to upper case.  

David.  



-Original Message-
From: mapserver-users-boun...@lists.osgeo.org
[mailto:mapserver-users-boun...@lists.osgeo.org] On Behalf Of stretch
Sent: Thursday, July 02, 2009 11:03 AM
To: mapserver-users@lists.osgeo.org
Subject: [mapserver-users] GetFeatureInfo - something not adding up



Hi All

I am doing a GetFeatureInfo Through Openlayers. All seems to be working
fine (i.e. template comes up) except it is not returning any values.
What happens is that template is returned but the values are not
populated - i.e Compt
No: [Compt_No] instead of Compt_no: A03 etc

Here is my URL

http://localhost/cgi-bin/masonite.asp?mf=bartonheights.mapLAYERS=Compar
tmentsSERVICE=WMSVERSION=1.0.0REQUEST=GetFeatureInfoSTYLES=EXCEPTIO
NS=application%2Fvnd.ogc.se_xmlFORMAT=pngSRS=EPSG%3A2054BBOX=-81259.3
86908%2C-3308449.52709%2C-73921.613092%2C-3305902.47291X=342Y=226INFO
_FORMAT=text%2FhtmlQUERY_LAYERS=CompartmentsWIDTH=1040HEIGHT=361



My Map file (parts of it)
   # WMS server settings
METADATA
 'wms_title'   'masonite'
 'wms_onlineresource'  'http://z/masonite.asp?'
 'wms_srs' 'EPSG:2054'
  'wms_feature_info_mime_type' 'text/html'
  'ows_include_items' 'all' 
END


LAYER
NAME 'Compartments'
TYPE POLYGON
DATA 'Farms\BartonHeights\Basedata\Compartments.shp'
TEMPLATE Compartments.html  #For select feature
TOLERANCE 15 
TOLERANCEUNITS PIXELS

--
And my Template File
!-- MapServer Template --
TABLE width=98%
trtdCompartment/td/tr
trtdCompt No: [Compt_No]/td/tr
trtdAge: [Age]/td/tr
trtdArea: [Area_ha]/td/tr
trtdSpecies: [Species]/td/tr
trtdPlant Year: [Pd_yy]/td/tr
trtdMethod: [Method]/td/tr
/table

Can anyone see anything drastically wrong. I have copied the template
from a mapserver 5 installation and added the magic words at the top -
is there anything else required

Thanks
Andrew


-- 
View this message in context:
http://n2.nabble.com/GetFeatureInfo---something-not-adding-up-tp3195907p
3195907.html
Sent from the Mapserver - User mailing list archive at Nabble.com.

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] getfeatureinfo problems

2009-06-26 Thread Rahkonen Jukka
Hi,

Have you tried to run the SQL queries from logfile directly?  I wonder if for 
example this part is correct and finds any data:

 WHERE (geoidn='geoidNL.IMRO.0026.SVBBU-0001') and (tc_vlak_geometry  
setSRID( 'BOX3D(155984.407968748 468982.233317728,156024.590926508 
469022.416275488)'::BOX3D,28992) )

Just a guess, but perhaps odd table name makes some trouble.  How about 
reneming or copying the table temporarily to something wiht more simple name, 
like test?

-Jukka Rahkonen-




DeDuikertjes wrote:

Dear list,

yesterday I reported problems with my WFS server. I could not fix that 
up till now.

I have another possibly related problem.
My WMS is set up allright, getcapabilities is ok, I can see the map, pan 
zoom, etc, no problems.

When I do an Identify (GetFeatureInfo request), I get back an 
exception-report, with no items in (so essentially an ampty exception 
report).
The query just doesn't seem to find the data.
Clicking inside a feature and outside does differ (outside doesn't give 
an exception report).

I've enabled debugging and this is the output when I do a GetFeatureInfo 
request:

[Fri Jun 26 13:21:11 2009].498623 CGI Request 1 on process 1525
[Fri Jun 26 13:21:11 2009].518710 msPOSTGISLayerOpen called datastatement: 
tc_vlak_geometry from NL.IMRO.0026.SVBBU-0001 using unique geoidn using 
srid=28992
[Fri Jun 26 13:21:11 2009].518735 MSPOSTGISLayerOpen -- shared connection not 
available.
[Fri Jun 26 13:21:11 2009].523422 
msConnPoolRegister(geoidNL.IMRO.0026.SVBBU-0001_vlak,host=localhost 
user=tc_check dbname=80.101.100.35,0x9457b38)
[Fri Jun 26 13:21:11 2009].523453 msPOSTGISLayerFreeItemInfo called
[Fri Jun 26 13:21:11 2009].523466 msPOSTGISLayerWhichShapes called
[Fri Jun 26 13:21:11 2009].523490 msPOSTGISLayerParseData: unique column = 
geoidn, srid='28992', geom_column_name = tc_vlak_geometry, 
table_name=NL.IMRO.0026.SVBBU-0001
[Fri Jun 26 13:21:11 2009].523796 query_string_0_6:DECLARE mycursor BINARY 
CURSOR FOR SELECT 
asbinary(force_collection(force_2d(tc_vlak_geometry)),'NDR'),geoidn::text from 
NL.IMRO.0026.SVBBU-0001 WHERE (geoidn='geoidNL.IMRO.0026.SVBBU-0001') and 
(tc_vlak_geometry  setSRID( 'BOX3D(155984.407968748 
468982.233317728,156024.590926508 469022.416275488)'::BOX3D,28992) )
[Fri Jun 26 13:21:11 2009].535912 msPOSTGISLayerFreeItemInfo called
[Fri Jun 26 13:21:11 2009].535925 msPOSTGISLayerClose datastatement: 
tc_vlak_geometry from NL.IMRO.0026.SVBBU-0001 using unique geoidn using 
srid=28992
[Fri Jun 26 13:21:11 2009].535931 msPOSTGISLayerClose -- closing query_result
[Fri Jun 26 13:21:11 2009].536007 
msConnPoolRelease(geoidNL.IMRO.0026.SVBBU-0001_vlak,host=localhost 
user=tc_check dbname=80.101.100.35,0x9457b38)
[Fri Jun 26 13:21:11 2009].536017 msConnPoolClose(host=localhost user=tc_check 
dbname=80.101.100.35,0x9457b38)
[Fri Jun 26 13:21:11 2009].538905 msPOSTGISLayerOpen called datastatement: 
tc_vlak_geometry from NL.IMRO.0026.SVBBU-0001 using unique geoidn using 
srid=28992
[Fri Jun 26 13:21:11 2009].538914 MSPOSTGISLayerOpen -- shared connection not 
available.
[Fri Jun 26 13:21:11 2009].543298 
msConnPoolRegister(geoidNL.IMRO.0026.SVBBU-0001_vlak,host=localhost 
user=tc_check dbname=80.101.100.35,0x9457b38)
[Fri Jun 26 13:21:11 2009].543314 msPOSTGISLayerFreeItemInfo called
[Fri Jun 26 13:21:11 2009].543319 in msPOSTGISLayerGetItems  (find column names)
[Fri Jun 26 13:21:11 2009].543329 msPOSTGISLayerParseData: unique column = 
geoidn, srid='28992', geom_column_name = tc_vlak_geometry, 
table_name=NL.IMRO.0026.SVBBU-0001
[Fri Jun 26 13:21:11 2009].545217 msPOSTGISLayerInitItemInfo called
[Fri Jun 26 13:21:11 2009].545230 msPOSTGISLayerGetShape called for record = 0
[Fri Jun 26 13:21:11 2009].545239 msPOSTGISLayerParseData: unique column = 
geoidn, srid='28992', geom_column_name = tc_vlak_geometry, 
table_name=NL.IMRO.0026.SVBBU-0001
[Fri Jun 26 13:21:11 2009].545253 msPOSTGISLayerGetShape: DECLARE mycursor2 
BINARY CURSOR FOR SELECT 
geoidn::text,idealisatie::text,tc_multi_geometry::text,tc_lijn_geometry::text,tc_punt_geometry::text,asbinary(force_collection(force_2d(tc_vlak_geometry)),'NDR')
 from NL.IMRO.0026.SVBBU-0001 WHERE geoidn = 0 
[Fri Jun 26 13:21:11 2009].547105 msFreeMap(): freeing map at 0x943d518.
[Fri Jun 26 13:21:11 2009].547114 msPOSTGISLayerClose datastatement: 
tc_vlak_geometry from NL.IMRO.0026.SVBBU-0001 using unique geoidn using 
srid=28992
[Fri Jun 26 13:21:11 2009].547119 msPOSTGISLayerClose -- query_result is NULL
[Fri Jun 26 13:21:11 2009].547124 
msConnPoolRelease(geoidNL.IMRO.0026.SVBBU-0001_vlak,host=localhost 
user=tc_check dbname=80.101.100.35,0x9457b38)


Just as with the WFS problem, there is no data returning. The WFS does show the 
exposed columns, never any data in. 

I've not a clue of how to proceed, or how to get extra debug info.
Please help !

MArco
[Fri Jun 26 13:21:11 2009].547132 msConnPoolClose(host=localhost user=tc_check 
dbname=80.101.100.35,0x9457b38)



Re: [mapserver-users] getfeatureinfo problems

2009-06-26 Thread DeDuikertjes

Jukka,

Thank you, I've tried the SQL statement:

DECLARE mycursor BINARY CURSOR FOR SELECT 
asbinary(force_collection(force_2d(tc_vlak_geometry)),'NDR'),geoidn::text from 
NL.IMRO.0026.SVBBU-0001 WHERE (geoidn='geoidNL.IMRO.0026.SVBBU-0001') and 
(tc_vlak_geometry  setSRID( 'BOX3D(155984.407968748 468982.233317728,156024.590926508 
469022.416275488)'::BOX3D,28992) )

with the first DECLARE part omitted, so:
SELECT 
asbinary(force_collection(force_2d(tc_vlak_geometry)),'NDR'),geoidn::text 
from NL.IMRO.0026.SVBBU-0001 WHERE 
(geoidn='geoidNL.IMRO.0026.SVBBU-0001') and (tc_vlak_geometry  
setSRID( 'BOX3D(155984.407968748 468982.233317728,156024.590926508 
469022.416275488)'::BOX3D,28992) )


This returns two rows.
I've tried
SELECT 
geoidn::text,idealisatie::text,tc_multi_geometry::text,tc_lijn_geometry::text,tc_punt_geometry::text,asbinary(force_collection(force_2d(tc_vlak_geometry)),'NDR') 
from NL.IMRO.0026.SVBBU-0001 WHERE geoidn = 0


also, which returns 0 rows.
This is as expected from this query as it asks for WHERE geoidn = 0
geoidn never is 0.

Why does mapserver come to this query? I've never asked for geidn to be 
zero!
If I remove the WHERE geoidn = 0 I get a result for all the layers on 
the point (all the layers in fact).
Somehow this WHERE geoidn = 0 condition is constructed false. Ist should 
be something like WHERE geoidn = geoidNL.IMRO.0026.SVBBU-0001


I've not a clue where that wrong query clause comes from.

MArco
P.S. In earlier attempts I've renamed the tables with identical results.




Rahkonen Jukka schreef:

Hi,

Have you tried to run the SQL queries from logfile directly?  I wonder if for 
example this part is correct and finds any data:

 WHERE (geoidn='geoidNL.IMRO.0026.SVBBU-0001') and (tc_vlak_geometry  
setSRID( 'BOX3D(155984.407968748 468982.233317728,156024.590926508 
469022.416275488)'::BOX3D,28992) )

Just a guess, but perhaps odd table name makes some trouble.  How about reneming or 
copying the table temporarily to something wiht more simple name, like test?

-Jukka Rahkonen-




DeDuikertjes wrote:

Dear list,

yesterday I reported problems with my WFS server. I could not fix that 
up till now.


I have another possibly related problem.
My WMS is set up allright, getcapabilities is ok, I can see the map, pan 
zoom, etc, no problems.


When I do an Identify (GetFeatureInfo request), I get back an 
exception-report, with no items in (so essentially an ampty exception 
report).

The query just doesn't seem to find the data.
Clicking inside a feature and outside does differ (outside doesn't give 
an exception report).


I've enabled debugging and this is the output when I do a GetFeatureInfo 
request:


[Fri Jun 26 13:21:11 2009].498623 CGI Request 1 on process 1525
[Fri Jun 26 13:21:11 2009].518710 msPOSTGISLayerOpen called datastatement: 
tc_vlak_geometry from NL.IMRO.0026.SVBBU-0001 using unique geoidn using 
srid=28992
[Fri Jun 26 13:21:11 2009].518735 MSPOSTGISLayerOpen -- shared connection not 
available.
[Fri Jun 26 13:21:11 2009].523422 
msConnPoolRegister(geoidNL.IMRO.0026.SVBBU-0001_vlak,host=localhost 
user=tc_check dbname=80.101.100.35,0x9457b38)
[Fri Jun 26 13:21:11 2009].523453 msPOSTGISLayerFreeItemInfo called
[Fri Jun 26 13:21:11 2009].523466 msPOSTGISLayerWhichShapes called
[Fri Jun 26 13:21:11 2009].523490 msPOSTGISLayerParseData: unique column = geoidn, 
srid='28992', geom_column_name = tc_vlak_geometry, 
table_name=NL.IMRO.0026.SVBBU-0001
[Fri Jun 26 13:21:11 2009].523796 query_string_0_6:DECLARE mycursor BINARY CURSOR FOR SELECT 
asbinary(force_collection(force_2d(tc_vlak_geometry)),'NDR'),geoidn::text from 
NL.IMRO.0026.SVBBU-0001 WHERE (geoidn='geoidNL.IMRO.0026.SVBBU-0001') and 
(tc_vlak_geometry  setSRID( 'BOX3D(155984.407968748 468982.233317728,156024.590926508 
469022.416275488)'::BOX3D,28992) )
[Fri Jun 26 13:21:11 2009].535912 msPOSTGISLayerFreeItemInfo called
[Fri Jun 26 13:21:11 2009].535925 msPOSTGISLayerClose datastatement: tc_vlak_geometry 
from NL.IMRO.0026.SVBBU-0001 using unique geoidn using srid=28992
[Fri Jun 26 13:21:11 2009].535931 msPOSTGISLayerClose -- closing query_result
[Fri Jun 26 13:21:11 2009].536007 
msConnPoolRelease(geoidNL.IMRO.0026.SVBBU-0001_vlak,host=localhost 
user=tc_check dbname=80.101.100.35,0x9457b38)
[Fri Jun 26 13:21:11 2009].536017 msConnPoolClose(host=localhost user=tc_check 
dbname=80.101.100.35,0x9457b38)
[Fri Jun 26 13:21:11 2009].538905 msPOSTGISLayerOpen called datastatement: 
tc_vlak_geometry from NL.IMRO.0026.SVBBU-0001 using unique geoidn using 
srid=28992
[Fri Jun 26 13:21:11 2009].538914 MSPOSTGISLayerOpen -- shared connection not 
available.
[Fri Jun 26 13:21:11 2009].543298 
msConnPoolRegister(geoidNL.IMRO.0026.SVBBU-0001_vlak,host=localhost 
user=tc_check dbname=80.101.100.35,0x9457b38)
[Fri Jun 26 13:21:11 2009].543314 msPOSTGISLayerFreeItemInfo called
[Fri Jun 26 13:21:11 2009].543319 in msPOSTGISLayerGetItems  (find column names)
[Fri Jun 26 13:21:11 2009].543329 msPOSTGISLayerParseData: 

Re: [mapserver-users] getfeatureinfo problems

2009-06-26 Thread Bart van den Eijnden (OSGIS)

Hi,

Mapserver needs an integer type column for the USING UNIQUE clause, not 
a string column. That won't work.


Best regards,
Bart

DeDuikertjes wrote:

Jukka,

Thank you, I've tried the SQL statement:

DECLARE mycursor BINARY CURSOR FOR SELECT 
asbinary(force_collection(force_2d(tc_vlak_geometry)),'NDR'),geoidn::text 
from NL.IMRO.0026.SVBBU-0001 WHERE 
(geoidn='geoidNL.IMRO.0026.SVBBU-0001') and (tc_vlak_geometry  
setSRID( 'BOX3D(155984.407968748 468982.233317728,156024.590926508 
469022.416275488)'::BOX3D,28992) )


with the first DECLARE part omitted, so:
SELECT 
asbinary(force_collection(force_2d(tc_vlak_geometry)),'NDR'),geoidn::text 
from NL.IMRO.0026.SVBBU-0001 WHERE 
(geoidn='geoidNL.IMRO.0026.SVBBU-0001') and (tc_vlak_geometry  
setSRID( 'BOX3D(155984.407968748 468982.233317728,156024.590926508 
469022.416275488)'::BOX3D,28992) )


This returns two rows.
I've tried
SELECT 
geoidn::text,idealisatie::text,tc_multi_geometry::text,tc_lijn_geometry::text,tc_punt_geometry::text,asbinary(force_collection(force_2d(tc_vlak_geometry)),'NDR') 
from NL.IMRO.0026.SVBBU-0001 WHERE geoidn = 0


also, which returns 0 rows.
This is as expected from this query as it asks for WHERE geoidn = 0
geoidn never is 0.

Why does mapserver come to this query? I've never asked for geidn to 
be zero!
If I remove the WHERE geoidn = 0 I get a result for all the layers on 
the point (all the layers in fact).
Somehow this WHERE geoidn = 0 condition is constructed false. Ist 
should be something like WHERE geoidn = geoidNL.IMRO.0026.SVBBU-0001


I've not a clue where that wrong query clause comes from.

MArco
P.S. In earlier attempts I've renamed the tables with identical results.




Rahkonen Jukka schreef:

Hi,

Have you tried to run the SQL queries from logfile directly?  I 
wonder if for example this part is correct and finds any data:


 WHERE (geoidn='geoidNL.IMRO.0026.SVBBU-0001') and (tc_vlak_geometry 
 setSRID( 'BOX3D(155984.407968748 468982.233317728,156024.590926508 
469022.416275488)'::BOX3D,28992) )


Just a guess, but perhaps odd table name makes some trouble.  How 
about reneming or copying the table temporarily to something wiht 
more simple name, like test?


-Jukka Rahkonen-




DeDuikertjes wrote:

Dear list,

yesterday I reported problems with my WFS server. I could not fix 
that up till now.


I have another possibly related problem.
My WMS is set up allright, getcapabilities is ok, I can see the map, 
pan zoom, etc, no problems.


When I do an Identify (GetFeatureInfo request), I get back an 
exception-report, with no items in (so essentially an ampty exception 
report).

The query just doesn't seem to find the data.
Clicking inside a feature and outside does differ (outside doesn't 
give an exception report).


I've enabled debugging and this is the output when I do a 
GetFeatureInfo request:


[Fri Jun 26 13:21:11 2009].498623 CGI Request 1 on process 1525
[Fri Jun 26 13:21:11 2009].518710 msPOSTGISLayerOpen called 
datastatement: tc_vlak_geometry from NL.IMRO.0026.SVBBU-0001 using 
unique geoidn using srid=28992
[Fri Jun 26 13:21:11 2009].518735 MSPOSTGISLayerOpen -- shared 
connection not available.
[Fri Jun 26 13:21:11 2009].523422 
msConnPoolRegister(geoidNL.IMRO.0026.SVBBU-0001_vlak,host=localhost 
user=tc_check dbname=80.101.100.35,0x9457b38)

[Fri Jun 26 13:21:11 2009].523453 msPOSTGISLayerFreeItemInfo called
[Fri Jun 26 13:21:11 2009].523466 msPOSTGISLayerWhichShapes called
[Fri Jun 26 13:21:11 2009].523490 msPOSTGISLayerParseData: unique 
column = geoidn, srid='28992', geom_column_name = tc_vlak_geometry, 
table_name=NL.IMRO.0026.SVBBU-0001
[Fri Jun 26 13:21:11 2009].523796 query_string_0_6:DECLARE mycursor 
BINARY CURSOR FOR SELECT 
asbinary(force_collection(force_2d(tc_vlak_geometry)),'NDR'),geoidn::text 
from NL.IMRO.0026.SVBBU-0001 WHERE 
(geoidn='geoidNL.IMRO.0026.SVBBU-0001') and (tc_vlak_geometry  
setSRID( 'BOX3D(155984.407968748 468982.233317728,156024.590926508 
469022.416275488)'::BOX3D,28992) )

[Fri Jun 26 13:21:11 2009].535912 msPOSTGISLayerFreeItemInfo called
[Fri Jun 26 13:21:11 2009].535925 msPOSTGISLayerClose datastatement: 
tc_vlak_geometry from NL.IMRO.0026.SVBBU-0001 using unique geoidn 
using srid=28992
[Fri Jun 26 13:21:11 2009].535931 msPOSTGISLayerClose -- closing 
query_result
[Fri Jun 26 13:21:11 2009].536007 
msConnPoolRelease(geoidNL.IMRO.0026.SVBBU-0001_vlak,host=localhost 
user=tc_check dbname=80.101.100.35,0x9457b38)
[Fri Jun 26 13:21:11 2009].536017 msConnPoolClose(host=localhost 
user=tc_check dbname=80.101.100.35,0x9457b38)
[Fri Jun 26 13:21:11 2009].538905 msPOSTGISLayerOpen called 
datastatement: tc_vlak_geometry from NL.IMRO.0026.SVBBU-0001 using 
unique geoidn using srid=28992
[Fri Jun 26 13:21:11 2009].538914 MSPOSTGISLayerOpen -- shared 
connection not available.
[Fri Jun 26 13:21:11 2009].543298 
msConnPoolRegister(geoidNL.IMRO.0026.SVBBU-0001_vlak,host=localhost 
user=tc_check dbname=80.101.100.35,0x9457b38)

[Fri Jun 26 13:21:11 2009].543314 

Re: [mapserver-users] getfeatureinfo problems

2009-06-26 Thread DeDuikertjes

List,

Thanks to Bart van den Eijnden the problem is solved.
I used a using unique clause on a column which was unique, but not 
integer.

So I now create my postgis tables with a CREAT TABLE  WITH OIDS

and I use a using unique oid clause in the DATA statement.

As often, details do matter.

Thanks for all the responses and efforts.

MArco




DeDuikertjes wrote:

Dear list,

yesterday I reported problems with my WFS server. I could not fix 
that up till now.


I have another possibly related problem.
My WMS is set up allright, getcapabilities is ok, I can see the map, 
pan zoom, etc, no problems.


When I do an Identify (GetFeatureInfo request), I get back an 
exception-report, with no items in (so essentially an ampty exception 
report).

The query just doesn't seem to find the data.
Clicking inside a feature and outside does differ (outside doesn't 
give an exception report).


I've enabled debugging and this is the output when I do a 
GetFeatureInfo request:


[Fri Jun 26 13:21:11 2009].498623 CGI Request 1 on process 1525
[Fri Jun 26 13:21:11 2009].518710 msPOSTGISLayerOpen called 
datastatement: tc_vlak_geometry from NL.IMRO.0026.SVBBU-0001 using 
unique geoidn using srid=28992
[Fri Jun 26 13:21:11 2009].518735 MSPOSTGISLayerOpen -- shared 
connection not available.
[Fri Jun 26 13:21:11 2009].523422 
msConnPoolRegister(geoidNL.IMRO.0026.SVBBU-0001_vlak,host=localhost 
user=tc_check dbname=80.101.100.35,0x9457b38)

[Fri Jun 26 13:21:11 2009].523453 msPOSTGISLayerFreeItemInfo called
[Fri Jun 26 13:21:11 2009].523466 msPOSTGISLayerWhichShapes called
[Fri Jun 26 13:21:11 2009].523490 msPOSTGISLayerParseData: unique 
column = geoidn, srid='28992', geom_column_name = tc_vlak_geometry, 
table_name=NL.IMRO.0026.SVBBU-0001
[Fri Jun 26 13:21:11 2009].523796 query_string_0_6:DECLARE mycursor 
BINARY CURSOR FOR SELECT 
asbinary(force_collection(force_2d(tc_vlak_geometry)),'NDR'),geoidn::text 
from NL.IMRO.0026.SVBBU-0001 WHERE 
(geoidn='geoidNL.IMRO.0026.SVBBU-0001') and (tc_vlak_geometry  
setSRID( 'BOX3D(155984.407968748 468982.233317728,156024.590926508 
469022.416275488)'::BOX3D,28992) )

[Fri Jun 26 13:21:11 2009].535912 msPOSTGISLayerFreeItemInfo called
[Fri Jun 26 13:21:11 2009].535925 msPOSTGISLayerClose datastatement: 
tc_vlak_geometry from NL.IMRO.0026.SVBBU-0001 using unique geoidn 
using srid=28992
[Fri Jun 26 13:21:11 2009].535931 msPOSTGISLayerClose -- closing 
query_result
[Fri Jun 26 13:21:11 2009].536007 
msConnPoolRelease(geoidNL.IMRO.0026.SVBBU-0001_vlak,host=localhost 
user=tc_check dbname=80.101.100.35,0x9457b38)
[Fri Jun 26 13:21:11 2009].536017 msConnPoolClose(host=localhost 
user=tc_check dbname=80.101.100.35,0x9457b38)
[Fri Jun 26 13:21:11 2009].538905 msPOSTGISLayerOpen called 
datastatement: tc_vlak_geometry from NL.IMRO.0026.SVBBU-0001 using 
unique geoidn using srid=28992
[Fri Jun 26 13:21:11 2009].538914 MSPOSTGISLayerOpen -- shared 
connection not available.
[Fri Jun 26 13:21:11 2009].543298 
msConnPoolRegister(geoidNL.IMRO.0026.SVBBU-0001_vlak,host=localhost 
user=tc_check dbname=80.101.100.35,0x9457b38)

[Fri Jun 26 13:21:11 2009].543314 msPOSTGISLayerFreeItemInfo called
[Fri Jun 26 13:21:11 2009].543319 in msPOSTGISLayerGetItems  (find 
column names)
[Fri Jun 26 13:21:11 2009].543329 msPOSTGISLayerParseData: unique 
column = geoidn, srid='28992', geom_column_name = tc_vlak_geometry, 
table_name=NL.IMRO.0026.SVBBU-0001

[Fri Jun 26 13:21:11 2009].545217 msPOSTGISLayerInitItemInfo called
[Fri Jun 26 13:21:11 2009].545230 msPOSTGISLayerGetShape called for 
record = 0
[Fri Jun 26 13:21:11 2009].545239 msPOSTGISLayerParseData: unique 
column = geoidn, srid='28992', geom_column_name = tc_vlak_geometry, 
table_name=NL.IMRO.0026.SVBBU-0001
[Fri Jun 26 13:21:11 2009].545253 msPOSTGISLayerGetShape: DECLARE 
mycursor2 BINARY CURSOR FOR SELECT 
geoidn::text,idealisatie::text,tc_multi_geometry::text,tc_lijn_geometry::text,tc_punt_geometry::text,asbinary(force_collection(force_2d(tc_vlak_geometry)),'NDR') 
from NL.IMRO.0026.SVBBU-0001 WHERE geoidn = 0 [Fri Jun 26 13:21:11 
2009].547105 msFreeMap(): freeing map at 0x943d518.
[Fri Jun 26 13:21:11 2009].547114 msPOSTGISLayerClose datastatement: 
tc_vlak_geometry from NL.IMRO.0026.SVBBU-0001 using unique geoidn 
using srid=28992
[Fri Jun 26 13:21:11 2009].547119 msPOSTGISLayerClose -- query_result 
is NULL
[Fri Jun 26 13:21:11 2009].547124 
msConnPoolRelease(geoidNL.IMRO.0026.SVBBU-0001_vlak,host=localhost 
user=tc_check dbname=80.101.100.35,0x9457b38)



Just as with the WFS problem, there is no data returning. The WFS 
does show the exposed columns, never any data in.

I've not a clue of how to proceed, or how to get extra debug info.
Please help !

MArco
[Fri Jun 26 13:21:11 2009].547132 msConnPoolClose(host=localhost 
user=tc_check dbname=80.101.100.35,0x9457b38)



___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


  


Re: [mapserver-users] getfeatureinfo problems

2009-06-26 Thread David Nugent

On 26/6/09 11:10 PM, Bart van den Eijnden (OSGIS) wrote:

Mapserver needs an integer type column for the USING UNIQUE clause, not
a string column. That won't work.


Actually, no it doesn't require an integer type column for the UNIQUE 
clause.  I have used text fields in the past with mapserver 5.x and can 
confirm that it does indeed work.


Mind you, some other cartographic software such as QGIS does insist on 
int4 fields for PostGIS layers, but not mapserver.


Regards,
David
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo in XML

2009-05-06 Thread Sven Schroeter

Pål ,
I use a simple XML-File with CGI-Variables ([myvar]) like this:

?xml version=1.0 encoding=UTF-8?
sg:FeatureInfoResponse
 sg:Schutzgebiet
   sg:SchutzgebietsartNaturschutzgebiet/sg:Schutzgebietsart
   sg:Gebietsname[name]/sg:Gebietsname
   sg:Gebietsnummer[objnr]/sg:Gebietsnummer
   
sg:Rechtsgrundlagehttp://www.naturschutz.rlp.de/dokumente/rvo/[objnr].htm/sg:Rechtsgrundlage
   sg:Schutzzone[schutzzone]/sg:Schutzzone
   sg:Erfassungsgrundlage[erfassungsgrundlage]/sg:Erfassungsgrundlage
   
sg:Info_Kontakthttp://www.naturschutz.rlp.de/Impressum.natur?ActiveID=1234/sg:Info_Kontakt
 /sg:Schutzgebiet
/sg:FeatureInfoResponse

If  there is a request for xml I tell my script to set the response-header 
is XML:


...
 $buffer = ms_iogetstdoutbufferstring();
   header('Content-type: text/xml');
   echo $buffer;
...

Greetings Sven



- Original Message - 
From: paalkr pal.kristen...@statkart.no

To: mapserver-users@lists.osgeo.org
Sent: Tuesday, May 05, 2009 11:01 PM
Subject: Re: [mapserver-users] GetFeatureInfo in XML



Hi!

This is something that I'm interested in as well, could I please ask you to
share your featureinfo_nsg.xml? I would like to have a look at it to get
some hints on how to set up a XML template.

BTW: I think you can expose a new InfoFormat by setting the
wms_feature_info_mime_type keyword in the web metadata section of your
mapfile.

Regards,
Pål Kristensen



Sven Schroeter wrote:


Hi all,
I am currently experimenting with Web Map Services and a custom PHP
wrapper.
In this script for a GetFeatureInfo-Request with
info_format=application/vnd.ogc.wms_xml or  info_format=text/xml a XML
document is generated.
This works well, a XML-template is set in the mapfile dynamically:
...
if($k == 'info_format'  ($v == 'application/vnd.ogc.wms_xml' || $v ==
'text/xml')){
 $layer = $oMap-getLayerByName($layername);
 $layer-set(template, template/featureinfo_nsg.xml);
...
}
...

Two questions:
1. Is it possible to get a featureInfo-Request in xml native by mapserver
(no gml)
2. How can I tell mapserver to enhance the list of capabilities to xml? At
this time there comes only
...
GetFeatureInfo
Formattext/plain/Format
Formattext/html/Format
Formatapplication/vnd.ogc.gml/Format
DCPType
...

Thanks
Sven





___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users





-

Regards,
Pål Kristensen
--
View this message in context: 
http://n2.nabble.com/GetFeatureInfo-in-XML-tp2787413p2806255.html

Sent from the Mapserver - User mailing list archive at Nabble.com.

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users 



___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo in XML

2009-05-05 Thread paalkr

Hi!

This is something that I'm interested in as well, could I please ask you to
share your featureinfo_nsg.xml? I would like to have a look at it to get
some hints on how to set up a XML template.

BTW: I think you can expose a new InfoFormat by setting the
wms_feature_info_mime_type keyword in the web metadata section of your
mapfile. 

Regards,
Pål Kristensen



Sven Schroeter wrote:
 
 Hi all,
 I am currently experimenting with Web Map Services and a custom PHP
 wrapper.
 In this script for a GetFeatureInfo-Request with 
 info_format=application/vnd.ogc.wms_xml or  info_format=text/xml a XML 
 document is generated.
 This works well, a XML-template is set in the mapfile dynamically:
 ...
 if($k == 'info_format'  ($v == 'application/vnd.ogc.wms_xml' || $v == 
 'text/xml')){
  $layer = $oMap-getLayerByName($layername);
  $layer-set(template, template/featureinfo_nsg.xml);
 ...
 }
 ...
 
 Two questions:
 1. Is it possible to get a featureInfo-Request in xml native by mapserver 
 (no gml)
 2. How can I tell mapserver to enhance the list of capabilities to xml? At 
 this time there comes only
 ...
 GetFeatureInfo
 Formattext/plain/Format
 Formattext/html/Format
 Formatapplication/vnd.ogc.gml/Format
 DCPType
 ...
 
 Thanks
 Sven
 
 
 
 
 
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users
 
 


-

Regards,
Pål Kristensen
-- 
View this message in context: 
http://n2.nabble.com/GetFeatureInfo-in-XML-tp2787413p2806255.html
Sent from the Mapserver - User mailing list archive at Nabble.com.

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureINFO errors in Mapserver notoccurringin Geoserver.

2009-04-24 Thread Steve Lime
Could be a config error in the mapfile. What version of MapServer are you 
using? What does the
layer def look like?

Geoserver and MapServer are completely different code bases so they definitely 
approach SDE 
differently.

Steve

 On 4/23/2009 at 6:45 PM, in message 
 1240530355847-2688375.p...@n2.nabble.com,
Michelle Douvil mrdouvi...@shaw.ca wrote:

 Hi Steve, 
 Thanks for the suggestion..
 
 I attempted this URL
 
 http://server/mapserver/air-climate?mapsize=1024+370layers=AEI_AIR_QUALITY_AO
  
 I_Omapxy=-126.94250575451+54.5026638549918mode=query
 
 and it returned:
 Content-type: text/html msSDELayerGetShape(): SDE error.
 SE_stream_fetch_row(): Invalid parameter value passed to function. (-66) 
 
 Looks like WMS and mapserver queries have problems at the same point in the
 code - msSDElayerGetShape().. 
 
 I find it odd that Geoserver WMS seems to have no problem with the same sde
 layer data. 
 Which makes me believe that the underlying SDE data may be OK, but Geoserver
 and Mapserver somehow do the queries to SDE differently..
 
 many thanks, 
 Michelle
 
 
 
 
 Steve Lime wrote:
 
 Sounds like more of an SDE problem than WMS. Can you query the SDE layer
 outside of WMS just
 using MapServer queries?
 
 Steve
 
 
 
 

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureINFO errors in Mapserver notoccurringin Geoserver.

2009-04-24 Thread Michelle Douvil

Steve here is the debug.. when GetFeatureINFO is requested..


[Fri Apr 24 10:37:59 2009].667000
msConnPoolRequest(AEI_AIR_QUALITY_AOI_O,server,port:5152,sde,username,password)
- got 01A63FE8
[Fri Apr 24 10:37:59 2009].667000 msSDELayerOpen(): Layer
AEI_AIR_QUALITY_AOI_O did not have a specified version.
[Fri Apr 24 10:37:59 2009].667000 msSDEGetLayerInfo(): Looking for layer by
WHSE_ENVIRONMENTAL_MONITORING.AEI_AIR_QUALITY_AOI_SVW, GEOMETRY,
server,port:5152,sde,username,password
[Fri Apr 24 10:37:59 2009].667000 msSDEGetLayerId(): Matched layer to id
1826.
[Fri Apr 24 10:37:59 2009].667000 Getting all column information in
msSDELayerInitItemInfo
[Fri Apr 24 10:37:59 2009].667000 msSDELayerGetRowIDColumn(): Column was
manually set to OBJECTID
[Fri Apr 24 10:37:59 2009].667000 msSDELayerInitItemInfo(): getting info for
geometry
[Fri Apr 24 10:37:59 2009].667000 msSDELayerInitItemInfo(): getting info for
objectid
[Fri Apr 24 10:37:59 2009].667000 msSDELayerInitItemInfo(): getting info for
air_quality_aoi_id
[Fri Apr 24 10:37:59 2009].667000 msSDELayerInitItemInfo(): getting info for
aoi_name
[Fri Apr 24 10:37:59 2009].667000 msSDELayerInitItemInfo(): getting info for
status
[Fri Apr 24 10:37:59 2009].667000 msSDELayerInitItemInfo(): getting info for
feature_code
[Fri Apr 24 10:37:59 2009].667000 msSDELayerGetShape(): SDE error.
SE_stream_fetch_row(): Invalid parameter value passed to function. (-66)
[Fri Apr 24 10:37:59 2009].667000 mapserv request processing time (msLoadMap
not incl.): 0.016s
-- 
View this message in context: 
http://n2.nabble.com/GetFeatureINFO-errors-in-Mapserver-not-occurring-in-Geoserver.-tp2686390p2693869.html
Sent from the Mapserver - User mailing list archive at Nabble.com.

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureINFO errors in Mapserver not occurringin Geoserver.

2009-04-23 Thread Steve Lime
Sounds like more of an SDE problem than WMS. Can you query the SDE layer
outside of WMS just
using MapServer queries?

Steve

 On 4/23/2009 at 3:59 PM, in message
1240520397380-2686390.p...@n2.nabble.com,
Michelle Douvil mrdouvi...@shaw.ca wrote:

 
 We have data that is in Oracle 10.2.0.2   Enterprise
Edition with ArcSDE 9.1
 General Update Patch 3.
 We have several spatial views that are causing us issues when
GetFeatureINFO
 is requested via Mapserver 5.2. The result is an SDE error.
 SE_stream_fetch_row(): Invalid parameter value passed to function.
(-66).
 However, using Geoserver 1.7.3 to the same data the GetFeatureINFO
request
 is successful. Any thoughts as to why Mapserver has issues but
Geoserver
 does not? 
 
 The Spatial View given in the example below is a simple view (no
where
 clauses or join statements). We have re-registered the Spatial view
with the
 sde to make sure the objectid was correct. 
 
 Looks like Geoserver 1.7.3 doesn’t mind GetFeatureINFO on
 SCHEMA.AEI_AIR_QUALITY_AOI_SVW 
 Whereas Mapserver 5.2 gets confused.. see examples below
 
 

http://server/geoserver/wms?service=wmsrequest=getFeatureInfoversion=1.1.1la


yers=prod:AOIAEIquery_layers=prod:AOIAEIwidth=500height=500SRS=EPSG:4326BBOX=

-126.94250575451,54.5026638549918,-126.72424645805,54.6394718590618x=200y=200
 info_format=text/plain 
 
 
 Results for FeatureType 'AOIAEI':
 
 geometry = [GEOMETRY (Polygon) with 22 points]
 air_quality_aoi_id = 66
 aoi_name = Bulkley Valley / Lakes District
 status = Plan Established
 feature_code = FF00595000
 
 
 
 

http://server/mapserver/air-climate?service=wmsrequest=getFeatureInfoversion


=1.1.1layers=AEI_AIR_QUALITY_AOI_Oquery_layers=AEI_AIR_QUALITY_AOI_Owidth=500

height=500SRS=EPSG:4326BBOX=-126.94250575451,54.5026638549918,-126.7242464580
 5,54.6394718590618x=200y=200info_format=text/plain
 
 
 
 GetFeatureInfo results:
 
 Layer 'AEI_AIR_QUALITY_AOI_O'
 Content-type: application/vnd.ogc.se_xml
 
 ?xml version='1.0' encoding=ISO-8859-1 standalone=no ?
 !DOCTYPE ServiceExceptionReport SYSTEM
 http://schemas.opengis.net/wms/1.1.1/exception_1_1_1.dtd;
 ServiceExceptionReport version=1.1.1
 ServiceException
 msSDELayerGetShape(): SDE error. SE_stream_fetch_row(): Invalid
parameter
 value passed to function. (-66)
 /ServiceException
 /ServiceExceptionReport
 
 
 many thanks for any assistance.
 
 
 -- 
 View this message in context: 

http://n2.nabble.com/GetFeatureINFO-errors-in-Mapserver-not-occurring-in-Geos

 erver.-tp2686390p2686390.html
 Sent from the Mapserver - User mailing list archive at Nabble.com.
 
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org 
 http://lists.osgeo.org/mailman/listinfo/mapserver-users
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureINFO errors in Mapserver not occurringin Geoserver.

2009-04-23 Thread Michelle Douvil

Hi Steve, 
Thanks for the suggestion..

I attempted this URL

http://server/mapserver/air-climate?mapsize=1024+370layers=AEI_AIR_QUALITY_AOI_Omapxy=-126.94250575451+54.5026638549918mode=query

and it returned:
Content-type: text/html msSDELayerGetShape(): SDE error.
SE_stream_fetch_row(): Invalid parameter value passed to function. (-66) 

Looks like WMS and mapserver queries have problems at the same point in the
code - msSDElayerGetShape().. 

I find it odd that Geoserver WMS seems to have no problem with the same sde
layer data. 
Which makes me believe that the underlying SDE data may be OK, but Geoserver
and Mapserver somehow do the queries to SDE differently..

many thanks, 
Michelle




Steve Lime wrote:
 
 Sounds like more of an SDE problem than WMS. Can you query the SDE layer
 outside of WMS just
 using MapServer queries?
 
 Steve
 
 
 
 

-- 
View this message in context: 
http://n2.nabble.com/GetFeatureINFO-errors-in-Mapserver-not-occurring-in-Geoserver.-tp2686390p2688375.html
Sent from the Mapserver - User mailing list archive at Nabble.com.

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo with ArcSDE9.1/Oracle10g Spatial Views - Mapserver 5.2

2009-02-23 Thread Stephan Holl
Hello Michelle,

Michelle Douvil mrdouvi...@shaw.ca, [20090220 - 15:34:34]

 
 
 Additional debugging info..
 
 [Fri Feb 20 15:18:05 2009].241000 msSDELayerOpen(): Layer
 BIOT_OCCR_TREES_AREA_SVW specified version SDE.DEFAULT.
 [Fri Feb 20 15:18:05 2009].241000 msSDEGetLayerInfo(): Looking for
 layer by WHSE_TERRESTRIAL_ECOLOGY.BIOT_OCCR_TREES_AREA_SVW, GEOMETRY,
 server,port:port,sde,username,password
 [Fri Feb 20 15:18:05 2009].241000 msSDEGetLayerId(): Matched layer to
 id 896.
 [Fri Feb 20 15:18:05 2009].241000 Getting all column information in
 msSDELayerInitItemInfo
 [Fri Feb 20 15:18:05 2009].241000 msSDELayerGetRowIDColumn(): Table
 was not registered, returning SE_ROW_ID.

Make sure that your Layer is registerd properly in our ArcSDE,
otherwise you will not be able to fetch the GetFeatureInfo.
[...]
 [Fri Feb 20 15:18:05 2009].241000 msSDELayerGetShape(): SDE
error.
 SE_stream_fetch_row(): Invalid parameter value passed to function.
 (-66) [Fri Feb 20 15:18:05 2009].241000 mapserv request processing
 time (msLoadMap not incl.): 0.016s
 [Fri Feb 20 15:18:05 2009].241000 msFreeMap(): freeing map at
 010B4548. [Fri Feb 20 15:18:05 2009].241000
 msSDELayerCloseConnection(): Closing connection for layer
 BIOT_OCCR_TREES_AREA_SVW.

[...]

Best

Stephan

-- 
Stephan Holl stephan.h...@intevation.de | Tel.: +49 (0)541-33 508 3663
Intevation GmbH, Neuer Graben 17, 49074 OS  |  AG Osnabrück - HR B 18998
Geschäftsführer:  Frank Koormann, Bernhard Reiter, Dr. Jan-Oliver Wagner


signature.asc
Description: PGP signature
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo with ArcSDE9.1/Oracle10g Spatial Views - Mapserver 5.2

2009-02-20 Thread Michelle Douvil


Additional debugging info..

[Fri Feb 20 15:18:05 2009].241000 msSDELayerOpen(): Layer
BIOT_OCCR_TREES_AREA_SVW specified version SDE.DEFAULT.
[Fri Feb 20 15:18:05 2009].241000 msSDEGetLayerInfo(): Looking for layer by
WHSE_TERRESTRIAL_ECOLOGY.BIOT_OCCR_TREES_AREA_SVW, GEOMETRY,
server,port:port,sde,username,password
[Fri Feb 20 15:18:05 2009].241000 msSDEGetLayerId(): Matched layer to id
896.
[Fri Feb 20 15:18:05 2009].241000 Getting all column information in
msSDELayerInitItemInfo
[Fri Feb 20 15:18:05 2009].241000 msSDELayerGetRowIDColumn(): Table was not
registered, returning SE_ROW_ID.
[Fri Feb 20 15:18:05 2009].241000 msSDELayerInitItemInfo(): getting info for
OCCR_AREA_SP_ID
[Fri Feb 20 15:18:05 2009].241000 msSDELayerInitItemInfo(): getting info for
GEOMETRY
[Fri Feb 20 15:18:05 2009].241000 msSDELayerInitItemInfo(): getting info for
OBJECTID
[Fri Feb 20 15:18:05 2009].241000 msSDELayerInitItemInfo(): getting info for
FEATURE_CODE
[Fri Feb 20 15:18:05 2009].241000 msSDELayerInitItemInfo(): getting info for
SHAPE_ID
[Fri Feb 20 15:18:05 2009].241000 msSDELayerInitItemInfo(): getting info for
SCI_NAME_F
[Fri Feb 20 15:18:05 2009].241000 msSDELayerInitItemInfo(): getting info for
SCI_NAME
[Fri Feb 20 15:18:05 2009].241000 msSDELayerInitItemInfo(): getting info for
ENG_NAME_F
[Fri Feb 20 15:18:05 2009].241000 msSDELayerInitItemInfo(): getting info for
ENG_NAME
[Fri Feb 20 15:18:05 2009].241000 msSDELayerInitItemInfo(): getting info for
OCCR_ID
[Fri Feb 20 15:18:05 2009].241000 msSDELayerInitItemInfo(): getting info for
EL_TYPE
[Fri Feb 20 15:18:05 2009].241000 msSDELayerInitItemInfo(): getting info for
DATA_SENS
[Fri Feb 20 15:18:05 2009].241000 msSDELayerInitItemInfo(): getting info for
SURV_SITE
[Fri Feb 20 15:18:05 2009].241000 msSDELayerInitItemInfo(): getting info for
DIRECTIONS
[Fri Feb 20 15:18:05 2009].241000 msSDELayerInitItemInfo(): getting info for
FIRST_OBS
[Fri Feb 20 15:18:05 2009].241000 msSDELayerInitItemInfo(): getting info for
LAST_OBS
[Fri Feb 20 15:18:05 2009].241000 msSDELayerInitItemInfo(): getting info for
OCCR_DATA
[Fri Feb 20 15:18:05 2009].241000 msSDELayerInitItemInfo(): getting info for
GEN_DESC
[Fri Feb 20 15:18:05 2009].241000 msSDELayerInitItemInfo(): getting info for
VEG_ZONE
[Fri Feb 20 15:18:05 2009].241000 msSDELayerInitItemInfo(): getting info for
HABITAT
[Fri Feb 20 15:18:05 2009].241000 msSDELayerInitItemInfo(): getting info for
BGC
[Fri Feb 20 15:18:05 2009].241000 msSDELayerInitItemInfo(): getting info for
REFERENCES
[Fri Feb 20 15:18:05 2009].241000 msSDELayerInitItemInfo(): getting info for
VERS_DATE
[Fri Feb 20 15:18:05 2009].241000 msSDELayerInitItemInfo(): getting info for
EST_RA
[Fri Feb 20 15:18:05 2009].241000 msSDELayerGetShape(): SDE error.
SE_stream_fetch_row(): Invalid parameter value passed to function. (-66)
[Fri Feb 20 15:18:05 2009].241000 mapserv request processing time (msLoadMap
not incl.): 0.016s
[Fri Feb 20 15:18:05 2009].241000 msFreeMap(): freeing map at 010B4548.
[Fri Feb 20 15:18:05 2009].241000 msSDELayerCloseConnection(): Closing
connection for layer BIOT_OCCR_TREES_AREA_SVW.


Mapfile layer:

 LAYER
NAME 'BIOT_OCCR_TREES_AREA_SVW'
CONNECTIONTYPE sde
CONNECTION server,port,sde,username,password
DATA
'WHSE_TERRESTRIAL_ECOLOGY.BIOT_OCCR_TREES_AREA_SVW,GEOMETRY,SDE.DEFAULT'
   # PROCESSING OBJECTID=SHAPE_ID
LABELITEM 'SHAPE_ID'
LABELMAXSCALE 50
CLASS
  NAME 'CDC Big Trees'
  STYLE
SYMBOL 'square'
COLOR 215 194 158
SIZE 5
  END #end style
  LABEL
COLOR 0 0 0
FONT arial
TYPE truetype
SIZE 8
PARTIALS FALSE
BUFFER 1
OUTLINECOLOR 254 254 254
  END #end label
  
END #end class
TYPE polygon
MINSCALE 0
MAXSCALE 300
STATUS ON
PROJECTION
  init=EPSG:3005
END #projection
METADATA
  wms_title Big Trees - Non Sensitive Occurrences
  wms_metadataurl_format html
  wms_metadataurl_href  
  wms_metadataurl_type TC211
  wfs_title CDC Big Trees
 # gml_geometries geom
  gml_geom_type polygon
  gml_include_items all
 # gml_exclude_items GEOMETRY,OBJECTID
  ows_include_items all
  gml_featureid OBJECTID
  ows_feature_id OBJECTID
  # wms_feature_info_mime_type text/plain


END #metadata
PROCESSING CLOSE_CONNECTION=DEFER
DEBUG 5
DUMP TRUE
TEMPLATE foo.html
  END #end layer


-- 
View this message in context: 
http://n2.nabble.com/GetFeatureInfo-with-ArcSDE9.1-Oracle10g-Spatial-Views---Mapserver-5.2-tp2361707p2361946.html
Sent from the Mapserver - User mailing list archive at Nabble.com.

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] getFeatureInfo() Only Works on One Layer?

2009-01-27 Thread Michael Smith
Bill,

Try separating the QUERY_LAYERS with a space rather than a comma. MapServer
uses space delimited values (gets changed to + separated in the URL).

Mike


-- 
Michael Smith
RSGIS Center
ERDC - CRREL
US Army Corps of Engineers





On 1/27/09  6:13 PM, Bill Thoen bth...@gisnet.com wrote:

 I originally asked this on the OpenLayers forum, but was told that this
 is really a Maperver question. So I'll try it here.
 
 I've got a WMS layer that has two sub-layers in it and I'm trying to get
 attribute information from them via a getFeatureInfo request, but I can
 only get one of them to respond at a time. I've looked at the docs at
 http://trac.openlayers.org/wiki/GetFeatureInfo and noticed that you can
 specify several layers with the QUERY_LAYERS parameter, but I'm finding
 that only the one listed first is active. Also, it's not clear what
 layer you specify at the root of the request, but it looks like it's
 supposed to be different from the layers you're querying. Anyway, here's
 what I'm trying:
 
 I open and load the combined layer like so:
  base = new OpenLayers.Layer.WMS(
Base,
http://192.168.0.250/cgi-bin/mapserv?map=base.map;,
{ layers: [us_states, us_interstate] }
  );
  map.addLayer(base);
 
 
 And here's the request string I'm sending to MapServer:
 
 var url = base.getFullRequestString({
  REQUEST: GetFeatureInfo,
  EXCEPTIONS: application/vnd.ogc.se_xml,
  FORMAT: 'png',
  BBOX: map.getExtent().toBBOX(),
  X: event.xy.x,
  Y: event.xy.y,
  INFO_FORMAT: 'text/plain',
  QUERY_LAYERS: us_interstate, us_states,
  FEATURE_COUNT: 1,
  WIDTH: map.size.w,
  HEIGHT: map.size.h},
  http://192.168.0.250/cgi-bin/mapserv?map=base.map;);
 OpenLayers.loadURL(url, '', this, setHTML);
 
 Note the QUERY_LAYERS line. As shown here, it responds with interstate
 attributes only when I click on an interstate roadway feature, but I get
 nothing when I click on a state. If I reverse the order of these layers
 in the list, then clicking on a state returns attributes from the
 us_states table only. Even if I click on a spot where features in both
 layers coincide, it returns only the attributes for the layer listed first.
 
 Also, setting the FEATURE_COUNT parameter to something higher than 1 just
 gives me more results from the single that  is working.
 
 So how do I use multiple layers in the QUERY_LAYERS parameter, or do I
 get only one at a time? Also, I just guessed at using the layer called
 'base' for the getFeatureInfo oject, what is supposed to be used here?
 
 TIA,
 - Bill Thoen
 
 
 
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] getFeatureInfo() Only Works on One Layer?

2009-01-27 Thread Bill Thoen
No, that's not it. I tried both a space and a '+' instead of the comma, 
but neither worked.


Michael Smith wrote:

Bill,

Try separating the QUERY_LAYERS with a space rather than a comma. MapServer
uses space delimited values (gets changed to + separated in the URL).

Mike


  


___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] getFeatureInfo() Only Works on One Layer?

2009-01-27 Thread Christopher Schmidt
On Tue, Jan 27, 2009 at 05:36:12PM -0700, Bill Thoen wrote:
 No, that's not it. I tried both a space and a '+' instead of the comma, 
 but neither worked.

Bill,

As I suggested before, I highly recommend taking the *actual URL*, and
tweaking that, without the interference of OpenLayers in the middle.

If you can share a URL that's not working, especially against a
liveserver, that would probably be helpful to all involved.

Regards,
-- 
Christopher Schmidt
MetaCarta
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] getFeatureInfo() Only Works on One Layer?

2009-01-27 Thread Yewondwossen Assefa

Bill,

You might try setting the layers in the QUERY_LAYERS parameter without 
any space: QUERY_LAYERS: us_interstate,us_states.
If that does not work, as suggested you might give the full URL sent to 
Mapserver.  From what I can see, query on more that one layer is 
possible  (URL using the Mapserver5.2.1 : 
http://www2.dmsolutions.ca/cgi-bin/mswms_gmap?SERVICE=WMSVERSION=1.1.1REQUEST=GetFeatureInfoBBOX=-173.433000,36.354100,-12.969800,83.746600SRS=EPSG:4326WIDTH=785HEIGHT=232LAYERS=park%2CpopplaceSTYLES=%2CFORMAT=image/pngTRANSPARENT=TRUEQUERY_LAYERS=popplace,parkINFO_FORMAT=text/plainX=302Y=121feature_count=1


Best Regards.


Bill Thoen wrote:
I originally asked this on the OpenLayers forum, but was told that this 
is really a Maperver question. So I'll try it here.


I've got a WMS layer that has two sub-layers in it and I'm trying to get 
attribute information from them via a getFeatureInfo request, but I can 
only get one of them to respond at a time. I've looked at the docs at  
http://trac.openlayers.org/wiki/GetFeatureInfo and noticed that you can 
specify several layers with the QUERY_LAYERS parameter, but I'm finding 
that only the one listed first is active. Also, it's not clear what 
layer you specify at the root of the request, but it looks like it's 
supposed to be different from the layers you're querying. Anyway, here's 
what I'm trying:


I open and load the combined layer like so:
base = new OpenLayers.Layer.WMS(
  Base,
  http://192.168.0.250/cgi-bin/mapserv?map=base.map;,
  { layers: [us_states, us_interstate] }
);
map.addLayer(base);


And here's the request string I'm sending to MapServer:

var url = base.getFullRequestString({
REQUEST: GetFeatureInfo,
EXCEPTIONS: application/vnd.ogc.se_xml,
FORMAT: 'png',
BBOX: map.getExtent().toBBOX(),
X: event.xy.x,
Y: event.xy.y,
INFO_FORMAT: 'text/plain',
QUERY_LAYERS: us_interstate, us_states,
FEATURE_COUNT: 1,
WIDTH: map.size.w,
HEIGHT: map.size.h},
http://192.168.0.250/cgi-bin/mapserv?map=base.map;);
OpenLayers.loadURL(url, '', this, setHTML);

Note the QUERY_LAYERS line. As shown here, it responds with interstate 
attributes only when I click on an interstate roadway feature, but I get 
nothing when I click on a state. If I reverse the order of these layers 
in the list, then clicking on a state returns attributes from the 
us_states table only. Even if I click on a spot where features in both 
layers coincide, it returns only the attributes for the layer listed first.


Also, setting the FEATURE_COUNT parameter to something higher than 1 just
gives me more results from the single that  is working.

So how do I use multiple layers in the QUERY_LAYERS parameter, or do I 
get only one at a time? Also, I just guessed at using the layer called 
'base' for the getFeatureInfo oject, what is supposed to be used here?


TIA,
- Bill Thoen



___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users




--

Assefa Yewondwossen
Software Analyst

Email: ass...@dmsolutions.ca
http://www.dmsolutions.ca/

Phone: (613) 565-5056 (ext 14)
Fax:   (613) 565-0925


___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] getFeatureInfo() Only Works on One Layer?

2009-01-27 Thread Bill Thoen
Well, when I moved the application to a publicly-accessible server to 
show you all, it worked as it should. Turns out my server has the latest 
version of MapServer installed, but my workstation is running an older 
one, and so I guess the problem got fixed in the newer release. 




Yewondwossen Assefa wrote:

Bill,

You might try setting the layers in the QUERY_LAYERS parameter without 
any space: QUERY_LAYERS: us_interstate,us_states.
If that does not work, as suggested you might give the full URL sent 
to Mapserver.  From what I can see, query on more that one layer is 
possible  (URL using the Mapserver5.2.1 : 
http://www2.dmsolutions.ca/cgi-bin/mswms_gmap?SERVICE=WMSVERSION=1.1.1REQUEST=GetFeatureInfoBBOX=-173.433000,36.354100,-12.969800,83.746600SRS=EPSG:4326WIDTH=785HEIGHT=232LAYERS=park%2CpopplaceSTYLES=%2CFORMAT=image/pngTRANSPARENT=TRUEQUERY_LAYERS=popplace,parkINFO_FORMAT=text/plainX=302Y=121feature_count=1 



Best Regards.


Bill Thoen wrote:
I originally asked this on the OpenLayers forum, but was told that 
this is really a Maperver question. So I'll try it here.


I've got a WMS layer that has two sub-layers in it and I'm trying to 
get attribute information from them via a getFeatureInfo request, but 
I can only get one of them to respond at a time. I've looked at the 
docs at  http://trac.openlayers.org/wiki/GetFeatureInfo and noticed 
that you can specify several layers with the QUERY_LAYERS parameter, 
but I'm finding that only the one listed first is active. Also, it's 
not clear what layer you specify at the root of the request, but it 
looks like it's supposed to be different from the layers you're 
querying. Anyway, here's what I'm trying:


I open and load the combined layer like so:
base = new OpenLayers.Layer.WMS(
  Base,
  http://192.168.0.250/cgi-bin/mapserv?map=base.map;,
  { layers: [us_states, us_interstate] }
);
map.addLayer(base);


And here's the request string I'm sending to MapServer:

var url = base.getFullRequestString({
REQUEST: GetFeatureInfo,
EXCEPTIONS: application/vnd.ogc.se_xml,
FORMAT: 'png',
BBOX: map.getExtent().toBBOX(),
X: event.xy.x,
Y: event.xy.y,
INFO_FORMAT: 'text/plain',
QUERY_LAYERS: us_interstate, us_states,
FEATURE_COUNT: 1,
WIDTH: map.size.w,
HEIGHT: map.size.h},
http://192.168.0.250/cgi-bin/mapserv?map=base.map;);
OpenLayers.loadURL(url, '', this, setHTML);

Note the QUERY_LAYERS line. As shown here, it responds with 
interstate attributes only when I click on an interstate roadway 
feature, but I get nothing when I click on a state. If I reverse the 
order of these layers in the list, then clicking on a state returns 
attributes from the us_states table only. Even if I click on a spot 
where features in both layers coincide, it returns only the 
attributes for the layer listed first.


Also, setting the FEATURE_COUNT parameter to something higher than 1 
just

gives me more results from the single that  is working.

So how do I use multiple layers in the QUERY_LAYERS parameter, or do 
I get only one at a time? Also, I just guessed at using the layer 
called 'base' for the getFeatureInfo oject, what is supposed to be 
used here?


TIA,
- Bill Thoen



___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users





___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo for number in textfield

2008-09-02 Thread Sven Schroeter

Steve,
it's really the problem with the template substitution string, with mynr 
it works, thank you very much!

Sven

- Original Message - 
From: Steve Lime [EMAIL PROTECTED]

To: mapserver-users@lists.osgeo.org; [EMAIL PROTECTED]
Sent: Tuesday, September 02, 2008 12:48 AM
Subject: Re: [mapserver-users] GetFeatureInfo for number in textfield


nr is also a template substitution string (means number of results) in 
mapserver templates so I'm guessing
that's being returned instead of the column values. A value of 1 for every 
result seems to confirm that. The
work around would be to rename the column in your SQL statement (eg nr as 
mynr).


Steve


Sven Schroeter [EMAIL PROTECTED] 09/01/08 10:54 AM 

Hi,
My System: Mapserver 5.02 on Win 2003 Server with Postgres/Postgis 8.3/1.3.
I make a GetFeatureInfo Request from a WMS-Service:

With
INFO_FORMAT=text/plain
every field from my Postgis-table comes with a correctly result:
For example

GetFeatureInfo results:

Layer 'naturschutzgebiet'
 Feature 13288152:
   geodb_oid = '175'
   objectid = '175'
   nr = '23308'
   name = 'Ernstberg'
   ...

The Field nr is a textfield with some numbers as strings, for example nr
= '23308'.
If I try to get a result via html-template (INFO_FORMAT=text/html)
everything works fine except the field nr.
For this field I get in every query a 1.

any ideas?

Thanks
Sven


___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users



___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo for number in textfield

2008-09-01 Thread Steve Lime
nr is also a template substitution string (means number of results) in 
mapserver templates so I'm guessing
that's being returned instead of the column values. A value of 1 for every 
result seems to confirm that. The
work around would be to rename the column in your SQL statement (eg nr as 
mynr). 

Steve

 Sven Schroeter [EMAIL PROTECTED] 09/01/08 10:54 AM 
Hi,
My System: Mapserver 5.02 on Win 2003 Server with Postgres/Postgis 8.3/1.3.
I make a GetFeatureInfo Request from a WMS-Service:

With
INFO_FORMAT=text/plain
every field from my Postgis-table comes with a correctly result:
For example

GetFeatureInfo results:

Layer 'naturschutzgebiet'
  Feature 13288152:
geodb_oid = '175'
objectid = '175'
nr = '23308'
name = 'Ernstberg'
...

 The Field nr is a textfield with some numbers as strings, for example nr 
= '23308'.
If I try to get a result via html-template (INFO_FORMAT=text/html) 
everything works fine except the field nr.
For this field I get in every query a 1.

any ideas?

Thanks
Sven 


___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo error

2008-07-06 Thread Jeff McKenna

On 6-Jul-08, at 7:04 AM, Steve White wrote:

Trying to get some HTML by sending in a GetFeatureInfo request and  
getting the following error:


msWMSLoadGetMapParams(): Image handling error. Unsupported output  
format (text/html).


Here’s the test map file:

MAP
  NAME TESTMS
  STATUS  ON
  UNITS METERS
  SHAPEPATH  /scripts/
  IMAGECOLOR  0 255 255
  SIZE 400 400
   
DEBUG   ON

  IMAGETYPE  PNG
  EXTENT -4.35 56.14 -3.23 56.91

WEB
  METADATA
wms_titleTEST MS
wms_onlineresource http://localhost/scripts/mapserv.exe; 

wms_srs  EPSG:4326 EPSG: 
54004 EPSG:27700

wms_feature_info_mime_type text/plain
  END

IMAGEPATH   /tmp/
IMAGEURL  /tmp/
LOG   /tmp/ 
mapserver.log
TEMPLATE   /tmp/ 
template.html
EMPTY  /tmp/ 
template.html


END

PROJECTION
  init=epsg:4326
END

SYMBOL
  NAME circle
  TYPE ellipse
  FILLED true
  POINTS
1 1
  END
END

LAYER
 
NAME
MedievalBattlefields

METADATA
wms_title 
MedievalBattlefields

gml_include_items all
wms_include_items   all
wms_feature_info_mime_type   text/html
END
 
TYPE  POINT
 
DATA  
MedievalBattlefields
TEMPLATE   / 
tmp/template.html
 
STATUS 
ON


PROJECTION
init 
=epsg:4326

END

CLASS
SYMBOL circle
SIZE 10
COLOR 0 0 255
END

END #end of layer

END # end of mapfile

I’m sending in the GetFeatueInfo using a Url like this one:

http://localhost/scripts/mapserv.exe?map=MedievalBattlefields.mapSERVICE=WMSVERSION=1.1.0REQUEST=GetFeatureInfoX=1127Y=336QUERY_LAYERS=MedievalBattlefieldsLAYERS=MedievalBattlefieldsINFO_FORMAT=text/htmlBBOX=-19.51171875,48.69096039092549,13.07373046875,59.94400716933026WIDTH=768HEIGHT=768SRS=EPSG:4326FORMAT=text/html

Any ideas why the error is being thrown?


try changing your web object's wms_feature_info_mime_type metadata  
value to text/html maybe, and then verify what formats are supported  
by checking your GetCapabilities response.


---
Jeff McKenna
FOSS4G Consulting and Training Services
http://www.gatewaygeomatics.com/

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo from PostGis database

2008-07-01 Thread SAEZ Laurent - CETE Méditerr./DI/ETER

Hi Guillaume,

You're right. A friend of mine has told me the same thing this morning. 
It works goo ! Youpi !


Thank you very much for your help

Regards

Le 01/07/2008 07:53,  Guillaume Sueur (par Internet) a écrit  :

add gid to the SQL string :

DATA  the_geom FROM (select gid, numero, feuille,
 the_geom FROM localisant) as foo USING UNIQUE gid USING SRID=27582

and try to use EPSG:27572 as 27582 is deprecated.

Regards,
GUillaume



SAEZ Laurent - CETE Méditerr./DI/ETER a écrit :
  

Hi,

I've tried to use the gid column, but the getfeatureinfo reports me an
error :
Postgresql reports the error as #39;ERREUR:  la colonne «gid»
n#39;existe pas
#39;
The error tells me that the gid column doesn't exist. You can trust me,
I have a field called gid.

Thanks

Le 30/06/2008 19:49,  Bart van den Eijnden (OSGIS) (par Internet) a
écrit  :


You shouldn't use the geometry column as the unique column (USING
UNIQUE X).

Try an integer type column for that.

Best regards,
Bart

SAEZ Laurent - CETE Méditerr./DI/ETER wrote:
  

Hi list,

I'm trying to access data fields using getfeatureinfo from a PostGIS
database.
I've read some articles about it, but it seems that I'm a newbie.
I've no problem with data access when I do some getmap requests.

Here is a part of my mapfile :

   LAYER
   NAMEbdparcellaire_numero
   TYPEannotation
   STATUS ON
   DUMP TRUE
   TEMPLATE blank.html
   MINSCALE 100
   MAXSCALE 1
   CONNECTIONTYPEpostgis
   CONNECTIONuser=toto password=toto
dbname=bdparcellaire_2007 host=172.23.208.134 port=5432
   
   LABELITEMnumero

   CLASS
 LABEL
   TYPE TRUETYPE
   WRAP #
   COLOR 0 0 0
   OUTLINECOLOR 254 254 254
   FONT arial
   SIZE 9
   POSITION CC
   FORCE false
   PARTIALS false
 END
END
   METADATA
   WMS_TITLE Numéros de parcelle (Données BD Parcellaire® -
Copyright IGN)
   wms_abstract Visible entre les échelles 1/100 et 1/10
000wms_srs EPSG:27582 EPSG:27581 EPSG:27583
EPSG:27584 EPSG:27591 EPSG:27592 EPSG:27593 EPSG:27594 EPSG:2154
EPSG:23030 EPSG:23031 EPSG:23032 EPSG:32630 EPSG:32631 EPSG:32632
EPSG:4326
   wms_extent 47650 1620400 1197850 2677450   
WMS_ENCODING UTF-8

   GML_INCLUDE_ITEMS all
   END
   END

When I try this getfeatureinfo request, the XML returned is not
complete :

The request :
http://myIP/cgi-bin/mapserv?map=/data/carto/ref/bdparcellaire/bdparcellaire_2007_direct.mapSERVICE=WMSVERSION=1.1.1REQUEST=GetFeatureInfoSRS=EPSG%3A27582WIDTH=600HEIGHT=400BBOX=643470,1743572,643590,1743652LAYERS=bdparcellaire_numeroSTYLES=FORMAT=image%2FpngQUERY_LAYERS=bdparcellaire_numeroX=167Y=175INFO_FORMAT=application%2Fvnd.ogc.gmlFEATURE_COUNT=999


The entire XML :
?xml version=1.0 encoding=UTF-8?

msGMLOutput
xmlns:gml=http://www.opengis.net/gml;
xmlns:xlink=http://www.w3.org/1999/xlink;
xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
   bdparcellaire_numero_layer


Why it doesn't work ?
I know that it should be in my DATA object in my mapfile, but I don't
know what exactly...

Thanks a lot...
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users



  

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users




  
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo from PostGis database

2008-06-30 Thread SAEZ Laurent - CETE Méditerr./DI/ETER

Hi,

I've tried to use the gid column, but the getfeatureinfo reports me an 
error :
Postgresql reports the error as #39;ERREUR:  la colonne «gid» 
n#39;existe pas

#39;
The error tells me that the gid column doesn't exist. You can trust me, 
I have a field called gid.


Thanks

Le 30/06/2008 19:49,  Bart van den Eijnden (OSGIS) (par Internet) a 
écrit  :
You shouldn't use the geometry column as the unique column (USING 
UNIQUE X).


Try an integer type column for that.

Best regards,
Bart

SAEZ Laurent - CETE Méditerr./DI/ETER wrote:

Hi list,

I'm trying to access data fields using getfeatureinfo from a PostGIS 
database.

I've read some articles about it, but it seems that I'm a newbie.
I've no problem with data access when I do some getmap requests.

Here is a part of my mapfile :

   LAYER
   NAMEbdparcellaire_numero
   TYPEannotation
   STATUS ON
   DUMP TRUE
   TEMPLATE blank.html
   MINSCALE 100
   MAXSCALE 1
   CONNECTIONTYPEpostgis
   CONNECTIONuser=toto password=toto 
dbname=bdparcellaire_2007 host=172.23.208.134 port=5432
   DATAthe_geom FROM (select numero, feuille, 
the_geom FROM localisant) as foo USING UNIQUE the_geom USING SRID=27582

   LABELITEMnumero
   CLASS
 LABEL
   TYPE TRUETYPE
   WRAP #
   COLOR 0 0 0
   OUTLINECOLOR 254 254 254
   FONT arial
   SIZE 9
   POSITION CC
   FORCE false
   PARTIALS false
 END
END
   METADATA
   WMS_TITLE Numéros de parcelle (Données BD Parcellaire® - 
Copyright IGN)
   wms_abstract Visible entre les échelles 1/100 et 1/10 
000wms_srs EPSG:27582 EPSG:27581 EPSG:27583 
EPSG:27584 EPSG:27591 EPSG:27592 EPSG:27593 EPSG:27594 EPSG:2154 
EPSG:23030 EPSG:23031 EPSG:23032 EPSG:32630 EPSG:32631 EPSG:32632 
EPSG:4326
   wms_extent 47650 1620400 1197850 2677450
WMS_ENCODING UTF-8

   GML_INCLUDE_ITEMS all
   END
   END

When I try this getfeatureinfo request, the XML returned is not 
complete :


The request : 
http://myIP/cgi-bin/mapserv?map=/data/carto/ref/bdparcellaire/bdparcellaire_2007_direct.mapSERVICE=WMSVERSION=1.1.1REQUEST=GetFeatureInfoSRS=EPSG%3A27582WIDTH=600HEIGHT=400BBOX=643470,1743572,643590,1743652LAYERS=bdparcellaire_numeroSTYLES=FORMAT=image%2FpngQUERY_LAYERS=bdparcellaire_numeroX=167Y=175INFO_FORMAT=application%2Fvnd.ogc.gmlFEATURE_COUNT=999 



The entire XML :
?xml version=1.0 encoding=UTF-8?

msGMLOutput
xmlns:gml=http://www.opengis.net/gml;
xmlns:xlink=http://www.w3.org/1999/xlink;
xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
   bdparcellaire_numero_layer


Why it doesn't work ?
I know that it should be in my DATA object in my mapfile, but I don't 
know what exactly...


Thanks a lot...
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users






___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo from PostGis database

2008-06-30 Thread Guillaume Sueur
add gid to the SQL string :

DATA  the_geom FROM (select gid, numero, feuille,
 the_geom FROM localisant) as foo USING UNIQUE gid USING SRID=27582

and try to use EPSG:27572 as 27582 is deprecated.

Regards,
GUillaume



SAEZ Laurent - CETE Méditerr./DI/ETER a écrit :
 Hi,
 
 I've tried to use the gid column, but the getfeatureinfo reports me an
 error :
 Postgresql reports the error as #39;ERREUR:  la colonne «gid»
 n#39;existe pas
 #39;
 The error tells me that the gid column doesn't exist. You can trust me,
 I have a field called gid.
 
 Thanks
 
 Le 30/06/2008 19:49,  Bart van den Eijnden (OSGIS) (par Internet) a
 écrit  :
 You shouldn't use the geometry column as the unique column (USING
 UNIQUE X).

 Try an integer type column for that.

 Best regards,
 Bart

 SAEZ Laurent - CETE Méditerr./DI/ETER wrote:
 Hi list,

 I'm trying to access data fields using getfeatureinfo from a PostGIS
 database.
 I've read some articles about it, but it seems that I'm a newbie.
 I've no problem with data access when I do some getmap requests.

 Here is a part of my mapfile :

LAYER
NAMEbdparcellaire_numero
TYPEannotation
STATUS ON
DUMP TRUE
TEMPLATE blank.html
MINSCALE 100
MAXSCALE 1
CONNECTIONTYPEpostgis
CONNECTIONuser=toto password=toto
 dbname=bdparcellaire_2007 host=172.23.208.134 port=5432

LABELITEMnumero
CLASS
  LABEL
TYPE TRUETYPE
WRAP #
COLOR 0 0 0
OUTLINECOLOR 254 254 254
FONT arial
SIZE 9
POSITION CC
FORCE false
PARTIALS false
  END
 END
METADATA
WMS_TITLE Numéros de parcelle (Données BD Parcellaire® -
 Copyright IGN)
wms_abstract Visible entre les échelles 1/100 et 1/10
 000wms_srs EPSG:27582 EPSG:27581 EPSG:27583
 EPSG:27584 EPSG:27591 EPSG:27592 EPSG:27593 EPSG:27594 EPSG:2154
 EPSG:23030 EPSG:23031 EPSG:23032 EPSG:32630 EPSG:32631 EPSG:32632
 EPSG:4326
wms_extent 47650 1620400 1197850 2677450   
 WMS_ENCODING UTF-8
GML_INCLUDE_ITEMS all
END
END

 When I try this getfeatureinfo request, the XML returned is not
 complete :

 The request :
 http://myIP/cgi-bin/mapserv?map=/data/carto/ref/bdparcellaire/bdparcellaire_2007_direct.mapSERVICE=WMSVERSION=1.1.1REQUEST=GetFeatureInfoSRS=EPSG%3A27582WIDTH=600HEIGHT=400BBOX=643470,1743572,643590,1743652LAYERS=bdparcellaire_numeroSTYLES=FORMAT=image%2FpngQUERY_LAYERS=bdparcellaire_numeroX=167Y=175INFO_FORMAT=application%2Fvnd.ogc.gmlFEATURE_COUNT=999


 The entire XML :
 ?xml version=1.0 encoding=UTF-8?

 msGMLOutput
 xmlns:gml=http://www.opengis.net/gml;
 xmlns:xlink=http://www.w3.org/1999/xlink;
 xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
bdparcellaire_numero_layer


 Why it doesn't work ?
 I know that it should be in my DATA object in my mapfile, but I don't
 know what exactly...

 Thanks a lot...
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users




 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo Problem in Mapserver5

2008-05-19 Thread Guillaume Sueur

Hi,

I would say something is wrong in your mapfile - SCALEBAR section. Maybe 
some option has changed in version 5. Try to delete that section and 
test again.


Regards,

Guillaume

kevin gomes a écrit :

Hello,
I'm facing problems making the GetFeatureInfo request in Mapserver5.

The following GetFeatureInfo request, returns expected results in 
Mapserver4.


*http://demo.binyasit.com/gvis/htdocs/protogis_wms.cgi?REQUEST=GetFeatureInfoEXCEPTIONS=application/vnd.ogc.se_xml; 
http://demo.binyasit.com/gvis/htdocs/protogis_wms.cgi?REQUEST=GetFeatureInfoEXCEPTIONS=application/vnd.ogc.se_xml;

BBOX=64.998443,15.821582,85.960357,21.578418X=492Y=119INFO_FORMAT=text/htmlQUERY_LAYERS=districts
FEATURE_COUNT=2WIDTH=954HEIGHT=262VERSION=1.1.1LAYERS=districts
*
But when i make the same request in Mapserver5, it asks for additional 
parameters. Then i checked the Migration Docs and modified the request 
as follows


*http://pcmcgisda.org.in/cgi-bin/mapserv.5b?format=image/pngSRS=EPSG:26915map=/srv/release.pcmc.org/map/.config.mapREQUEST=GetFeatureInfo; 
http://pcmcgisda.org.in/cgi-bin/mapserv.5b?format=image/pngSRS=EPSG:26915map=/srv/release.pcmc.org/map/.config.mapREQUEST=GetFeatureInfo;

EXCEPTIONS=application/vnd.ogc.se_xmlBBOX=356415.589844,2056761.035156,395041.410156,2067368.964844X=440Y=98INFO_FORMAT=text/html
QUERY_LAYERS=watersupplyline,esr,valveFEATURE_COUNT=2WIDTH=954HEIGHT=262VERSION=1.1.1LAYERS=watersupplyline,esr,valveSTYLES=

*But it returns the following error.*
*


?xml version='1.0' encoding=ISO-8859-1 standalone=no ?
!DOCTYPE ServiceExceptionReport SYSTEM 
http://schemas.opengis.net/wms/1.1.1/exception_1_1_1.dtd;

ServiceExceptionReport version=1.1.1
ServiceException
msDrawScalebar(): General error message. Unsupported scalebar style.
/ServiceException
/ServiceExceptionReport

I am not able to make out what is wrong with the Request. Can you please 
guide me.

Regards,
--
Kevin Gomes ...enjoy being GIS maniacs




___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


--


___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] GetFeatureInfo request against an OGR virtual data source

2008-05-19 Thread Frank Warmerdam

Robert Sanson wrote:

Dear List
 
I have set up Mapserver map file configured as a WMS service. One of my 
layers is a OGR point data source drawing its coodinates from x,y fields 
in a SQL-Server database via ODBC. The x,y coordinates are in NZ Map 
Grid projection (EPSG:27200) but all my other layers are NZ Transverse 
Mercator (EPSG:2193).
 
My top level SRS is defined as EPSG:2193 (NZTM).
 
The particular OGR data source is therefore being projected to 
EPSG:2193, which it seems to be doing properly.
 
The layers in the map are displaying correctly, using a number of 
different clients - OpenLayers, uDig, ArcMap.
 
Now, my problem is that sending the following GetFeatureInfo request 
from OpenLayers: (also tested manually via a Browser URL):
 
http://10.65.192.1/cgi-bin/gsswms.exe?service=WMSversion=1.1.1request=GetFeatureInfoLAYERS=apiaries_devQUERY_layers=apiaries_devFORMAT=image/pngINFO_FORMAT=gmlSRS=EPSG:2193BBOX=1478229.486251,5375153.051004,1482462.817299,5379386.382051WIDTH=512HEIGHT=512X=341Y=19STYLES 
http://10.65.192.1/cgi-bin/gsswms.exe?service=WMSversion=1.1.1request=GetFeatureInfoLAYERS=apiaries_devQUERY_layers=apiaries_devFORMAT=image/pngINFO_FORMAT=gmlSRS=EPSG:2193BBOX=1478229.486251,5375153.051004,1482462.817299,5379386.382051WIDTH=512HEIGHT=512X=341Y=19STYLES=
 
returns the first record in the database table, regardless of the BBOX 
and location parameters, which are all in terms of EPSG:2193 (NZTM).
 
Can MapServer back project the GetFeatureInfo request from EPSG:2193 
into valid NZMG (EPSG:27200) coordinates in order to request the correct 
feature details via OGR?


Robert,

The problem is (likely) due to the lack of a persistent feature id when
reading from ODBC.  This doesn't negatively impact drawing but completely
fouls up MapServer's two pass query mechanism.

If you have an integer field on the source table that is a unique id,
you will likely be able to mark it as the feature id using the
FID element in the VRT file.  But I'm not sure if that is enough, since
when the VRT asks the ODBC layer for a particular feature by fid,
the ODBC driver will still do the wrong thing.

I see there is also a secret configure option in the ODBC driver for
selecting a field as an FID.  So, if your unique integer id field
was called id, adding the following within your map should force
the OGR ODBC driver to use it:

  CONFIG ODBC_OGR_FID id

Generally speaking doing MapServer queries against OGR feature
datasources without persistent feature ids is problematic and
should be avoided if practical.

Best regards,
--
---+--
I set the clouds in motion - turn up   | Frank Warmerdam, [EMAIL PROTECTED]
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush| President OSGeo, http://osgeo.org

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users