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

PRIMARY KEY does not imply NOT NULL

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 10.1.1.0
    • Component/s: SQL
    • Labels:
      None

      Description

      PRIMARY KEY does not imply NOT NULL. Derby issues error message:

      ij> create table tab (i integer primary key);
      ERROR 42831: 'I' cannot be a column of a primary key or unique key because it can contain null values.

      This is neither compliant with SQL-92 nor with SQL-99 (Feature E141-08, I think).

        Attachments

        1. derby-158-1.patch
          8 kB
          Jeremy Boynes
        2. derby-158-2.patch
          16 kB
          Jeremy Boynes

          Activity

            People

            • Assignee:
              jboynes Jeremy Boynes
              Reporter:
              bernt Bernt M. Johnsen
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: