UCL-ShippingGroup / pyrate

Python AIS Tools Environment
MIT License
25 stars 10 forks source link

Check that postgis extensions are installed - before running scripts #27

Open ejokeeffe opened 8 years ago

ejokeeffe commented 8 years ago

Or at least only install the postgis dependent tables if they're there.

I think it's just a matter of running "SELECT name, default_version,installed_version FROM pg_available_extensions WHERE name LIKE 'postgis%' or name LIKE 'address%';"

If the result is greater than 0, then postgis is installed.