2

I need to upload some very large tables (over 10Gb) into Postgis so I actually found this link What is the best hack for importing large datasets into PostGIS?

The DB manager is far too slow and only uploaded 10% of the data despite saying the import was successful.

Problem is, this is my 1st day ever using Postgis and I have no idea where to run those commands, so I can't really understand the answers in the above link. Is it in the QGIS interface? pgadmin? some other interface?

I have all the latest versions of the softwares and Windows 8

I found a file called shp2pgsql but after clicking it, it instantly closes down

7
  • What are the tables that you want to upload? Are they simple attribute tables? Are they spatial data? What format are they in? Based on your comment, it looks like they might be shapefiles. Where is Postgres installed? Have you read any of the documentation for Postgres, since you are new to using it? Here is a link to the documentation. The more detail you can provide about what you are trying to do, the better your chances of obtaining a solution. Commented May 25, 2016 at 16:52
  • 1
    shp2pgsql is a command-line program. You need to open a Windows command prompt and type "shp2pgsql". If the PATH is correctly set up, it will print out some instructions. If not, you'll get an error. There's some talk about setting the PATH on Win 8 here. The path should point to the folder where you found the shp2pgsql file.
    – Rob Skelly
    Commented May 25, 2016 at 17:22
  • @GetSpatial they are point vector files with >14Gb dbf files in size. I've read the documentation but I didn't find the right thing. I want to upload these files without spending days, not sure what other details can I provide
    – Luffydude
    Commented May 25, 2016 at 20:01
  • @RobSkelly thank you, will look into that tomorrow and see if it works for me
    – Luffydude
    Commented May 25, 2016 at 20:02
  • @RobSkelly it worked. thanks! Also this trick will help some people, after opening the prompt, it's very useful to just type cd and then drag the folder into the prompt to get the correct path
    – Luffydude
    Commented May 26, 2016 at 8:25

1 Answer 1

1

shp2pgsql is a command-line program. You need to open a Windows command prompt and type "shp2pgsql". If the PATH is correctly set up, it will print out some instructions. If not, you'll get an error. There's some talk about setting the PATH on Win 8 here. The path should point to the folder where you found the shp2pgsql file.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.