Menu

#431 XML columns require consistent casing when column sensing is enabled

v2.6.*
closed-fixed
None
2.7.0
5
2020-02-23
2019-04-18
No

When using column sensing, any encountered column name is checked against existing columns for that table by doing a case-insensitive comparison. However, when retrieving the attribute value to populate the data set, the xml qname is used to retrieve the value, which is case-sensitive. Thus, once a column is encountered for a table, subsequent usages of that column must have identical casing to the first usage. When they do not match casing, a null value is inserted.

Relevant code was found in FlatXmlProducer#startElement. Have not verified if other XML formats have the same behavior.

I assume that this is unintended behavior, since the code specifically does case-insensitive comparisons to determine if the column has already been encountered and error messages do specify that column names are case-insensitive.

If this is a bug that is determined to be worth fixing, I would like to take on developing the patch.

Discussion

  • Jeff Jensen

    Jeff Jensen - 2019-04-18

    Hi, thank you for the report and analysis.

    I would like to take on developing the patch

    Yes, seems like undesired behavior. Please create test(s) proving the problem along with a fix.

    Please follow the dev guide for making and testing changes.

     
  • Jeff Jensen

    Jeff Jensen - 2020-02-23
    • status: open --> pending
     
  • Jeff Jensen

    Jeff Jensen - 2020-02-23
    • status: pending --> closed-fixed
    • assigned_to: Jeff Jensen
    • Fixed Release: (not fixed) --> 2.6.1
     

Log in to post a comment.

MongoDB Logo MongoDB