Skip to content

Instantly share code, notes, and snippets.

@tomciopp
Created August 31, 2012 00:58
Show Gist options
  • Save tomciopp/3546980 to your computer and use it in GitHub Desktop.
Save tomciopp/3546980 to your computer and use it in GitHub Desktop.
Setting up Postgis with Postgresql
require 'rails/all'
require 'squeel'
require 'active_record/connection_adapters/postgis_adapter/railtie'
development:
adapter: postgis
schema_search_path: "public,postgis"
su_username: postgresql
postgis_extension: true
encoding: unicode
database: myapp_development
pool: 5
username: myapp
password:
PG::Error: ERROR: syntax error at or near "EXTENSION"
LINE 1: CREATE EXTENSION postgis SCHEMA postgis
^
: CREATE EXTENSION postgis SCHEMA postgis
gem 'pg'
gem 'jquery-rails'
# Gems for geospatial data
gem 'activerecord-postgis-adapter'
gem 'rgeo-shapefile'
gem 'squeel'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment