Is there anyway I can download shapefile from GeoServer at the same time limit which columns will be downloaded? I know that GeoServer can serve different WFS format and this includes .SHP files. My problem is that some columns must not be made available for download. Is there anyway to limit the columns for download?
Currently I am thinking of writing a server-side script that will execute:
ogr2ogr -f "ESRI Shapefile" download.shp -sql "SELECT allowed_column1, allowed_column2 FROM tablename" PG:"host=host user=user dbname=databasename password=password"
but I am trying to use what GeoServer already have as much as possible.
Thanks a lot!