Vishful thinking…

A possible solution to getting your Geodatabase under source control

Posted in ArcGIS, ESRI by viswaug on January 21, 2009

A lot has already been said on the importance of getting your database under source control. If you haven’t given thought to including the database into your SVN, now is a good time to start and these tools can help. Various command line tools currently exist to script out the schema and optionally even the data to SQL script files on disk that can be checked into the SVN along with your source code. SQL Compare from redgate has the most complete solution with some features to die for. It will let you diff your current database with a SQL script that was generated earlier… yeah that’s nice. But it is gonna cost but well worth the money in my opinion. If you don’t want to dish out the $$$ for SQL Compare then the “Database Publishing Wizard” on CodePlex can step in to help your cause. It even has a command line version so that it can be easily incorporated into your automated build process.

Well, why did I say all that? I had been thinking about how I could get my Geodatabase under source control. Well, for starters we can export the Geodatabase to the XML Workspace Document format manually from ArcCatalog and check-in the XML document into source control.

export_xml_workspace

export_x603734039

If you are interested in automating that process of exporting your Geodatabase to XML then the ‘IGdbXmlExport‘ interface is your buddy and can be used to export and import schema and data. A NAnt or MSBuild task can written to include it as a part of your automated build process.

Filter Encoding Standard 1.1 and the curious case of the missing ‘IN’ operator

Posted in ArcGIS, ESRI, GIS by viswaug on January 20, 2009

I was working with the Filter Encoding (FE) 1.1 standard recently and was surprised to find that it did not have an equivalent to the ‘IN’ operator. The FE 1.1 standard currently supports the following comparison operator.

  •  
    • PropertyIsEqualTo
    • PropertyIsNotEqualTo
    • PropertyIsLessThan
    • PropertyIsGreaterThan
    • PropertyIsLessThanOrEqualTo
    • PropertyIsGreaterThanOrEqualTo
    • PropertyIsLike
    • PropertyIsBetween
    • PropertyIsNull

That was a big bummer for me since when I tried to use multiple “PropertyIsEqualTo” comparison operator coupled with the logical “OR” operator the performance was VERY bad. I am using ArcGIS server 9.3 like always.

The OGC support in ArcGIS Server is really great in case your are wondering. ArcGIS Server 9.3 supports the Filter Encoding 1.1, Styled Layer Descriptor 1.0 and other OGC standards as listed here http://www.esri.com/software/standards/standards_tables.html. Support for Styled Layer Descriptor 1.1 is not there yet but may happen in the future versions.

The FE 1.1 standard does include support for the ‘GmlObjectId’ object identifiers way of querying data. This can serve as the ‘IN’ operator if you are querying by the object identifiers. Unfortunately, I wasn’t. The Filter Encoding does include support for ‘Functions’ where custom filters can be supported by the GIS Server. And since, the ‘IN’ comparison operator is missing, it can be implemented as a custom ‘Function’ by GIS Servers to serve clients who desperately that functionality…