Open options
Open options can be specified in command-line tools using the syntax -oo <NAME>=<VALUE> or by providing the appropriate arguments to GDALOpenEx() (C) or gdal.OpenEx (Python). The following open options are supported:
ENCODING=[<encoding_name>/""]: Override the encoding interpretation of the shapefile with any encoding supported by CPLRecode or to "" to avoid any recoding.
DBF_DATE_LAST_UPDATE=YYYY-MM-DD: Modification date to write in DBF header with year-month-day format. If not specified, current date is used.
ADJUST_TYPE=[YES/NO]: Defaults to NO. Set to YES to read the whole .dbf to adjust Real->Integer/Integer64 or Integer64->Integer field types when possible. This can be used when field widths are ambiguous and that by default OGR would select the larger data type. For example, a numeric column with 0 decimal figures and with width of 10/11 character may hold Integer or Integer64, and with width 19/20 may hold Integer64 or larger integer (hold as Real)
ADJUST_GEOM_TYPE=[NO/FIRST_SHAPE/ALL_SHAPES]: Defaults to FIRST_SHAPE. Defines how layer geometry type is computed, in particular to distinguish shapefiles that have shapes with significant values in the M dimension from the ones where the M values are set to the nodata value. By default (FIRST_SHAPE), the driver will look at the first shape and if it has M values it will expose the layer as having a M dimension. By specifying ALL_SHAPES, the driver will iterate over features until a shape with a valid M value is found to decide the appropriate layer type.
AUTO_REPACK=[YES/NO]: Defaults to YES. Whether the shapefile should be automatically repacked when needed, at dataset closing or at FlushCache()/SyncToDisk() time.
DBF_EOF_CHAR=[YES/NO]: Defaults to YES. Whether the .DBF should be terminated by a 0x1A end-of-file character, as in the DBF spec and done by other software vendors. Previous GDAL versions did not write one.