diff --git a/java/src/main/java/ai/rapids/cudf/Table.java b/java/src/main/java/ai/rapids/cudf/Table.java index 360bb5c7467..861c6485a5c 100644 --- a/java/src/main/java/ai/rapids/cudf/Table.java +++ b/java/src/main/java/ai/rapids/cudf/Table.java @@ -2004,10 +2004,6 @@ public GatherMap[] leftJoinGatherMaps(Table rightKeys, boolean compareNullsEqual */ public GatherMap[] leftJoinGatherMaps(Table rightTable, CompiledExpression condition, boolean compareNullsEqual) { - if (getNumberOfColumns() != rightTable.getNumberOfColumns()) { - throw new IllegalArgumentException("column count mismatch, this: " + getNumberOfColumns() + - "rightKeys: " + rightTable.getNumberOfColumns()); - } long[] gatherMapData = conditionalLeftJoinGatherMaps(getNativeView(), rightTable.getNativeView(), condition.getNativeHandle(), compareNullsEqual); @@ -2049,10 +2045,6 @@ public GatherMap[] innerJoinGatherMaps(Table rightKeys, boolean compareNullsEqua */ public GatherMap[] innerJoinGatherMaps(Table rightTable, CompiledExpression condition, boolean compareNullsEqual) { - if (getNumberOfColumns() != rightTable.getNumberOfColumns()) { - throw new IllegalArgumentException("column count mismatch, this: " + getNumberOfColumns() + - "rightKeys: " + rightTable.getNumberOfColumns()); - } long[] gatherMapData = conditionalInnerJoinGatherMaps(getNativeView(), rightTable.getNativeView(), condition.getNativeHandle(), compareNullsEqual); @@ -2094,10 +2086,6 @@ public GatherMap[] fullJoinGatherMaps(Table rightKeys, boolean compareNullsEqual */ public GatherMap[] fullJoinGatherMaps(Table rightTable, CompiledExpression condition, boolean compareNullsEqual) { - if (getNumberOfColumns() != rightTable.getNumberOfColumns()) { - throw new IllegalArgumentException("column count mismatch, this: " + getNumberOfColumns() + - "rightKeys: " + rightTable.getNumberOfColumns()); - } long[] gatherMapData = conditionalFullJoinGatherMaps(getNativeView(), rightTable.getNativeView(), condition.getNativeHandle(), compareNullsEqual); @@ -2146,10 +2134,6 @@ public GatherMap leftSemiJoinGatherMap(Table rightKeys, boolean compareNullsEqua */ public GatherMap leftSemiJoinGatherMap(Table rightTable, CompiledExpression condition, boolean compareNullsEqual) { - if (getNumberOfColumns() != rightTable.getNumberOfColumns()) { - throw new IllegalArgumentException("column count mismatch, this: " + getNumberOfColumns() + - "rightKeys: " + rightTable.getNumberOfColumns()); - } long[] gatherMapData = conditionalLeftSemiJoinGatherMap(getNativeView(), rightTable.getNativeView(), condition.getNativeHandle(), compareNullsEqual); @@ -2191,10 +2175,6 @@ public GatherMap leftAntiJoinGatherMap(Table rightKeys, boolean compareNullsEqua */ public GatherMap leftAntiJoinGatherMap(Table rightTable, CompiledExpression condition, boolean compareNullsEqual) { - if (getNumberOfColumns() != rightTable.getNumberOfColumns()) { - throw new IllegalArgumentException("column count mismatch, this: " + getNumberOfColumns() + - "rightKeys: " + rightTable.getNumberOfColumns()); - } long[] gatherMapData = conditionalLeftAntiJoinGatherMap(getNativeView(), rightTable.getNativeView(), condition.getNativeHandle(), compareNullsEqual); diff --git a/java/src/test/java/ai/rapids/cudf/TableTest.java b/java/src/test/java/ai/rapids/cudf/TableTest.java index 1b2ed1ad0b8..6b347897f82 100644 --- a/java/src/test/java/ai/rapids/cudf/TableTest.java +++ b/java/src/test/java/ai/rapids/cudf/TableTest.java @@ -1496,7 +1496,9 @@ void testConditionalLeftJoinGatherMaps() { new ColumnReference(0, TableReference.LEFT), new ColumnReference(0, TableReference.RIGHT)); try (Table left = new Table.TestBuilder().column(2, 3, 9, 0, 1, 7, 4, 6, 5, 8).build(); - Table right = new Table.TestBuilder().column(6, 5, 9, 8, 10, 32).build(); + Table right = new Table.TestBuilder() + .column(6, 5, 9, 8, 10, 32) + .column(0, 1, 2, 3, 4, 5).build(); Table expected = new Table.TestBuilder() .column( 0, 1, 2, 2, 2, 3, 4, 5, 5, 6, 7, 8, 9, 9) .column(inv, inv, 0, 1, 3, inv, inv, 0, 1, inv, 1, inv, 0, 1) @@ -1589,7 +1591,9 @@ void testConditionalInnerJoinGatherMaps() { new ColumnReference(0, TableReference.LEFT), new ColumnReference(0, TableReference.RIGHT)); try (Table left = new Table.TestBuilder().column(2, 3, 9, 0, 1, 7, 4, 6, 5, 8).build(); - Table right = new Table.TestBuilder().column(6, 5, 9, 8, 10, 32).build(); + Table right = new Table.TestBuilder() + .column(6, 5, 9, 8, 10, 32) + .column(0, 1, 2, 3, 4, 5).build(); Table expected = new Table.TestBuilder() .column(2, 2, 2, 5, 5, 7, 9, 9) .column(0, 1, 3, 0, 1, 1, 0, 1) @@ -1684,7 +1688,9 @@ void testConditionalFullJoinGatherMaps() { new ColumnReference(0, TableReference.LEFT), new ColumnReference(0, TableReference.RIGHT)); try (Table left = new Table.TestBuilder().column(2, 3, 9, 0, 1, 7, 4, 6, 5, 8).build(); - Table right = new Table.TestBuilder().column(6, 5, 9, 8, 10, 32).build(); + Table right = new Table.TestBuilder() + .column(6, 5, 9, 8, 10, 32) + .column(0, 1, 2, 3, 4, 5).build(); Table expected = new Table.TestBuilder() .column(inv, inv, inv, 0, 1, 2, 2, 2, 3, 4, 5, 5, 6, 7, 8, 9, 9) .column( 2, 4, 5, inv, inv, 0, 1, 3, inv, inv, 0, 1, inv, 1, inv, 0, 1) @@ -1763,7 +1769,9 @@ void testConditionalLeftSemiJoinGatherMap() { new ColumnReference(0, TableReference.LEFT), new ColumnReference(0, TableReference.RIGHT)); try (Table left = new Table.TestBuilder().column(2, 3, 9, 0, 1, 7, 4, 6, 5, 8).build(); - Table right = new Table.TestBuilder().column(6, 5, 9, 8, 10, 32).build(); + Table right = new Table.TestBuilder() + .column(6, 5, 9, 8, 10, 32) + .column(0, 1, 2, 3, 4, 5).build(); Table expected = new Table.TestBuilder() .column(2, 5, 7, 9) // left .build(); @@ -1827,7 +1835,9 @@ void testConditionalLeftAntiJoinGatherMap() { new ColumnReference(0, TableReference.LEFT), new ColumnReference(0, TableReference.RIGHT)); try (Table left = new Table.TestBuilder().column(2, 3, 9, 0, 1, 7, 4, 6, 5, 8).build(); - Table right = new Table.TestBuilder().column(6, 5, 9, 8, 10, 32).build(); + Table right = new Table.TestBuilder() + .column(6, 5, 9, 8, 10, 32) + .column(0, 1, 2, 3, 4, 5).build(); Table expected = new Table.TestBuilder() .column(0, 1, 3, 4, 6, 8) // left .build();