locked
Which datatype should be used to store foreign language characters, date and numeric values? RRS feed

  • Question

  • NCHAR, NVARCHAR, NVARCHAR(MAX) can be used to store the string characters. But what should be used to store the numerical data and datetime values in unicode?

    Any pointers on this will be appreciated.

     


    MS SQL Server DBA
    Wednesday, June 22, 2011 1:01 PM

Answers

  • >But what should be used to store the numerical data and datetime values in unicode?

    DATETIME and numbers are internal formats and do not require unicode. Regardless of locale settings that change the display.

    • Proposed as answer by Naomi NEditor Wednesday, June 22, 2011 6:56 PM
    • Marked as answer by Peja TaoEditor Wednesday, June 29, 2011 8:58 AM
    Wednesday, June 22, 2011 2:54 PM
    Answerer
  • Use DATETIME type for storing datetime values (look also at date, datetime2, smalldatetime types). Use DECIMAL for numerical types (check also int, bigint, etc. - you need to chose the type depending on the structure of the data).
    For every expert, there is an equal and opposite expert. - Becker's Law


    My blog
    Wednesday, June 22, 2011 6:57 PM
    Answerer

All replies

  • >But what should be used to store the numerical data and datetime values in unicode?

    DATETIME and numbers are internal formats and do not require unicode. Regardless of locale settings that change the display.

    • Proposed as answer by Naomi NEditor Wednesday, June 22, 2011 6:56 PM
    • Marked as answer by Peja TaoEditor Wednesday, June 29, 2011 8:58 AM
    Wednesday, June 22, 2011 2:54 PM
    Answerer
  • Use DATETIME type for storing datetime values (look also at date, datetime2, smalldatetime types). Use DECIMAL for numerical types (check also int, bigint, etc. - you need to chose the type depending on the structure of the data).
    For every expert, there is an equal and opposite expert. - Becker's Law


    My blog
    Wednesday, June 22, 2011 6:57 PM
    Answerer