benj created DRILL-7568: --------------------------- Summary: Strange renaming of duplicate column name Key: DRILL-7568 URL: https://issues.apache.org/jira/browse/DRILL-7568 Project: Apache Drill Issue Type: Bug Affects Versions: 1.17.0, 1.16.0, 1.15.0 Reporter: benj
(explicit called) duplicate columns name are automatically renamed by drill {code:java} apache drill> SELECT 1 a, 2 a, 3 a, 4 a, 5 a, 6 a; +---+----+----+----+----+----+ | a | a0 | a1 | a2 | a3 | a4 | +---+----+----+----+----+----+ | 1 | 2 | 3 | 4 | 5 | 6 | +---+----+----+----+----+----+ {code} That's ok, this rule seems "logical" BUT (with a csvh containing columns a,b and c : {code:java} SELECT *, a, a, a, a FROM dfs.tmp.`example.csvh`; +------+------+------+------+------+------+------+ | a | b | c | a0 | a00 | a1 | a2 | +------+------+------+------+------+------+------+ | cola | colb | colc | cola | cola | cola | cola | +------+------+------+------+------+------+------+ {code} The renaming rule is not applying at the same way The first duplicate a is well renaming *a0* but the second is renaming *a00* (instead of *a1*). Note that the third is renaming a1 (with an offset of 1 compared to the expected) and so on. -- This message was sent by Atlassian Jira (v8.3.4#803005)