Uploaded image for project: 'WiredTiger'
  1. WiredTiger
  2. WT-2757

Column tables behave differently when column names are provided

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major - P3
    • Resolution: Fixed
    • Affects Version/s: WT2.8.0
    • Fix Version/s: WT2.9.0, 3.3.11, 3.2.10
    • Labels:
      None
    • Environment:
      Debian Jessie

      Description

      I attach a patch with a test that demonstrate the problem against master.

      What works:

      • Create a table with a single record column as key and whatever as value column
      • Open a cursor in append mode
      • Set value
      • Insert
      • Retrieve record number with cursor->get_key()

      In this case cursor->uri is file:terms.wt

      What doesn't work:

      • Create a table with a single record column as key and whatever as value column and *give a name to the columns*.
      • Open a cursor in append mode
      • Set value
      • Insert
      • cursor->get_key() will raise the following exception:

      ======================================================================
      ERROR: test_bug016.test_bug016.test_with_column_names
      Insert a row into a table *with* column names
      ----------------------------------------------------------------------
      Traceback (most recent call last):
        File "/home/amirouche/src/c/wiredtiger/test/suite/test_bug016.py", line 31, in test_with_column_names
          self.assertEqual(cursor.get_key(), 1)
        File "/home/amirouche/src/c/wiredtiger/lang/python/wiredtiger/__init__.py", line 269, in get_key
          k = self.get_keys()
        File "/home/amirouche/src/c/wiredtiger/lang/python/wiredtiger/__init__.py", line 281, in get_keys
          return [self._get_recno(),]
      WiredTigerError: Invalid argument
       
      ----------------------------------------------------------------------
      

      In this case cursor->uri is table:terms.

        Attachments

          Activity

            People

            • Assignee:
              keith.bostic Keith Bostic
              Reporter:
              amz3 Amirouche
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: