Skip to content

date-column-without-suffix (NM016)#

Automatic fix is available.

What it does#

Checks that date columns are suffixed with the defined suffix, by default _date.

Why not?#

Adding _date to a date column name makes it clear that the value represents the date when something happened. For example, created_date indicates the date when a record was created, and updated_date indicates the date when a record was last updated.

Date columns could easily be confused with other types of data if not clearly named. For example, a column named created might be unclear — does it represent a boolean flag, a date, or something else? created_date removes this ambiguity by specifying that it's a date.

When should you?#

Almost Never.

Use instead:#

Add the defined suffix or the default _date to to the date column name.

Configuration#

date-column-suffix: Specify the suffix for date columns.