Opening File Based Geodatabases in QGIS 2.2

Mar 5, 2014 | ArcGIS Desktop, ESRI, Open Source GIS, QGIS

File based geodatabases….love them or hate them. I’ve done both. Back in 2009 I even did a two hour workshop on Switching to File Based Geodatabases and why this was the best thing ever.

A question came up on the QGIS users list and it led to a slight detour as the days usually go. What do you do if you get a file based geodatabase and you are using QGIS? At about 9.x everyone was usually screwed. Then ESRI relased their API and the good people at GDAL fixed it to where life was much easier. You could break out ogr and get to your data out.

I’ve been in the middle of writing the QGIS Part Deaux class. It’s going to be heavy editing/working with your data. With the emphasis on your data. It’s going to be the nice thing by the end of the three day class (Parts I, II, and III) is that you aren’t going to care what software you use – you are only going to care ultimately about your data and the tools you can use on it. The tool we will discuss will be QGIS in the class (obviously).

So what happens when you are sitting there and you get a file based geodatabase from someone. I’ve used linux and windows to pull data out into shapefiles but this example ran from the windows side of life and the OSGEO4W installer as described here. Being a complete slacker I didn’t try the stand alone installer but I did get anecdotal evidence it works also. Well – because of GDAL you can open a file based geodatabase as a directory once you get the gdal-filegdb library installed. You can open your data. I even edited the data (but that scared the crap out of me).

osgeofilebasedgdb

In all of that I did something completely out of the ordinary – or at least I thought it was. It actually is quite brilliant that QGIS can do this. I’ve talked about spatialite and with the OGC’s announcement of the geopackage I have a bit more hope with it as an alternative software. So after opening the file based geodatabase in QGIS I cracked open spatialite and made a new database (there are several ways to do it) and used the database manager to pull data out of the File based geodatabase and into spatialite.

screenshot_qgis

Why is that remotely brilliant? When I die I’m going to have the words descriptio put on my tombstone. For those who have dealt with moving data from a database into a shapefile that’s always how I describe the truncation that occurs. It is a pain if you are working with data and you move something into a shapefile and all the fields become truncated. Well with the database manager that comes with QGIS you can move it straight from the file based geodatabase into spatialite (or PostGIS). Yes this is awesome – BUT – you can’t go back to a file based geodatabase….BUT you can hand of the spatialite database to your ESRI users.

So a diversion out of my day. I learned something. Hopefully you did too….QGIS – it’s awesome. It’s OpenSource. (shameless plug WE TEACH CLASSES ABOUT IT!!)

 

You may also like

My So called Life as a Map Maker

My So called Life as a Map Maker

I can sum it up: It's not much of one. Way back in my younger days I was infatuated with ArcPlot (which was the plotting portion of ArcINFO). From there I moved to Arcview, ArcMap, and eventually here to QGIS. All of my work typically revolves around Data. I usually...

Tricks with an ESRI File Geodatabase

Tricks with an ESRI File Geodatabase

A few years back I jumped in way over my head with QGIS/Postgis. I had moved a process out of one software and into my favorite two (QGIS/PostGIS) and little did I know the final output had to be a ESRI File Geodatabase. So what did I do? I shamed them into using a...

Making the Invalid Valid

Making the Invalid Valid

I could argue I'm doing that on multiple levels these days. Except I want to talk Geometry, QGIS, and Forks in the Road. I haven't done just a "QGIS Tech Post" in a while. I talk about it and training and generalities but hardly dive into the specifics. So here is a...