We have 5 "Master" shapefiles(A, B, C, D & E). Each will have different table structure. We have 100's of shapefiles which has features which has to go to A,B, C, D & E.

We have a column in all those 100's of shapefiles, like Column Name: Master & it's values are A,B,C,D,E.

Is it possible to run a query using ogr2ogr and filter out all the features with values "A" and append them to "Master table A" ?


It is possible to add a sql-statement as a parameter

ogr2ogr -append outfile.shp infile.shp-dialect sqlite -sql "SELECT * FROM shapefile WHERE column = 'A'"

Your Answer

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

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