public class TestScanLevelProjection extends SubOperatorTest
DrillTest.MemWatcherdirTestWatcher, fixturelogOutcome, objectMapper, REPEAT_RULE, thrownException, TIMEOUT| Constructor and Description |
|---|
TestScanLevelProjection() |
| Modifier and Type | Method and Description |
|---|---|
void |
testArray()
Similar to maps, if the project list contains "a[1]" then we've learned that
a is an array, but we don't know what type.
|
void |
testBasics()
Basic test: select a set of columns (a, b, c) when the
data source has an early schema of (a, c, d).
|
void |
testColumnAndWildcard()
Test a column name and a wildcard.
|
void |
testEmptyProjection()
Test an empty projection which occurs in a
SELECT COUNT(*) query.
|
void |
testEmptyProvidedSchema() |
void |
testMap()
Map projection occurs when a query contains project-list items with
a dot, such as "a.b".
|
void |
testNonStrictProvidedSchema()
Non-strict provided schema, reader that offers an extra column,
projection list includes the column.
|
void |
testProvidedSchemaModeMismatch() |
void |
testProvidedSchemaTypeMismatch() |
void |
testProvidedSchemaWildcard() |
void |
testProvidedSchemaWildcardSpecialCols() |
void |
testStrictProvidedSchema()
Strict provided schema, reader that offers an extra column,
projection list includes the column.
|
void |
testStrictProvidedSchemaWildcard()
Wildcard projection with a strict schema is the same as a non-strict
schema, except that the projection type is different.
|
void |
testTwoWildcards()
Wildcard included twice is benign
|
void |
testWildcard()
Simulate a SELECT * query by passing "**" (Drill's internal representation
of the wildcard) as a column name.
|
void |
testWildcardAndColumns()
Can include both a wildcard and a column name.
|
classSetup, classTeardownescapeJsonString, finishDrillTest, initDrillTestpublic void testBasics()
public void testMap()
public void testArray()
public void testWildcard()
public void testEmptyProjection()
public void testWildcardAndColumns()
public void testColumnAndWildcard()
public void testTwoWildcards()
Note: Drill actually allows this, but the work should be done in the project operator; scan should see at most one wildcard.
public void testEmptyProvidedSchema()
public void testProvidedSchemaWildcard()
public void testProvidedSchemaWildcardSpecialCols()
public void testStrictProvidedSchemaWildcard()
public void testProvidedSchemaTypeMismatch()
public void testProvidedSchemaModeMismatch()
public void testNonStrictProvidedSchema()
public void testStrictProvidedSchema()
Copyright © 2021 The Apache Software Foundation. All rights reserved.