Re: [mapserver-users] WMS-T with daterange attribute

2020-04-08 Thread pe_lord
I've forgot a important thing in my question:


Do you know if there is a way for Mapserver to manage a daterange field (or
a
start_date AND end_date) in a wms-t request?

The request only provide a single date, not a range. 
Does Mapserver could generate a SQL like  :
select ... from table where dateRangeField contains userProvidedDate





--
Sent from: http://osgeo-org.1560.x6.nabble.com/Mapserver-User-f4226646.html
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

[mapserver-users] WMS-T with daterange attribute

2020-04-08 Thread pe_lord
I have a time enabled dataset containing various attributes, 3 of them are
related to time. The temporal steps between the records are not constant...

The dataset presents roads history. There is many overlap inside this
dataset.

1st attribute = start_date
2nd attribute = end_date
3rd attribute = period_valid [start_date,end_date]

Here what i've tried:

1- Generate a step constant temporal dataset (e.g. create a geometry for
each date I want to publish by wms-t, and join the geometry (and attribute)
where the step intersect the period for each records). Then my dataset pass
from 250K to 11M records..
2- Keep my original dataset and let mapserver manage the temporal
intersection between the user's provided date AND the period (period_valid).

In this ladder situation, mapserver send me this error:


PGRES_FATAL_ERROR (7)
...
Error (ERROR:  operator does not exist: daterange >= timestamp with time
zone

LINE 1: ...92 321002.819068926))',3798) and ("period_valid" between da...

 ^

HINT:  No operator matches the given name and argument type(s). You might
need to add explicit type casts.


Do you know if there is a way for Maserver to manage a daterange field (or a
start_date AND end_date) in a wms-t request?









--
Sent from: http://osgeo-org.1560.x6.nabble.com/Mapserver-User-f4226646.html
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] Combining WMS Filter and Style Parameters

2019-07-31 Thread pe_lord
Yes I encounter the same issue as you mentioned.




--
Sent from: http://osgeo-org.1560.x6.nabble.com/Mapserver-User-f4226646.html
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

[mapserver-users] Mapserver 7.2.1 Classgroup

2019-07-23 Thread pe_lord
I have a layer defined with multiple classgroup.

Here the getcapabilities response...






Here my mapfile

CLASSGROUP "group1"

CLASS
GROUP "group1"

END

CLASS
GROUP "group2"
 ...
END


Do you know if there is a way to broadcast a different name for the style's
title and the style's name?







--
Sent from: http://osgeo-org.1560.x6.nabble.com/Mapserver-User-f4226646.html
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] 7.2.1 html [shpxy] formating (templating)

2019-05-10 Thread pe_lord
Thanks Steve you were right!

 xf="&"  




--
Sent from: http://osgeo-org.1560.x6.nabble.com/Mapserver-User-f4226646.html
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

[mapserver-users] 7.2.1 html [shpxy] formating (templating)

2019-05-07 Thread pe_lord
I try to format my html getfeatureinfo response with my geometry coordinate
(point).

In my html.html response, I want [shpxy] with a "&" separator. 

Here what I set into my html template:
[shpxy xh="x=" yh="y=" cs="&"]

and I get this response:
x=701467,y=305958 

I need to concatenate my x an y with a & to build an url. Something I'm
doing wrong?




--
Sent from: http://osgeo-org.1560.x6.nabble.com/Mapserver-User-f4226646.html
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] WFS 2.0 and QGIS

2019-03-22 Thread pe_lord
I use QGIS 3.4 with mapserver 7.2.1

Everything is fine.

From fiddler:
 



--
Sent from: http://osgeo-org.1560.x6.nabble.com/Mapserver-User-f4226646.html
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

[mapserver-users] Geotransform AND WMS Filter

2019-03-12 Thread pe_lord
Does somebody has an idea about this issue?

https://github.com/mapserver/mapserver/issues/5744

Pierre





--
Sent from: http://osgeo-org.1560.x6.nabble.com/Mapserver-User-f4226646.html
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

[mapserver-users] WFS outputformat zipped geojson(s)?

2019-02-15 Thread pe_lord
Hi

I try to output many wfs layers (typenames) to a single zipped output.

This is working properly for zipped shapefiles. 

...?service=wfs&version=2.0.0&request=getfeature&typename=A,B&outputformat=SHP

