Current PostGIS Blog Articles
• Morton key function for PostgreSQL/PostGIS
• Generating a Grid (fishnet) of points or polygons for PostGIS
• ST_Parallel for PostGIS
• R based Delaunay Triangulation Function for PostGIS using the deldir package
• COGO: Converting Decimal Degrees to Degrees Minutes and Seconds - and back again (PostGIS)
• COGO: Finding centre and radius of a curve defined by three points (PostGIS)
• Gridding a geometry object (PostGIS)
• FOSSLIC - PostGIS presentations
• Vectorization: Exploding a linestring or polygon into individual vectors in PostGIS
• How to apply spatial constraints to PostGIS tables
• Loading and Processing GPX 1.1 files using PostgreSQL XML
• Converting Oracle Optimized Rectangles to PostGIS
• Building polygons from overlapping linestrings requiring intersection
• Loading Point Data from a CSV File in PostGIS
• DMS2DD for PostGIS
• Implementing Oracle's GetVertices function in PostGIS - ST_DumpPoints
• Filtering Rings in Polygon (PostGIS)
I recently wrote an article on the use of External File with Oracle tables to load point data into Oracle.
I thought I would have a look on how to do this in PostGIS.
A bit of research came up with the PostgreSQL COPY SQL command.
There appears to be no equivalent to Oracle’s Organisation External for a table. In PostgreSQL you simply create your table and then insert data into it from an external file. You don’t seem to need to concern yourself with special permissions to do this: just get in and do it.
Which is what we will do right now.
Now, that was pretty simple. There are certainly advantages to the PostgreSQL way of loading CSV organised data. I am not sure about the lack of security with regards to external file access though. One thing in Oracle’s favour is that externally organised tables can be used without having to load the data which can be useful in many situations.
Anyway, I hope this article is of use to someone.