Allow use of Logical dbf data type


The DBIII format supports more data types then our current shapefile format, making some shapefiles not work properly in MW5.
According to the following data types are supported:

Data Type

Data Input

C (Character)

All OEM code page characters.

D (Date)

Numbers and a character to separate month, day, and year (stored internally as 8 digits in YYYYMMDD format).

N (Numeric)

- . 0 1 2 3 4 5 6 7 8 9

L (Logical)

? Y y N n T t F f (? when not initialized).

M (Memo)

All OEM code page characters (stored internally as 10 digits representing a .DBT block number).

We're missing support for the Date type (see ) and the Logical type.

Also some MW5 plugins like the Table Editor don't handle Date and Logical properly.


Jerry Faust
April 2, 2018, 4:13 AM

Note that Memo fields are still not supported, but a new Issue () has been created to give coverage to that feature.

Jerry Faust
April 2, 2018, 4:11 AM

Date and Logical field types have been added to the Shapefiles. While Dates are also supported by OGR, Logical fields are not.

A Logical field in an OgrLayer is stored as a single-character string field, that just happens to contain one of the valid Logical characters (Y, y, N, n, T, t, F, f, ?). When converting from an OgrLayer (using GetBuffer), MapWinGIS will by default interpret such fields as Logical fields. This default behavior can be changed, through the new Global setting, OgrInterpretYNStringAsBoolean, if you have a need to interpret those fields as their raw string data.



Jerry Faust


Paul Meems


Epic Link


Affects versions

Fix versions