SQL Server Performance

Datatype to use for phone numbers in SQL Server

Discussion in 'General DBA Questions' started by artfuldodger, May 23, 2005.

  1. artfuldodger New Member

    What is the best datatype to use for storing phone numbers in SQL Server?

    What are the reasons behind using a specific datatype?
    I read somewhere that using text is beneficial.
    Why not use varchar versus test?
  2. Madhivanan Moderator

    I think varchar is enough
    Where did you read text can be used for this? Can you provide us that link?


    Madhivanan

    Failing to plan is Planning to fail
  3. derrickleggett New Member

    Whoever told you to use text was an idiot!!! Text would be used if you wanted to store the Yellow Pages for every single city in the US all in one big BLOB and never do anything useful with it.

    /RANT

    MeanOldDBA
    derrickleggett@hotmail.com

    When life gives you a lemon, fire the DBA.
  4. dineshasanka Moderator

    Best is varchar, and include check constraint or else u can deffine your own data type depending on the requirment.

    quote:Originally posted by artfuldodger

    What is the best datatype to use for storing phone numbers in SQL Server?

    What are the reasons behind using a specific datatype?
    I read somewhere that using text is beneficial.
    Why not use varchar versus test?
  5. artfuldodger New Member

    Thanks Guys.

    I found it in one of my searches for info on SQL Server.
    Nevertheless, I did what you guys suggested.
    I used varchar.

Share This Page