OUTPUTFORMAT
NAME "SHP"
DRIVER "OGR/ESRI Shapefile"
FORMATOPTION "STORAGE=filesystem"
FORMATOPTION "FORM=zip"
FORMATOPTION "FILENAME=result.zip"
END
OUTPUTFORMAT
NAME "geojson"
DRIVER "OGR/GEOJSON"
FORMATOPTION "LCO:COORDINATE_PRECISION=15"
FORMATOPTION "LCO:WRITE_BBOX=YES"
FORMATOPTION "STORAGE=filesystem"
FORMATOPTION "FORM=zip"
FORMATOPTION "FILENAME=result.geojson.zip"
END

For "Zipped" geojson
...?service=wfs&version=2.0.0&request=getfeature&typename=A,B&outputformat=geojson

I get :

General error message. 
OGR OGR_DS_CreateLayer failed for layer 'B' with driver 'GEOJSON'.

Does somebody already create zipped geojson?






--
Sent from: http://osgeo-org.1560.x6.nabble.com/Mapserver-User-f4226646.html
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

[mapserver-users] Mapserver 7.2.x WMS with Filter (rfc118)

2018-12-03 Thread pe_lord
I have a web app interfacing and building the ogc filter xml query. 

https://geoegl.msp.gouv.qc.ca/igo2/apercu-qc/?context=rfc118&tool=ogcFilter
  

Here the picture for a WMS layer:
1- without filter
 a- getmap is ok
 b- getfeatureinfo response is OK. All my features under my click are
found. 
2- with a spatial filter ONLY (square geometry). 
 a- getmap is ok
 b- getfeatureinfo response is OK. All my features under my click are
found. 
3- with an attribute filter ( ex: Topographic System Index (FCA_NO_FEU =
21M05NE)  ). 
   or
   with an attribute and a spatial filter (square geometry and FCA_NO_FEU =
21M05NE). 
 a- getmap is ok (only filtered features are shown)
 b- getfeatureinfo
 1- if I click on a shown feature, response is OK. All my
features under my click are found.
 2- if I click outside shown features, response is not ok
because the getfeatureinfo return content not shown on getmap. Filters with
attributes do not seem to be honored on getfeatureinfo.

To fire a getfeatureinfo, simply click on map. 
Here an explanation for how to add filters:
 

I've tried with Mapserver 7.2.0 and 7.2.1 with various sources (i.e.
Postgis, Oracle, Sqlite, GPKG, SHP), getting the same results (attribute
filters on getfeatureinfo not honored).
My layers are properly defined. 
I've alseo tried with my filtering attribute properly typed for each field: 
  - gml_itemname_type "Character" 

Any hint?





--
Sent from: http://osgeo-org.1560.x6.nabble.com/Mapserver-User-f4226646.html
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] GetMap vs GetFeatureinfo sort

2018-08-27 Thread pe_lord
Thanks. 

Here more informations.

I have 2 overlapping geometries. 

My class are based on a field ==> CLASSITEM "code_type" and appear in my
mapfile in this order.

CLASS
NAME "Blue CLASS"
EXPRESSION '1'
STYLE
SYMBOL "square"
SIZE 8
COLOR 53 68 150
END
END
...
CLASS
NAME "Red Class"
EXPRESSION '4'
STYLE
SYMBOL "square"
SIZE 8
COLOR 188 34 115
END
END

My data is stored in this order into PG, with this structure (id,
code_type,geom):
id1,4,geom
id2,1,geom

If I understand properly, my last geometrie (id2) is plotted on top of other
classes. This is making sense. 

Otherwise, in the getfeatureinfo, the same order is kept, this a non-sense
according to my classes's order.

I would like to to present this data in a flipped order like, according to
my classes's logic:
id2,1
id1,4


I expect that the topmost feature returned in getfeatureinfo response
correspond to the topmost feature drawn on map. I would like to have a
constant response, independently from my template format (gml, html,
json...)

You will find an 
 


Here what I tried without succes:
- flip my mapfile's classes
- sort my data based on my field (code_type). In this case, either I have
the getmap sorted in the right order, or the getfeatureinfo. Both behaviors
are impossible at the same time.





--
Sent from: http://osgeo-org.1560.x6.nabble.com/Mapserver-User-f4226646.html
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

[mapserver-users] GetMap vs GetFeatureinfo sort

2018-08-24 Thread pe_lord
I have 2 superposed points with different attributes. 

When I render my classes, the rendering ordering is defined by the last
geometry retrieved from the db. 
Then my last geometry (I defined an "order by fieldname asc" in my data
section) is on the top of the getmap return image.

On the other hand, I want to invert this sorting when I call a
GetFeatureInfo, to sort this way "order by fieldname desc"

Do you know if there is a way to change sorting order. 

I want to avoid using a runtime substitution.

MapServer version 7.0.3




--
Sent from: http://osgeo-org.1560.x6.nabble.com/Mapserver-User-f4226646.html
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

[mapserver-users] Using Geopackage 1.0 & Spatial view

2018-07-19 Thread pe_lord
I've created a view joining 2 tables (1:M). 
This view is well recognized with QGIS 3.0 & GDAL 2.2.4 (OsGeo4W)

When I use this view in mapserver :
CONNECTIONTYPE OGR
CONNECTION "mygeopackage.gpkg"
DATA "v_my_view"

I get 
msOGRFileOpen(): OGR error. GetLayer(v_my_view) failed for OGR connection.
Check logs.

Here my log(debug 5 & "CPL_DEBUG" "ON").

... msOGRFileOpen(mygeopackage.gpkg)...
... OGROPen(/my_path/mygeopackage.gpkg)
... msConnPoolRegister(v_my_view,mygeopackage.gpkg,0x1dfd3c0)
... msOGRFileOpen(): OGR error. GetLayer(v_my_view) failed for OGR
connection. Check logs.
... GetLayer(v_my_view) failed for OGR connection `mygeopackage.gpkg'.
... msConnPoolRelease(v_my_view,mygeopackage.gpkg,0x1dfd3c0)
... msConnPoolClose(mygeopackage.gpkg,0x1dfd3c0)
... msDrawMap(): Image handling error. Failed to draw layer named
'v_my_view'.
... freeLayer(): freeing layer at 0x1e02ac0.

Then, when I write this view as a table (well recognized with QGIS 3.0 &
GDAL 2.2.4 (OsGeo4W)) , everything is fine with Mapserver.

Seem like my view is crashing my OGR connection.

The only difference between my view and my tables is that my view do not
have gpkg_rtree_index associated?  I've tried from spatialite gui to Select
gpkgAddSpatialIndex(...). But I received this error :
cannot create AFTER trigger on view: v_my_view 

I use Mapserver 7.03 on RedHat.
I don't know which version of gdal is used with Mapserver...sorry


Pierre






--
Sent from: http://osgeo-org.1560.x6.nabble.com/Mapserver-User-f4226646.html
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] HTML template javascript and d3

2018-07-19 Thread pe_lord
This is working perfectly with [field_from_mapserver_raw] . I get the
expected results.

Yes, it is an interesting use of Mapserver, but it's not my idea. I took it
on
https://gis.stackexchange.com/questions/232098/calculate-a-field-in-a-getfeatureinfo-request-with-mapserver-7-0-4



--
Sent from: http://osgeo-org.1560.x6.nabble.com/Mapserver-User-f4226646.html
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] passing variables to includes

2017-10-30 Thread pe_lord
To solve this problem, i've used an scaletoken with multiple parameters
(sorted). 

SCALETOKEN
NAME "%f%"
VALUES
"0" "2|1"
"100" "2|1"  
END
END

And inside my query string to postgis, I've substitued these sorted value
into a sub select and I split with the '|'. 

DATA "the_geom from (SELECT table.*, d.* FROM table, 
(select split_part('%f%','|',1)::integer as
p1,split_part('%f%','|',2)::integer as p2)as d ) as subquery using unique
cod_instl srid=3857"
 



--
Sent from: http://osgeo-org.1560.x6.nabble.com/Mapserver-User-f4226646.html
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] GRABBING some default CGI parameters in MapFile.

2017-10-25 Thread pe_lord
I' trying to do the same thing but I get this error message?

[Wed Oct 25 16:47:35 2017].80906 msPostGISLayerWhichShapes(): Error (ERROR: 
find_srid() - could not find the corresponding SRID - is the geometry
registered in the GEOMETRY_COLUMNS table?  Is there an uppercase/lowercase
mismatch?
CONTEXT:  fonction PL/pgsql find_srid(character varying,character
varying,character varying), line 17 at RAISE


Did you have the same problem? What is wrong...

My query is working correctly into pgadminIII.
I'm working with MapServer version 7.0.4




--
Sent from: http://osgeo-org.1560.x6.nabble.com/Mapserver-User-f4226646.html
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] Stop CLUSTERING beyond scale

2017-10-12 Thread pe_lord
Ok. But does the getfeatureinfo able to go through a group? 



--
Sent from: http://osgeo-org.1560.x6.nabble.com/Mapserver-User-f4226646.html
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

[mapserver-users] Stop CLUSTERING beyond scale

2017-10-12 Thread pe_lord
Hi list,

I would like to know if it is possible beyond a scale denom to  stop
clustering. I have this issue because I cluster some overlapping point and
it is impossible to symbolize the individually when they are clusterized...

I'm looking for this kind of feature:

CLUSTER
 MAXDISTANCE 20  # in pixels
 REGION "ellipse"  # can be rectangle or ellipse
 MINSCALEDENOM 2000  # At 1:2000, Mapserver stops clustering?
END


At this time, as an alternative, I use scaletoken managing various query to
postgis. But this query is in mapunits, not in pixels...

Thanks!






--
Sent from: http://osgeo-org.1560.x6.nabble.com/Mapserver-User-f4226646.html
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] WFS export as GeoJSON or CSV

2017-09-25 Thread pe_lord
I've found.

I forgot to add this parameter to my layer. 

http://mapserver.gis.umn.edu/output/ogr_output.html#geometry-types-supported

My output had mixed feature strored in my geometry column. 





--
Sent from: http://osgeo-org.1560.x6.nabble.com/Mapserver-User-f4226646.html
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] WMS-T in WMS Client

2017-09-21 Thread pe_lord
It is working properly.

Except that I modified the validation part to set a default value for my
parameter.

  VALIDATION
'default_TIME' "1980-01-01/2020-06-01" 
'TIME' '^(TIME=)?.*$'
  END


Now my connection string look like:
CONNECTION "https://ws.mapserver.transports.gouv.qc.ca/swtq?TIME=%TIME%&";

And I set wms_timeextent, wms_timeitem et wms_timeformat into the layer's
metadate section to broadcast wms-t capabilities into my local
getcapabilities.

Thanks!



--
Sent from: http://osgeo-org.1560.x6.nabble.com/Mapserver-User-f4226646.html
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

[mapserver-users] WFS export as GeoJSON or CSV

2017-09-20 Thread pe_lord
I work with Mapserver 7.0.3 to extract some datasets in various format (i.e,
csv, geojson, shp...).

Here my service. 
https://ws.mapserver.transports.gouv.qc.ca/swtq?service=wfs&request=getcapabilities
Here the URL I use to extract data:

https://ws.mapserver.transports.gouv.qc.ca/swtq?service=wfs&version=2.0.0&request=getfeature&typename=ms:bgr_v_dirct_terrt_geomt_act&outputformat=geojson
https://ws.mapserver.transports.gouv.qc.ca/swtq?service=wfs&version=2.0.0&request=getfeature&typename=ms:bgr_v_dirct_terrt_geomt_act&outputformat=csv
https://ws.mapserver.transports.gouv.qc.ca/swtq?service=wfs&version=2.0.0&request=getfeature&typename=ms:bgr_v_dirct_terrt_geomt_act&outputformat=shp

Everything is fine with exportation as shp.
But for CSV and GeoJSON (wkt?), my largest geometry (~79074 vertices) is
downloaded but is not spatially selectable into qgis. And when I zoom, the
geometry disappear?

The problem occur on the most northern geometry/feature.

I've tried to find which version of Gdal Mapserver 7.0.3 use but I didn't
find.




--
Sent from: http://osgeo-org.1560.x6.nabble.com/Mapserver-User-f4226646.html
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

[mapserver-users] WMS-T in WMS Client

2017-09-13 Thread pe_lord
I try to cascade some public wms service in my local (dev). The public wms
has wms-t capabilities. 

When I call this public  WMS

 
, on layer histo_stations_meteoroutieres. 

Here an example of  getfeatureinfo

  
with a time filter.

When I use this layer as a wms client layer within mapserv, I'm unable to
get a filtered result. Here my cascaded wms call.

call

  

Here how I config Mapserver 7.0.4 


LAYER
  NAME "cascade_histo_stations_meteoroutieres"
  TYPE RASTER
  STATUS ON
  CONNECTION "https://ws.mapserver.transports.gouv.qc.ca/swtq?";
  CONNECTIONTYPE WMS
PROJECTION
"init=epsg:3857"
END
  TEMPLATE 'VOID'
  
  METADATA
"wms_title"  "Cascade sm"
"wms_name""histo_stations_meteoroutieres"
"wms_server_version"  "1.1.1"
"wms_format"  "image/png"
"wms_timeitem""-MM-DD"
"wms_timeextent"  "1980-01-01/2020-06-01"
"wms_timeitem""date_mesu"
"wms_timeformat"  "-MM-DD"
  END
END


Am I missing something on my mapfile configuration?  Here my log with a
debug 5 level. There is no param name TIME=...

[Wed Sep 13 16:41:13 2017].331455 HTTP: Starting to prepare HTTP requests.
[Wed Sep 13 16:41:13 2017].331871 HTTP request: id=2,
https://ws.mapserver.transports.gouv.qc.ca/swtq?LAYERS=histo_stations_meteoroutieres&REQUEST=GetFeatureInfo&SERVICE=WMS&FORMAT=image/png&STYLES=&HEIGHT=912&QUERY_LAYERS=histo_stations_meteoroutieres&VERSION=1.1.1&SRS=EPSG:3857&WIDTH=732&BBOX=-9145938.5879864,4467354.72401133,-6541314.70148728,7713336.06546235&TRANSPARENT=TRUE&FEATURE_COUNT=100&INFO_FORMAT=text%2Fhtml&X=372&EXCEPTIONS=application/vnd.ogc.se_xml&Y=490
[Wed Sep 13 16:41:13 2017].331920 HTTP request: id=2,
https://ws.mapserver.transports.gouv.qc.ca/swtq?LAYERS=histo_stations_meteoroutieres&REQUEST=GetLegendGraphic&SERVICE=WMS&FORMAT=image/png&STYLES=&QUERY_LAYERS=histo_stations_meteoroutieres&VERSION=1.1.1&SRS=EPSG:3857&TRANSPARENT=TRUE&SCALE=1.34668e+07&LAYER=histo_stations_meteoroutieres
[Wed Sep 13 16:41:13 2017].331941 HTTP: Before download loop
[Wed Sep 13 16:41:13 2017].668641 msHTTPWriteFct(id=2, 678 bytes)
[Wed Sep 13 16:41:13 2017].711841 msHTTPWriteFct(id=2, 8094 bytes)
[Wed Sep 13 16:41:13 2017].715295 msHTTPWriteFct(id=2, 7685 bytes)
[Wed Sep 13 16:41:13 2017].715377 HTTP: After download loop
[Wed Sep 13 16:41:13 2017].715398 msHTTPExecuteRequests() timing summary per
layer (connect_time + time_to_first_packet + download_time = total_time in
seconds)
[Wed Sep 13 16:41:13 2017].715414 Layer 2: 0.108 + 0.272 + 0.111 = 0.491s
[Wed Sep 13 16:41:13 2017].715442 Layer 2: 0.198 + 0.139 + 0.198 = 0.534s
[Wed Sep 13 16:41:13 2017].756428 freeLayer(): freeing layer at
0xf4cd4f42b0.











--
Sent from: http://osgeo-org.1560.x6.nabble.com/Mapserver-User-f4226646.html
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] Multi template

2017-09-06 Thread pe_lord
What about your own curiosity?
I've retried and I get the same behavior. And you?

Pierre



--
Sent from: http://osgeo-org.1560.x6.nabble.com/Mapserver-User-f4226646.html
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] Multi template

2017-08-23 Thread pe_lord
I'm on MapServer 7.0.3



--
View this message in context: 
http://osgeo-org.1560.x6.nabble.com/Multi-template-tp5317599p5332325.html
Sent from the Mapserver - User mailing list archive at Nabble.com.
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] Multi template

2017-08-23 Thread pe_lord
I understand but I cannot get the same behavior.

Here some mapfile sample:


 
OUTPUTFORMAT
  NAME 'html'
  DRIVER 'TEMPLATE'
  MIMETYPE 'text/html'
  FORMATOPTION "FILE=../templates/html.tmpl"   
  FORMATOPTION 'ATTACHMENT=info.html'
END

LAYER
NAME A
...
TEMPLATE 'another_template_html.html'
...
END

LAYER 
NAME B
...
TEMPLATE 'void' # redirect to template-driven output filtered by the
resultset tag [resultset layer="B"]
...
END



At this time, with this configuration, I cannot alternate between the 2
methods. I get a correct template from layer B but nothing from LAYER A...


Is it correct? Something wrong?









--
View this message in context: 
http://osgeo-org.1560.x6.nabble.com/Multi-template-tp5317599p5332287.html
Sent from the Mapserver - User mailing list archive at Nabble.com.
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] Multi template

2017-08-23 Thread pe_lord
One more question. 

Can template-output-driven be able to live at the same time as other
standard templates? Until now, it seems to me that supplant the behavior of
the other.




--
View this message in context: 
http://osgeo-org.1560.x6.nabble.com/Multi-template-tp5317599p5332275.html
Sent from the Mapserver - User mailing list archive at Nabble.com.
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] Multi template

2017-06-13 Thread pe_lord
This is working properly with your proposal.





--
View this message in context: 
http://osgeo-org.1560.x6.nabble.com/Multi-template-tp5317599p5324075.html
Sent from the Mapserver - User mailing list archive at Nabble.com.
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] Class maxscaledenom performance

2017-06-02 Thread pe_lord
It is precisely what I expect. 

The solution is to use scaletoken.

As proposed on  Github RFC86
  , I think it should be
documented into the layer description section:
http://www.mapserver.org/mapfile/layer.html

Pierre



--
View this message in context: 
http://osgeo-org.1560.x6.nabble.com/Class-maxscaledenom-performance-tp5322521p5322827.html
Sent from the Mapserver - User mailing list archive at Nabble.com.
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] Class maxscaledenom performance

2017-06-01 Thread pe_lord
I've verified if the issue was not linked to WMS. shp2img succeed to produce
the png. But it's quite long.

I have tried at 
*1:102 000 *
PGIS Query = 4 sec
Nb of recors = 2859 records
Mapserver render by WMS = 2.5 sec
Mapserver render by shp2img =  shp2img total time: 3.677s

select
"classitem_field",encode(ST_AsBinary(ST_Force2D("the_geom"),'NDR'),'hex') as
geom,"ogc_fid" from ori_pee 
where the_geom && ST_GeomFromText('POLYGON((-8871026
6114309.70958512,-8871026 6140241.29041488,-8834701
6140241.29041488,-8834701 6114309.70958512,-8871026
6114309.70958512))',3857)


*1:1 002 000*
PGIS Query = 26 minutes
Nb of records = 242832 records
Mapserver render by WMS = "internal server error" = timout
Mapserver render by shp2img =  shp2img total time: 156.299s

select
"classitem_field",encode(ST_AsBinary(ST_Force2D("the_geom"),'NDR'),'hex') as
geom,"ogc_fid" from ori_pee 
where the_geom && ST_GeomFromText('POLYGON((-9031284
504.71459227,-9031284 6254645.28540772,-8674443
6254645.28540772,-8674443 504.71459227,-9031284
504.71459227))',3857)

Here my validations
1-My layer have EXTENT
2-Mapserver do not reproject data
3-My layer has no label
4-Myconnection on postgis "DEFER"
5-My table have no OIDS
6-My table have GIST index on the_geom field
7-My table have a btree index on classitem field.
8-No warning in my GetCapabilities


I have tried loading a new table with OIDS set to TRUE (on table, not on
database)  and it's seem to be the same behavior? Do I really need to modify
postgresql.conf?



When I read the query called from mapserver, I think there is a way to
improve performance on maxscaledenom. Do you think there is a way for
mapserver to know which class to render at current scale (based on bbox )
and filter on them ... 

the query might look like this:
select
"classitem_field",encode(ST_AsBinary(ST_Force2D("the_geom"),'NDR'),'hex') as
geom,"ogc_fid" from ori_pee 
where the_geom && ST_GeomFromText('POLYGON((-9031284
504.71459227,-9031284 6254645.28540772,-8674443
6254645.28540772,-8674443 504.71459227,-9031284
504.71459227))',3857) and classitem_field = 'BBOX'

I think I will work on union layers :) .





--
View this message in context: 
http://osgeo-org.1560.x6.nabble.com/Class-maxscaledenom-performance-tp5322521p5322693.html
Sent from the Mapserver - User mailing list archive at Nabble.com.
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

[mapserver-users] Class maxscaledenom performance

2017-05-31 Thread pe_lord
I have a large dataset (7 500 000 polygons) published in a WMS service stored
in a PostGIS table (spatial index and attribute index on classitem field). I
render this layer between 1 and 100 001. I'm trying to manage my scale by
class asMapfile maxscaledenom
   to show
between 1: 15 000 000 and 1:100 001 the footprint of data (classitem='BBOX')
and the data between 1:100 000 and 1:1 

Everything working properly. Except for performance. I have tested with a
DEBUG 5 to know which element has been evaluated and every element in map
has been "checked". Causing this lack of performance.

I have also tried union layers but I find it too much time expensive to
maintain over a large number of layers.

Any hints to solve this problem?

Pierre









--
View this message in context: 
http://osgeo-org.1560.x6.nabble.com/Class-maxscaledenom-performance-tp5322521.html
Sent from the Mapserver - User mailing list archive at Nabble.com.
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] Multi template

2017-05-11 Thread pe_lord
But how to control the layer to use. 
In the case where my templates varies for each layer. Do I have to call an
new name at each call like this?

LAYER1  call looks like  : ...&INFO_FORMAT=application/json1 
LAYER2  call looks like  : ...&INFO_FORMAT=application/json2


OUTPUTFORMAT
  NAME 'json1'
  DRIVER TEMPLATE
  MIMETYPE 'application/json1; subtype=geojson'
  TEMPLATE 'templ1.js'
END

OUTPUTFORMAT
  NAME 'json2'
  DRIVER TEMPLATE
  MIMETYPE 'application/json2; subtype=geojson'
  TEMPLATE 'templ2.js'
END
 
I don't understant how to control the template calling and redirection to
the right template.




--
View this message in context: 
http://osgeo-org.1560.x6.nabble.com/Multi-template-tp5317599p5320221.html
Sent from the Mapserver - User mailing list archive at Nabble.com.
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] Multi template

2017-05-01 Thread pe_lord
I'm trying to setup these "DRIVER 'TEMPLATE'"
Few more questions!

1- What is the goal/difference of   
FORMATOPTION "FILE="
vs 
FORMATOPTION 'ATTACHMENT=...' ?

2- How to not all redirect my query on the same template (json or html).
I've tried for an other layer, my Driver template is used instead of the one
call into the layer section?




--
View this message in context: 
http://osgeo-org.1560.x6.nabble.com/Multi-template-tp5317599p5318988.html
Sent from the Mapserver - User mailing list archive at Nabble.com.
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] Multi template

2017-04-27 Thread pe_lord
Any another hint to maintain 2 template on same layer?



--
View this message in context: 
http://osgeo-org.1560.x6.nabble.com/Multi-template-tp5317599p5318595.html
Sent from the Mapserver - User mailing list archive at Nabble.com.
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] Multi template

2017-04-18 Thread pe_lord
Here the kind of html template i would like to both call in html and json

I know that i would need to simplify the data in json but it's simply an
example:
GetInfo HTML with joins

  




--
View this message in context: 
http://osgeo-org.1560.x6.nabble.com/Multi-template-tp5317599p5317677.html
Sent from the Mapserver - User mailing list archive at Nabble.com.
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] Multi template

2017-04-18 Thread pe_lord
But more specificly, two template on the same layer managing [join], one in
html, the other  in json or whatever...

I do not understant how to configure it or which call to make to retrieve
the right template...

INFO_FORMAT=text/html
 VS 
Queryformat = application/json



--
View this message in context: 
http://osgeo-org.1560.x6.nabble.com/Multi-template-tp5317599p5317655.html
Sent from the Mapserver - User mailing list archive at Nabble.com.
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

[mapserver-users] Multi template

2017-04-18 Thread pe_lord
I would like to know if Mapserver is able to maintain 2 template (or more) as
the same time.I want to maintain a HTML and a JSON template at the same
time, depending my call's parameters on my WMS getfeatureinfo.



--
View this message in context: 
http://osgeo-org.1560.x6.nabble.com/Multi-template-tp5317599.html
Sent from the Mapserver - User mailing list archive at Nabble.com.___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] Mapserver 7.0.4 Join 1:M ouput in GML

2017-04-13 Thread pe_lord
I did'nt succed to overide the gml native template from Mapserver.

Despite, I succeded in combining my join into a GEOJSON.
The real problem to increment [shpxy] with correct option to format
coordinates correctly. With my tries, i've seen that the trimlast option do
not work properly.

Here how look my templates

Main template 

// mapserver template
{
   "type":"FeatureCollection",
   "crs":{
  "type":"name",
  "properties":{
 "name":"urn:ogc:def:crs:EPSG::3857"
  }
   },

   "features":[
  {
 "type":"Feature",
 "properties":{
 "ID":"[ID]",
 [join_NAMEOFTHEJOIN]
 "Total":"[total]"# NEED to add something 
after the
1:M Join to manage my last , from my join content. 
 },
 "geometry":{
"type":"Polygon",
"coordinates":[
[shpext
format="[[$minx,$miny],[$maxx,$miny],[$maxx,$maxy],[$minx,$maxy],[$minx,$miny]]"]
]
 }
  }

   ]
}

=
1:M template join
=
//Mapserver Template

   
   
"field1_[NAMEOFTHEJOIN_FIELD1]":"[NAMEOFTHEJOIN_FIELD1]",  # I ADD
NAMEOFTHEJOIN_FIELD1] after field1 or field2 because JSON dont manage
identical keys.
   
"field2_[NAMEOFTHEJOIN_FIELD1]":"[NAMEOFTHEJOIN_FIELD1]",


   








--
View this message in context: 
http://osgeo-org.1560.x6.nabble.com/Mapserver-7-0-4-Join-1-M-ouput-in-GML-tp5316702p5317266.html
Sent from the Mapserver - User mailing list archive at Nabble.com.
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

[mapserver-users] Mapserver 7.0.4 Join 1:M ouput in GML

2017-04-10 Thread pe_lord
I would like to know if it is possible to ouput a 1:M join  -- join doc --
into a GML as suggested into
this page:  Template output
  

At this moment, I succeed with HTML template. Here one of my HTML template
retrieving content from many pg tables.
Example 1

  
Example 2

  

This question is linked ton an integration to Openlayers4 (  URL

 
)





--
View this message in context: 
http://osgeo-org.1560.x6.nabble.com/Mapserver-7-0-4-Join-1-M-ouput-in-GML-tp5316702.html
Sent from the Mapserver - User mailing list archive at Nabble.com.
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] Mapserver 7.0.2

2017-03-22 Thread pe_lord
Thanks a lot for your quick reply. 

For sure, the mapfile snippets in the documentation, it's really helpful. 
For the arrows, it's would be a nice enhancement!

Pierre



--
View this message in context: 
http://osgeo-org.1560.x6.nabble.com/Mapserver-7-0-2-Arrows-on-leader-tp5313718p5313763.html
Sent from the Mapserver - User mailing list archive at Nabble.com.
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

[mapserver-users] Mapserver 7.0.2

2017-03-22 Thread pe_lord
There is a way to add arrows at the end of a label leader.

At this time, my leaders are working properly ( Leader
  ). At the moment I try
to add another style by geotransform as explained here ( Geotransform
  )

Here my result
 

Now a part of my mapfile:

   LEADER
  GRIDSTEP 10 # number of pixels between positions that are tested
  MAXDISTANCE 100 # distance in pixels that leader text can be drawn

  STYLE
GEOMTRANSFORM "start"
SYMBOL "circle"
COLOR 255 0 0
SIZE 20
  END # STYLE
  STYLE
COLOR 0 0 0
WIDTH 4
  END # STYLE
  STYLE
GEOMTRANSFORM "end"
SYMBOL "circle"
COLOR 0 255 0
SIZE 20
  END # STYLE

END




--
View this message in context: 
http://osgeo-org.1560.x6.nabble.com/Mapserver-7-0-2-tp5313718.html
Sent from the Mapserver - User mailing list archive at Nabble.com.
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] RE Union Layer

2016-06-29 Thread pe_lord
Thanks, it's working perfectly!




--
View this message in context: 
http://osgeo-org.1560.x6.nabble.com/Union-Layer-tp5273957p5273966.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] Union Layer

2016-06-29 Thread pe_lord
I'm using Mapserver 6.4.2 on ubuntu server

I make an union layer.
The source layer share the same attributes and are based on 2 postgis
connection.

Here's my problem, or the expected behavior I expect from this feature.

I'm setting my union layer STATUS ON
I set source(s) layer STATUS OFF

I'm expecting the source(s) layer not be shown in the GetCapabilities,
however, the source(s) layer are shown? 

Is it normal? I can post my mapfile if it is a real issue.

Is it similar on Mapserver 7?




--
View this message in context: 
http://osgeo-org.1560.x6.nabble.com/Union-Layer-tp5273957.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] Mapserver JOIN to html template

2016-03-14 Thread pe_lord
Finally, 

I've moved from 6.2.1 to 6.4.2 and the issue is solved.





--
View this message in context: 
http://osgeo-org.1560.x6.nabble.com/Mapserver-JOIN-to-html-template-tp5255688p5256224.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] Mapserver JOIN to html template

2016-03-14 Thread pe_lord
1- Concerning view, at this time, I don't want to plan to make view because,
if I create view, I will get redundant geometries, resulting varying numbers
of geometries between 1 an M possiblities... And My example is based on only
1 table. I plan to make 1:M relationships with 5-6 others tables. If I'm
wrong, tell my!

2- About OIDs, every table has OIDs. I've loaded my datasets with ogr2ogr
from esri filegdb. 

3- Concerning others manipulation. I didn't try at this time,  I will try it
soon. Before, I will test 2 things:
3A- Log SQL query from PG to see if there is not a baq query sent by
Mpaserver to PG.
3B- Update Mapserver to 7. 




--
View this message in context: 
http://osgeo-org.1560.x6.nabble.com/Mapserver-JOIN-to-html-template-tp5255688p5256205.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