Results 1 to 5 of 5

Thread: Datatypes

  1. #1
    Join Date
    Aug 2004
    Location
    Manchester, UK
    Posts
    143

    Question Unanswered: Datatypes

    I'm new to SQLServer and I'm creating some tables. In Oracle I always used varchar as this was the default and also recommended. The default in SQLServer seems to be char. Am I right in thinking that varchar is still best to use, as the field can then be of variable length rather than fixed?

  2. #2
    Join Date
    Nov 2002
    Location
    Jersey
    Posts
    10,322
    don't you mean varchar2 in Oracle?

    If the field is 10 to 15 bytes, make it char(n), all other values are varchar(n)


    And Good Luck with SQL Server....

    One word of Advice...drop the cursors until the house is on fire and your stuck in a corner....
    Brett
    8-)

    It's a Great Day for America everybody!

    dbforums Yak CorralRadio 'Rita
    dbForums Member List
    I'm Good Once as I ever was

    The physical order of data in a database has no meaning.

  3. #3
    Join Date
    Aug 2004
    Location
    Manchester, UK
    Posts
    143
    I do indeed mean varchar2, was just being lazy.

  4. #4
    Join Date
    Aug 2004
    Location
    Manchester, UK
    Posts
    143
    Also, I've had this new job for 4 months and so far all I've used is Access! Believe me SQLServer is like a breath of fresh air! It's not Oracle but it'll do!

  5. #5
    Join Date
    Nov 2002
    Location
    Jersey
    Posts
    10,322
    Quote Originally Posted by Polly013
    It's not Oracle but it'll do!
    [big grin]
    Careful
    [/big grin]

    Remember where you are......
    Brett
    8-)

    It's a Great Day for America everybody!

    dbforums Yak CorralRadio 'Rita
    dbForums Member List
    I'm Good Once as I ever was

    The physical order of data in a database has no meaning.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •