Take the 2-minute tour ×
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

using QGIS, i've loaded up some administrative boundary data of New Zealand. I wish to now import this vector data from QGIS into my Sql Server 2012.

Is there any way to do this with QGIS 1.8.0-Lisboa?

share|improve this question

1 Answer 1

up vote 2 down vote accepted

I don't know if you can do it directly with QGIS but Shape2SQL ( free standalone tool ) can do it for you.

enter image description here

You can also import shapefiles to SQL Server using ogr2ogr. A sample command is:

ogr2ogr -overwrite -f MSSQLSpatial "MSSQL:server=.\MSSQLSERVER2008;database=spatial;trusted_connection=yes" "your_shapefile.shp"

Source: http://gis.stackexchange.com/a/29849/292

share|improve this answer
    
I've tried that (so many times) but it failed (with the administrative dataset from that link). –  Pure.Krome Sep 25 '12 at 7:49
1  
Which error did you get? –  R.K. Sep 25 '12 at 7:52
    
exe crashed. yep -> stack trace, dump, etc. I might try the ogr2ogr method. Where can i find it? (i've installed QGIS, remember). Assumption : it's included with the stock standard QGIS 1.8 windows install. –  Pure.Krome Sep 25 '12 at 9:10
    
You can try adding the GDAL directory to your Windows path. Once you've done that, you can invoke the command on the command prompt (cmd.exe) –  R.K. Sep 25 '12 at 9:14

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.