Skip to content

Date decodes

Note

If your data is already in YYYYMMDD format it is suitable for use in FastStats directly and you need not use any conversion.

Note

We advise that all dates use 4 digit years to ensure standard date compliance.

FastStats automatically detects dates by looking for common date formats and setting the appropriate mapping. Dates are treated as a specialisation of selector codes. During the auto discovery processing the first and last dates are detected. Decodes codes and descriptions are then automatically created for a full date range encompassing the end points.

However it is sometimes necessary to set date mappings manually if the format cannot be automatically detected.

Date format conversions

dd.mm.yyyy converts a dd.mm.yyyy date (where . can be any, or no separator) to a YYYYMMDD date selector. Note that a space is not permissible as a separator.

Examples:

21/07/1969 → 19690721

13/01/2002 → 20020113

dd.mmm.yyyy converts a dd.mm.yyyy date (where . can be any, or no separator) to a YYYYMMDD date selector. Note that a space is not permissible as a separator.

Examples:

21-JUL-1969 → 19690721

13-JAN-2002 → 20020113

yyyy.ddd converts a Julian date yyyy.ddd (where . can be any, or no separator) to a YYYYMMDD date selector. Note that a space is not permissible as a separator.

Example

1969-205 →19690724.

mm.yyyy converts a mm.yyyy month (where . can be any, or no separator) to a YYYYMM month selector. Note that a space is not permissible as a separator.

e.g. 07/1969 → 196907.

mm.dd.yyyy and mmm.dd.yyyy are US equivalents.

dd.mm converts a yearless dd.mm date to a MMDD "birthday" selector.

e.g. 3107 → 0731 (31st July).

yyyy.[mm.[dd]] converts a date specified to the year, month or day level to an age in years relative to the current date. The map output size will be forced to 3. This format conversion is only necessary for age calculation.

The map size can be specified to give other options when processing full date conversions only. If map size is changed to 3 the date will be converted to an age in years relative to the current date.