Example SDF Files - Advanced SQL Engine - Teradata Database

Database Utilities

Product
Advanced SQL Engine
Teradata Database
Release Number
17.05
Published
January 2021
Language
English (United States)
Last Update
2021-01-23
dita:mapPath
ynh1604715438919.ditamap
dita:ditavalPath
hoy1596145193032.ditaval
dita:id
B035-1102
lifecycle
previous
Product Category
Teradata Vantage™

Example: Teradata Database default locale format settings

// File name     : tdlocaledef.txt   
// Purpose       : This file contains the specifications for data formatting(SDF) 
//                 defined by the user.      
// Scope         : Project - subsystems 
// Required files: None
// History       :  05-21-2001 - Created
//                  10-27-2005 - Added BIGINT
//                  05-24-2010 - Added TimeZoneString
// Description   : This data is compatible with pre-V2R5 releases. 
// DBS System Formatting Data 
// Day and month names
      ShortDays { 
          "Sun";
          "Mon";
          "Tue";
          "Wed";
          "Thu";
          "Fri";
          "Sat"
      }
      LongDays { 
          "Sunday";
          "Monday";
          "Tuesday";
          "Wednesday";
          "Thursday";
          "Friday";
          "Saturday"
      }
      ShortMonths { 
          "Jan";
          "Feb";
          "Mar";
          "Apr";
          "May";
          "Jun";
          "Jul";
          "Aug";
          "Sep";
          "Oct";
          "Nov";
          "Dec"
      }
      LongMonths { 
          "January";
          "February";
          "March";
          "April";
          "May";
          "June";
          "July";
          "August";
          "September";
          "October";
          "November";
          "December"
      }
      AMPM { 
          "AM";
          "PM"
      }
      // Parsing Elements
      RadixSeparator {"."}
      GroupSeparator {","}
      GroupingRule   {"3"}
      Currency       {"$"}
      ISOCurrency    {"USD"}
      CurrencyName    {"US Dollars"}
      CurrencyRadixSeparator {"."}
      CurrencyGroupSeparator {","}
      CurrencyGroupingRule   {"3"}
      DualCurrency    {"$"}
      DualISOCurrency {"USD"}
      DualCurrencyName {"US Dollars"}
      // Data type default formats
      BYTEINT        {"-(3)9"}
      INTEGER        {"-(10)9"}
      SMALLINT       {"-(5)9"}
      BIGINT         {"-(19)9"}
      NUMERIC        {"--(I).9(F)"}
      REAL           {"-9.99999999999999E-999"}
      DATE           {"YY/MM/DD"}
      TIME           {"HH:MI:SS.S(F)Z"}
      TIMESTAMP      {"YYYY-MM-DDBHH:MI:SS.S(F)Z"}
      NUMBER         {"FN9"}
      // System Time Zone string
      TimeZoneString {""}

Example: Customized SDF for Japanese Data Formatting

This example shows how an SDF file might be customized for a Japanese location. The file contains Japanese date and time default formatting and the Unicode hex notation for Kanji characters. Also, Unicode characters in the default format strings are specified with “\u.”

// DBS System Formatting Data
// Day and month names
      ShortDays {
          "\u65E5";
          "\u6708";
          "\u706B";
          "\u6C34";
          "\u6728";
          "\u91D1";
          "\u571F"
      }
      LongDays {
          "\u65E5\u66DC\u65E5";
          "\u6708\u66DC\u65E5";
          "\u706B\u66DC\u65E5";
          "\u6C34\u66DC\u65E5";
          "\u6728\u66DC\u65E5";
          "\u91D1\u66DC\u65E5";
          "\u571F\u66DC\u65E5"
      }
      ShortMonths {
          "1\u6708";
          "2\u6708";
          "3\u6708";
          "4\u6708";
          "5\u6708";
          "6\u6708";
          "7\u6708";
          "8\u6708";
          "9\u6708";
          "10\u6708";
          "11\u6708";
          "12\u6708"
      }
      LongMonths {
          "1\u6708";
          "2\u6708";
          "3\u6708";
          "4\u6708";
          "5\u6708";
          "6\u6708";
          "7\u6708";
          "8\u6708";
          "9\u6708";
          "10\u6708";
          "11\u6708";
          "12\u6708"
      }
      AMPM {
          "\u5348\u524D";
          "\u5348\u5F8C"
      }
      // Parsing Elements
      RadixSeparator         {"."}
      GroupSeparator         {","}
      GroupingRule           {"3"}
      Currency               {"\u00A5"}
      ISOCurrency            {"JPY"}
      CurrencyName           {"Yen"}
      CurrencyRadixSeparator {"."}
      CurrencyGroupSeparator {","}
      CurrencyGroupingRule   {"3"}
      DualCurrency           {"\u00A5"}
      DualISOCurrency        {"JPY"}
      DualCurrencyName       {"Yen"}
      // Data type default formats
      BYTEINT        {"-(3)9"}
      INTEGER        {"G-(I)9"}
      SMALLINT       {"G-(I)9"}
      BIGINT         {"G-(I)9"}
      NUMERIC        {"G--(I)D9(F)"}
      REAL           {"G-9D99999999999999E-999"}
      DATE           {"YYYY\u5E74MM\u6708DD\u65E5"}
      TIME           {"HH\u6642MI\u5206SSDS(F)\u79D2Z"}
      TIMESTAMP      {"YYYY\u5E74MM\u6708DD\u65E5BHH\u6642MI\u5206SSDS(F)\u79D2Z"}      NUMBER         {"FN9"}
      // System Time Zone string
      TimeZoneString {""}