Created
January 6, 2025 08:30
-
-
Save filipkral/77b5d2e9cd732998f644614fb8cd8ba5 to your computer and use it in GitHub Desktop.
Import Polygon ESRI Shapefile to PostgreSQL database using ogr2ogr
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ogr2ogr -f "PostgreSQL" -a_srs "EPSG:4326" -lco SCHEMA=<schema> PG:"host=<ip or hostname> user=<user> password=<password> dbname=<dbname>" -nlt MULTIPOLYGON -nln <table_name> <shapefile_name>.shp |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment