[mapserver-users] mapserver vrt et mapfile : file not found or unsupported format
Hello, I try to create a mapfile with data in a csv file. I have failed to draw the layer with a Virtual Format and a OGR connectiontype directly in the mapfile. So I have decided to store the connection in a different file like here http://mapserver.org/input/vector/VirtualSpatialData.html#steps-for-display mapfile : LAYER CONNECTION "basol_auv.ovf" CONNECTIONTYPE OGR DATA "test" METADATA "wms-srs" "2154" "wms-title" "test" END NAME "pollution" TYPE POINT CLASS NAME "pollution" STYLE SYMBOL "pollution" SIZE 10 END #fin style END #-fin class END #-fin layer sols pollués basol_auv.ovf : C:\OSGeo4W\Apache\htdocs\data\test.csv test wkbPoint I have a new error message : msDrawMap(): Image handling error. Failed to draw layer named 'pollution'. msOGRFileOpen(): OGR error. Open failed for OGR connection in layer `pollution'. File not found or unsupported format. I dont'know what to do to verify if it is a matter of path or format. ogrinfo command gives the correct answer : ogrinfo basol_auv.ovf test -- View this message in context: http://osgeo-org.1560.x6.nabble.com/mapserver-vrt-et-mapfile-file-not-found-or-unsupported-format-tp5278305.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] unable to build spatial index when running shptree from ArcGIS model
Very cool stuff Matt and Mark!!! -jeff -- Jeff McKenna MapServer Consulting and Training Services http://www.gatewaygeomatics.com/ On 2016-07-26 7:03 PM, Matt Brown wrote: Mark, I just ran a test and was able to execute shptree through a script in arcmap. ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] unable to build spatial index when running shptree from ArcGIS model
Mark, I just ran a test and was able to execute shptree through a script in arcmap. this is the script I ran: import subprocess subprocess.Popen(['D:/GIS/testqix.bat']) which opened this batch file: call d:\ms4w\setenv.bat shptree d:\gis\nm.shp I was also able to just point directly to the batch file when I defined the script which also works for me. Hope this helps, Matt Matt Brown Technology Systems Director Alabama 811 mbr...@al811.com On Tue, Jul 26, 2016 at 2:25 PM, Mark Volz wrote: > Hello, > > > > I am in the process of trying to automate the update process for my > mapserver GIS data. As part of the process I am using shptree to build > spatial indexes. I created a batch file (.bat) that will set all the paths > and environment variables then run shptree on my new GIS layers. This > batch file works fine on its own. My next that I would like to do is call > this batch file from ArcGIS so that I can run the “update shptree” script > immediately after I update my GIS data. Although I can use python to open > up my “update shptree” batch file, it appears that shptree does not get > run at all. > > > > Please let me know If anyone has had any success in using ArcGIS to run > shptree.exe. > > > > *Working Method* > > Window Explorer à UpdateShptree.bat: Works great > > *Not Working* > > ArcGIS Catalog / Model Builder àPython Script to run UpdateShptree.bat à > UpdateShptree.bat: does not work > > > > Scripts: > > > > Python file: > > # Import native arcgisscripting module > > import sys, string, os, arcgisscripting > > # Create the geoprocessor object > > gp = arcgisscripting.create() > > os.system('C:\\ GIS\\ PublishUpdates\\UpdateMooseQIX.bat') > > gp.SetParameterAsText(0,"True") > > > > Batch file: > > set > PATH=C:\ms4w\Apache\cgi-bin;C:\ms4w\tools\gdal-ogr;C:\ms4w\tools\mapserv;C:\ms4w\tools\shapelib;C:\ms4w\proj\bin;C:\ms4w\tools\shp2tile;C:\ms4w\tools\shpdiff;C:\ms4w\tools\avce00;C:\ms4w\tools\demtools;%PATH% > > set GDAL_DATA=C:\ms4w\gdaldata > > set GDAL_DRIVER_PATH=C:\ms4w\gdalplugins > > set PROJ_LIB=C:\ms4w\proj\nad > > cd C:\ GIS\ PublishUpdates\MOOSEStagingArea\ > > shptree ParcelsLyon.shp > > shptree Plats.shp > > shptree Lots.shp > > > > > > Sincerely, > > *Mark Volz, GISP* > > *Lyon County GIS Coordinator* > > ___ > 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] Create tile index for a directories with many layers of subfolders
Martin, You can simply specify a set of files separated by spaces. See gdal_file in the link: http://www.gdal.org/gdaltindex.html Example: gdaltindex output.shp /1.tif /2.tif /n.tif -- View this message in context: http://osgeo-org.1560.x6.nabble.com/Create-tile-index-for-a-directories-with-many-layers-of-subfolders-tp5278271p5278273.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] Create tile index for a directories with many layers of subfolders
Hi, I am trying to create tile index for a very big dataset of historic images. I used to be able to create tile index for a directory of images but this dataset has several layers of subfolders in it such as \NY\1968\LOC\1.tif and \NY\1972\UPA\2.tif. The goal is to create one tile index for the whole dataset without change the physical storage. And I am having difficulty using wildcards to make gdaltindex command working. Any suggestions or possible solutions? Is there a way for gdaltindex function works like gdalbuildvrt with a parameter(-input_file_list) using a file listing all the image paths? Thanks in advance, Martin ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
[mapserver-users] unable to build spatial index when running shptree from ArcGIS model
Hello, I am in the process of trying to automate the update process for my mapserver GIS data. As part of the process I am using shptree to build spatial indexes. I created a batch file (.bat) that will set all the paths and environment variables then run shptree on my new GIS layers. This batch file works fine on its own. My next that I would like to do is call this batch file from ArcGIS so that I can run the "update shptree" script immediately after I update my GIS data. Although I can use python to open up my "update shptree" batch file, it appears that shptree does not get run at all. Please let me know If anyone has had any success in using ArcGIS to run shptree.exe. Working Method Window Explorer --> UpdateShptree.bat: Works great Not Working ArcGIS Catalog / Model Builder -->Python Script to run UpdateShptree.bat --> UpdateShptree.bat: does not work Scripts: Python file: # Import native arcgisscripting module import sys, string, os, arcgisscripting # Create the geoprocessor object gp = arcgisscripting.create() os.system('C:\\ GIS\\ PublishUpdates\\UpdateMooseQIX.bat') gp.SetParameterAsText(0,"True") Batch file: set PATH=C:\ms4w\Apache\cgi-bin;C:\ms4w\tools\gdal-ogr;C:\ms4w\tools\mapserv;C:\ms4w\tools\shapelib;C:\ms4w\proj\bin;C:\ms4w\tools\shp2tile;C:\ms4w\tools\shpdiff;C:\ms4w\tools\avce00;C:\ms4w\tools\demtools;%PATH% set GDAL_DATA=C:\ms4w\gdaldata set GDAL_DRIVER_PATH=C:\ms4w\gdalplugins set PROJ_LIB=C:\ms4w\proj\nad cd C:\ GIS\ PublishUpdates\MOOSEStagingArea\ shptree ParcelsLyon.shp shptree Plats.shp shptree Lots.shp Sincerely, Mark Volz, GISP Lyon County GIS Coordinator ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] mapserver-cgi displays nothing
Also, I tested locally by modifying the value passed, starting with '&yuk=1' and then trying '&yuk=10' etc. It could be that your value of 500 just isn't in your data. -jeff -- Jeff McKenna MapServer Consulting and Training Services http://www.gatewaygeomatics.com/ On 2016-07-26 10:06 AM, Ahmet Temiz wrote: Thank you all, But the problem still exists. ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] mapserver-cgi displays nothing
Hello Ahmet, I just ran your test locally here (MapServer 7.0.1, MS4W 3.1.4), using your last validation example and expression on a raster layer, and I received a proper map image. It must be something with your data I think. Maybe try another local file (not in that same database?). My test was with a GeoTIFF file. -jeff -- Jeff McKenna MapServer Consulting and Training Services http://www.gatewaygeomatics.com/ On 2016-07-26 10:06 AM, Ahmet Temiz wrote: Thank you all, But the problem still exists. complete layer portion in the map : ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] mapserver-cgi displays nothing
Thank you all, But the problem still exists. complete layer portion in the map : LAYER NAME 'runtimeSubstitution' TYPE RASTER DUMP true METADATA "wms_title" "WMS Demo Server" "wms_onlineresource" " http://localhost/cgi-bin/mapserv?map=/var/www/trdem1.map&"; "wms_srs" "EPSG:3857" "WMS_ENABLE_REQUEST" "*" "wms_feature_info_mime_type" "text/html" "wms_format" "image/png" END PROCESSING "NODATA=0" PROCESSING "SCALE=AUTO" PROCESSING "CLOSE_CONNECTION=DEFER" EXTENT 2857613.741389 4274927.875099 4989786.191152 5176940.449967 DATA 'PG: dbname=tr22 host=localhost user=orkun password=22 port=5432 schema=public table=o_16_rdem3857 mode=2' STATUS ON OPACITY 50 VALIDATION 'yuk' '^[0-9]+$' END CLASS EXPRESSION ([pixel] >= %yuk% ) STYLE COLOR 255 0 0 END END #end class END # layer =trdem_4326 http://localhost/cgi-bin/mapserv?mode=map&map=/var/www/trdem1.map&layer=runtimeSubstitution&yuk=500 On Tue, Jul 26, 2016 at 3:35 PM, Rahkonen Jukka (MML) < jukka.rahko...@maanmittauslaitos.fi> wrote: > Hi > > Test systematically. If you test your validation with some service like > http://www.regexpal.com/ you will find that yuk=50 does not validate > because it has more than one number in the string. > Try to validate with ^[0-9]+$ > > And yes, variable must be enclosed between %%. That is well documented in > http://mapserver.org/cgi/runsub.html. > > -Jukka Rahkonen- > > > > Lähettäjä: mapserver-users > käyttäjän puolestaYves Jacolin > Lähetetty: 26. heinäkuuta 2016 10:17 > Vastaanottaja: mapserver-users@lists.osgeo.org > Aihe: Re: [mapserver-users] mapserver-cgi displays nothing > > On Tuesday, July 26, 2016 10:12:58 Ahmet Temiz wrote: > > Our mapserver-cgi displays nothing. > > > > > http://localhost/cgi-bin/mapserv?mode=map&map=/var/www/trdem1.map&layer=runt > > imeSubstitution&yuk=50 > > > > VALIDATION > > 'yuk' '^[0-9]$' > > END > > > > CLASS > > EXPRESSION ([pixel] >= 'yuk' ) > > STYLE COLOR 255 0 0 END > > END #end class > > > > What am I doing wrong? > > regards > Hello, > > You should probably use %: > >EXPRESSION ([pixel] >= '%yuk%' ) > > 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 -- Ahmet Temiz Jeoloji Müh. Afet ve Acil Durum Yönetimi Başkanlığı Bilgi İşlem Dairesi Başkanlığı-CBS Grubu Ahmet Temiz Geological Eng. Information Systems - GIS Group Disaster and Emergency Management of Presidency ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] mapserver-cgi displays nothing
Get rid of the quotes around %yuk% so that you're comparing number to number. --Steve From: mapserver-users [mapserver-users-boun...@lists.osgeo.org] on behalf of Ahmet Temiz [ahmettemi...@gmail.com] Sent: Tuesday, July 26, 2016 5:48 AM To: mapserver-users Subject: Re: [mapserver-users] mapserver-cgi displays nothing Thank you, I tried . But it did not work. I also checked the map without runtime substitution. as: CLASS EXPRESSION ([pixel] >= 100 ) STYLE COLOR 255 0 0 END END #end class it looks OK. On Tue, Jul 26, 2016 at 10:12 AM, Ahmet Temiz mailto:ahmettemi...@gmail.com>> wrote: Our mapserver-cgi displays nothing. http://localhost/cgi-bin/mapserv?mode=map&map=/var/www/trdem1.map&layer=runtimeSubstitution&yuk=50 VALIDATION 'yuk' '^[0-9]$' END CLASS EXPRESSION ([pixel] >= 'yuk' ) STYLE COLOR 255 0 0 END END #end class What am I doing wrong? regards -- Ahmet Temiz Jeoloji Müh. Afet ve Acil Durum Yönetimi Başkanlığı Bilgi İşlem Dairesi Başkanlığı-CBS Grubu Ahmet Temiz Geological Eng. Information Systems - GIS Group Disaster and Emergency Management of Presidency -- Ahmet Temiz Jeoloji Müh. Afet ve Acil Durum Yönetimi Başkanlığı Bilgi İşlem Dairesi Başkanlığı-CBS Grubu Ahmet Temiz Geological Eng. Information Systems - GIS Group Disaster and Emergency Management of Presidency ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] mapserver-cgi displays nothing
Hi Test systematically. If you test your validation with some service like http://www.regexpal.com/ you will find that yuk=50 does not validate because it has more than one number in the string. Try to validate with ^[0-9]+$ And yes, variable must be enclosed between %%. That is well documented in http://mapserver.org/cgi/runsub.html. -Jukka Rahkonen- Lähettäjä: mapserver-users käyttäjän puolestaYves Jacolin Lähetetty: 26. heinäkuuta 2016 10:17 Vastaanottaja: mapserver-users@lists.osgeo.org Aihe: Re: [mapserver-users] mapserver-cgi displays nothing On Tuesday, July 26, 2016 10:12:58 Ahmet Temiz wrote: > Our mapserver-cgi displays nothing. > > http://localhost/cgi-bin/mapserv?mode=map&map=/var/www/trdem1.map&layer=runt > imeSubstitution&yuk=50 > > VALIDATION > 'yuk' '^[0-9]$' > END > > CLASS > EXPRESSION ([pixel] >= 'yuk' ) > STYLE COLOR 255 0 0 END > END #end class > > What am I doing wrong? > regards Hello, You should probably use %: EXPRESSION ([pixel] >= '%yuk%' ) 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] GUI for map file creation/edit
Thanks for sharing. I have also added this to the wiki page of MapFile Editors: https://github.com/mapserver/mapserver/wiki/MapFile-Editors Note that anyone can edit that page, as it is a wiki page. (surprisingly I was asked to edit it myself). I want to stress again: the MapServer wiki can be edited by anyone. That is everyone. Everyone on this planet :) The wiki is there for anyone to create a page, add a link, and share their passion for MapServer. -jeff -- Jeff McKenna MapServer Consulting and Training Services http://www.gatewaygeomatics.com/ On 2016-07-26 1:45 AM, Ullas Dastakar wrote: Dear All We are developing a GUI for map file maker named as Crowmap. This is available in beta form under Github. This is a standalone application that can run in a browser. This application can be used to create/ edit map files. No map server is required for running this tool . Please try the tool and give your valuable feedbacks. Currently the tool is written for Mapserver 7.0.1 The github link is given below. https://github.com/Maptell/crowmap Looking forward to hear from you, ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] mapserver-cgi displays nothing
Thank you, I tried . But it did not work. I also checked the map without runtime substitution. as: CLASS EXPRESSION ([pixel] >= 100 ) STYLE COLOR 255 0 0 END END #end class it looks OK. On Tue, Jul 26, 2016 at 10:12 AM, Ahmet Temiz wrote: > Our mapserver-cgi displays nothing. > > > http://localhost/cgi-bin/mapserv?mode=map&map=/var/www/trdem1.map&layer=runtimeSubstitution&yuk=50 > > VALIDATION > 'yuk' '^[0-9]$' > END > > CLASS > EXPRESSION ([pixel] >= 'yuk' ) > STYLE COLOR 255 0 0 END > END #end class > > What am I doing wrong? > regards > > -- > Ahmet Temiz > Jeoloji Müh. > Afet ve Acil Durum Yönetimi Başkanlığı > Bilgi İşlem Dairesi Başkanlığı-CBS Grubu > > > > > Ahmet Temiz > Geological Eng. > Information Systems - GIS Group > Disaster and Emergency Management > of Presidency > -- Ahmet Temiz Jeoloji Müh. Afet ve Acil Durum Yönetimi Başkanlığı Bilgi İşlem Dairesi Başkanlığı-CBS Grubu Ahmet Temiz Geological Eng. Information Systems - GIS Group Disaster and Emergency Management of Presidency ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] mapserver-cgi displays nothing
On Tuesday, July 26, 2016 10:12:58 Ahmet Temiz wrote: > Our mapserver-cgi displays nothing. > > http://localhost/cgi-bin/mapserv?mode=map&map=/var/www/trdem1.map&layer=runt > imeSubstitution&yuk=50 > > VALIDATION > 'yuk' '^[0-9]$' > END > > CLASS > EXPRESSION ([pixel] >= 'yuk' ) > STYLE COLOR 255 0 0 END > END #end class > > What am I doing wrong? > regards Hello, You should probably use %: EXPRESSION ([pixel] >= '%yuk%' ) 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] mapserver-cgi displays nothing
Our mapserver-cgi displays nothing. http://localhost/cgi-bin/mapserv?mode=map&map=/var/www/trdem1.map&layer=runtimeSubstitution&yuk=50 VALIDATION 'yuk' '^[0-9]$' END CLASS EXPRESSION ([pixel] >= 'yuk' ) STYLE COLOR 255 0 0 END END #end class What am I doing wrong? regards -- Ahmet Temiz Jeoloji Müh. Afet ve Acil Durum Yönetimi Başkanlığı Bilgi İşlem Dairesi Başkanlığı-CBS Grubu Ahmet Temiz Geological Eng. Information Systems - GIS Group Disaster and Emergency Management of Presidency ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users