Results 1 to 4 of 4
  1. #1
    Join Date
    Sep 2003
    Posts
    9

    Unanswered: Does "text type" belong to SQL2 standard ?

    Hi,

    I am developping an application that should work with different RDBMS.

    I need to store a field of 500 characters.

    Hence, I thought of using the type "text" that works with MySQL, but I am wondering if it is part of SQL standard or if it is supported by the main RBDMS (Orcale, DB2, SQL Server ...).

    Thanks in advance,

    Sylvain

  2. #2
    Join Date
    Oct 2002
    Location
    Plymouth UK
    Posts
    116
    The "Text" datatype is not part of the ANSI SQL99 standard. Most vendors also have their own variants of datatypes. The nearest agreements in datatypes for your purposes I guess would be to use a VARCHAR. However there is still variation, in Oracle this would be a VARCHAR2.

    Hope this help you on your way.

  3. #3
    Join Date
    Sep 2003
    Posts
    9
    Hi,

    Originally posted by gannet
    The "Text" datatype is not part of the ANSI SQL99 standard. Most vendors also have their own variants of datatypes. The nearest agreements in datatypes for your purposes I guess would be to use a VARCHAR. However there is still variation, in Oracle this would be a VARCHAR2.

    But with MySQL for example VARCHAR is limited to 255. We can't do VARCHAR(500).

    So you see any solution ?

    Regards
    Sylvain

  4. #4
    Join Date
    Oct 2002
    Location
    Plymouth UK
    Posts
    116
    Unfortunately there will be no vendor independent way araound this, you will need to generate some vendor specific translations. Not what you wanted to hear I know.

Posting Permissions

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