Uploaded image for project: 'Derby'
  1. Derby
  2. DERBY-166

NULL is not a valid constraint type

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Trivial
    • Resolution: Duplicate
    • 10.0.2.0
    • None
    • Documentation
    • None
    • Windows XP SP1 Professional

    Description

      The following statement in the documentation is incorrect:

      NULL The opposite of NOT NULL (not really a constraint), it specifies that the column can hold NULL values. Specifying NULL is the same as saying nothing at all, except when the column is included in a PRIMARY KEY constraint.

      If you try to create a column with the NULL attribute, you get a failure:

      CREATE TABLE X ( A INT NULL );

      ERROR 42X01: Syntax error: Encountered "null" at line 1, column 23.

      While this isn't really a problem since we can just omit the NULL keyword, the documentation gives the impression that it is allowed in the CREATE statement.

      Attachments

        Activity

          People

            Unassigned Unassigned
            baklarz George Baklarz
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: