Using SQLAlchemy with Spatial Databases
WHAT OUR HAPPY PROGRAMMER SAY
GeoAlchemy 2 provides extensions to SQLAlchemy for working with spatial databases.
GeoAlchemy 2 focuses on PostGIS. PostGIS 1.5 and PostGIS 2 are supported.
SpatiaLite is also supported, but using GeoAlchemy 2 with SpatiaLite requires some specific configuration on the application side. GeoAlchemy 2 works with SpatiaLite 4.3.0 and higher.
GeoAlchemy 2 aims to be simpler than its predecessor, GeoAlchemy. Simpler to use, and simpler to maintain.
- Is the Sutherland Shire Sydney’s new hotspot to live in Sydney?This article will look into about how the Sutherland Shire is becoming a popular spot to live in Sydney. […]
- Which Cars Are Best for Cheap InsuranceIf you are investing in a car for practical reasons of being able to conveniently transport you and your […]
- What are the advantages of using a creative agencyThe advantages of using a creative agency. When it comes to marketing and advertising, creativity is key. And that’s […]
- Let us know about wedding rings in ThailandThailand is the country that fashionably represented culture. Particularly weddings in Thailand are more adorable. As other ornaments are […]
- 10 Mistakes that can ruin your Commercial Interiors DesignCommercial interior designers plan and design the interiors of offices, laboratories, retail spaces, and other places of business. The […]
What’s New in GeoAlchemy
- GeoAlchemy 2 supports PostGIS’
geometrytype, as well as the
- The first series had its own namespace for spatial functions. With GeoAlchemy 2, spatial functions are called like any other SQLAlchemy function, using
func, which is SQLAlchemy’s standard way of calling SQL functions.
- GeoAlchemy 2 works with SQLAlchemy’s ORM, as well as with SQLAlchemy’s SQL Expression Language (a.k.a the SQLAlchemy Core). (This is thanks to SQLAlchemy’s new type-level comparator system.)
- GeoAlchemy 2 supports reflection of geometry and geography columns.
- GeoAlchemy 2 adds
from_shapefunctions for a better integration with Shapely.
See the Migrate to GeoAlchemy 2 page for details on how to migrate a GeoAlchemy application to GeoAlchemy 2.
GeoAlchemy 2 requires SQLAlchemy 0.8. GeoAlchemy 2 does not work with SQLAlchemy 0.7 and lower.