Hi, I try this command but it's doesn't work :
ogrinfo -al "MSSQL:server=.\MSSQLSERVER2008;driver=FreeTDS;database=EXAMPLE;trusted_connection=yes" I'm not sure for values in server and driver. server=.\MSSQLSERVER2008 or server=XX.XX.XX.XX driver=FreeTDS or driver=[value from freetds.conf] scott ----- Mail Original ----- De: "Tamas Szekeres" <[email protected]> À: [email protected] Cc: "Eduardo Kanegae" <[email protected]>, "MapServer Users" <[email protected]> Envoyé: Mercredi 14 Décembre 2011 12h37:51 GMT +01:00 Amsterdam / Berlin / Berne / Rome / Stockholm / Vienne Objet: Re: [mapserver-users] - SQL Server 2008 Hi, I think the OGR MSSQL Spatial driver would be a better choice than OGR ODBC to connect to MS SQL Server 2008. You may however specify the driver in the connection string explicitly. The default is driver={SQL Server} which may not be sufficient in non Windows environments. You may probably use: "MSSQL:driver=FreeTDS;..." You may also require to use the latest SVN (trunk or branch-1-8) in order to get it working. Best regards, Tamas 2011/12/13 < [email protected] > Hi, I install and configure FreeTDS and unixodbc to connect to SQL Server 2008. Everything is ok when I request database with tsql. But when I launch "ogrinfo ODBC:user/pwd@DSN", I have this error message : [unixodbc] [driver manager] data source name not found and no default driver specified What's the solution, environment variable ... ? Thanks ----- Mail Original ----- De: "Eduardo Kanegae" < [email protected] > À: "MapServer Users" < [email protected] > Envoyé: Samedi 26 Novembre 2011 15h49:27 GMT +01:00 Amsterdam / Berlin / Berne / Rome / Stockholm / Vienne Objet: Re: [mapserver-users] - SQL Server 2008 The mapfile won't change so much. Basically your layer will have layer name, type, connection type and then in connection param something like "MSSQL:dsn=MY_DSN;server=(local);database=DBNAME_HERE;tables=myscheme.mytable;uid=USER_HERE;pwd=PWD_HERE" mytable Check OGR docs for more info http://www.gdal.org/ogr/drv_mssqlspatial.html You might need freetds + unixodbc too http://www.sommarskog.se/mssqlperl/unix.html http://comments.gmane.org/gmane.comp.db.tds.freetds/13292 In advance I can tell what I got: I gave up using default geometry/spatial types/functions from SQL 2008 - to slow, no official docs is available. To speed it up, I installed MsSqlSpatial lib (originally developed for SQL 2005 but also works for 2008) on SQL 2008 database + ODBC OGR driver on MapServer. And then spatial SQL speed gone 10-15 times over standard ms sql 2008 types Eduardo Patto Kanegae http://www.webmapit.com | @webmapit 2011/11/26 < [email protected] > > > Ok but I try to use it on Linux. Do you have some examples of mapfile to > specify a sql 2008 connection ? > > ----- Mail Original ----- > De: "Eduardo Kanegae" < [email protected] > > À: "MapServer Users" < [email protected] > > Envoyé: Samedi 26 Novembre 2011 00h00:11 GMT +01:00 Amsterdam / Berlin / > Berne / Rome / Stockholm / Vienne > Objet: Re: [mapserver-users] - SQL Server 2008 > > I'm sure about 2008 but 2000/2005 you can connect using FreeTDS client > libs - and probably an ODBC connection. > > I also plan to publish more experiments using 2008/2005 > http://blog.webmapit.com/2011/11/ms-sql-2008-spatial-experiments.html > > regards > > Eduardo Patto Kanegae > http://www.webmapit.com | @webmapit > > > 2011/11/25 < [email protected] > > > > > Hi, > > > > I would like to create a mapfile with SQL Server 2008 connection but i > > don't know how to configure it. With Windows, the driver is mssql2008.dll > > but my server run on Linux. How to do it ? > > When MapServer is running with fcgid mode, what's the best configuration ? > > Is it possible to have some examples of fcgid.conf ? > > > > Thanks > > _______________________________________________ > > mapserver-users mailing list > > [email protected] > > http://lists.osgeo.org/mailman/listinfo/mapserver-users > _______________________________________________ > mapserver-users mailing list > [email protected] > http://lists.osgeo.org/mailman/listinfo/mapserver-users _______________________________________________ mapserver-users mailing list [email protected] http://lists.osgeo.org/mailman/listinfo/mapserver-users _______________________________________________ mapserver-users mailing list [email protected] http://lists.osgeo.org/mailman/listinfo/mapserver-users _______________________________________________ mapserver-users mailing list [email protected] http://lists.osgeo.org/mailman/listinfo/mapserver-users
