Skip to content
  • Erik Froseth's avatar
    2f690381
    Bug#28460369 LOAD DATA INFILE THROWS ERROR WITH NOT NULL COLUMN DEFINED VIA SET · 2f690381
    Erik Froseth authored
    When loading data using LOAD DATA, it is possible to specify values for
    columns using the SET clause (LOAD DATA ... SET col1 = 'foo';).
    This can for instance be used to set values for columns that does not
    have any data specified in the data file. Intuivetly, it should be
    possible to set values for NOT NULL columns with this syntax
    (a kind of default value for the column). This did not work with
    GEOMETRY NOT NULL columns, as the check for whether or not all columns
    had a value assigned to it did not consider columns in the SET clause.
    This patch changes this so that columns set in the SET clause are
    considered when evaluating whether or not all NOT NULL columns has a
    value assigned to it.
    
    Change-Id: I3ca2ffa27ca4fbc6a81723b29188b1c018093e36
    2f690381
    Bug#28460369 LOAD DATA INFILE THROWS ERROR WITH NOT NULL COLUMN DEFINED VIA SET
    Erik Froseth authored
    When loading data using LOAD DATA, it is possible to specify values for
    columns using the SET clause (LOAD DATA ... SET col1 = 'foo';).
    This can for instance be used to set values for columns that does not
    have any data specified in the data file. Intuivetly, it should be
    possible to set values for NOT NULL columns with this syntax
    (a kind of default value for the column). This did not work with
    GEOMETRY NOT NULL columns, as the check for whether or not all columns
    had a value assigned to it did not consider columns in the SET clause.
    This patch changes this so that columns set in the SET clause are
    considered when evaluating whether or not all NOT NULL columns has a
    value assigned to it.
    
    Change-Id: I3ca2ffa27ca4fbc6a81723b29188b1c018093e36
Loading