The DateForm Setting

Teradata Vantageā„¢ Data Types and Literals

brand
Software
Teradata Vantage
prodname
Teradata Database
Teradata Vantage NewSQL Engine
vrm_release
16.20
category
Programming Reference
featnum
B035-1143-162K

Before you change the DateForm setting, you need to consider the effect the change has on the following:

  • Export data type of DATE values.

    Changing the DateForm setting changes the export data type of DATE values.

  • Data-entry format for dates.

    Changing the DateForm setting changes the data entry format of dates for new tables, but not for existing tables. To avoid data entry problems, however, you can enter all dates as ANSI DATE literals.

  • Display format of DATE columns.

    Changing the DateForm setting changes the display of DATE values in new tables, but not in existing tables. Therefore, DATE values display differently for new tables than for old tables. Because views are based on the underlying table, this is true for views of tables as well.

  • String-to-DATE comparisons and conversions.

    To compare or convert strings to DATE values, the strings must have the same format as the DATE values. Such comparisons can fail after you change the DateForm setting because the DATE format for new tables, views of new tables, and existing macros changes. To avoid format errors in string-to-DATE comparisons, however, you can specify dates as ANSI DATE literals.

  • Format of DATE values in macros being executed.

    Changing the DateForm setting can change the format of DATE values in macros, which can cause the macro to fail.

Changing the DateForm setting does not change the DATE format for the following:

  • Tables created prior to the format change
  • Tables created by users currently logged on
  • Macros executed by users currently logged on
  • Views based on tables that were created prior to the change