Currently I have a PostGIS database that is taking in shapefiles. However, these shapefiles are converted into tables when they are imported into the database. Each shapefile deals with a farm name, field name, and year. Is there a way that I can add these attributes to be associated with the table so I could query my table by farm name and field name?

  • Yes, append each shape file to an existing table (there is an -a switch in shp2pgsql) and the year, name and field will just be attributes of this table, rather than creating a new table each time. – John Powell Oct 30 '18 at 7:25
  • Would you be able to refer me to any documentation that I could read about for this?? – Ammar Hoque Oct 31 '18 at 18:57
  • Yes, actually, I asked this question which more or less explains how to do it and an answer using ogr2ogr also. – John Powell Oct 31 '18 at 19:21

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.