[mapserver-users] non spatial MSSQL data in a Layer JOIN

Daniel Morissette dmorissette at mapgears.com
Thu Jan 9 11:27:14 PST 2014


On 14-01-09 1:36 PM, KenHeer1 wrote:
> So digging a little deeper the problem is in the data somewhere. I have the
> same problem when trying to do the same join within ArcMap. What is weird is
> that with three data sources all with the say key values I can join the
> shapefile to table 2 and I can join table 1 to table 2, but I can't join the
> shapefile to table 1. There is something in the shapefile that table 1
> doesn't like.
>
> Either way it looks as though my initial question was answered; you can join
> a shapefile to a datasource in MSSQL that does not have any spatial data in
> it using OGR.
>


Glad to hear that the joins to MSSQL are working fine, apart from this 
issue with table1.

I am not familiar with the MSSQL driver specifics, so I cannot provide 
much more advice, other than suggesting that the issue is clearly not in 
MapServer, but lies somewhere between OGR and MSSQL. You could perhaps 
raise the issue on the GDAL list and see if someone more knowledgeable 
about the MSSQL driver can help.

You may also get some additional hints about the issue if you "set 
CPL_DEBUG=ON" in your DOS window before running ogrinfo with the SQL 
statement that fails. If you're lucky this may output some useful hints 
about the source of the issue with table1.

More info about CPL_DEBUG here:
http://trac.osgeo.org/gdal/wiki/ConfigOptions#CPL_DEBUG


-- 
Daniel Morissette
http://www.mapgears.com/
Provider of Professional MapServer Support since 2000



More information about the mapserver-users mailing list