Package org.apache.calcite.sql.dialect
Class JethroDataSqlDialect
java.lang.Object
org.apache.calcite.sql.SqlDialect
org.apache.calcite.sql.dialect.JethroDataSqlDialect
A
SqlDialect
implementation for the JethroData database.-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
Information about the capabilities of a Jethro database.static interface
Stores information about capabilities of Jethro databases.Nested classes/interfaces inherited from class org.apache.calcite.sql.SqlDialect
SqlDialect.CalendarPolicy, SqlDialect.Context, SqlDialect.DatabaseProduct, SqlDialect.FakeUtil
-
Field Summary
Fields inherited from class org.apache.calcite.sql.SqlDialect
BUILT_IN_OPERATORS_LIST, EMPTY_CONTEXT, identifierEndQuoteString, identifierEscapedQuote, identifierQuoteString, literalEndQuoteString, literalEscapedQuote, literalQuoteString, LOGGER, nullCollation
-
Constructor Summary
ConstructorDescriptionJethroDataSqlDialect
(SqlDialect.Context context) Creates a JethroDataSqlDialect. -
Method Summary
Modifier and TypeMethodDescription@Nullable SqlNode
emulateNullDirection
(SqlNode node, boolean nullsFirst, boolean desc) Returns the SqlNode for emulating the null direction for the given field ornull
if no emulation needs to be done.boolean
boolean
Returns whether the dialect supports character set names as part of a data type, for instanceVARCHAR(30) CHARACTER SET `ISO-8859-1`
.boolean
supportsFunction
(SqlOperator operator, RelDataType type, List<RelDataType> paramTypes) Returns whether this dialect supports a given function or operator.boolean
Returns whether the dialect supports nested aggregations, for instanceSELECT SUM(SUM(1))
.boolean
Returns whether the dialect supports OFFSET/FETCH clauses introduced by SQL:2008, for instanceOFFSET 10 ROWS FETCH NEXT 20 ROWS ONLY
.Methods inherited from class org.apache.calcite.sql.SqlDialect
allowsAs, configureParser, configureParser, containsNonAscii, create, defaultNullDirection, emulateJoinTypeForCrossJoin, emulateNullDirectionWithIsNull, getCalendarPolicy, getCastSpec, getConformance, getDatabaseProduct, getFormatModel, getNullCollation, getProduct, getQuotedCasing, getQuoting, getSingleRowTableName, getTypeSystem, getUnquotedCasing, hasImplicitTableAlias, identifierNeedsQuote, isCaseSensitive, quoteIdentifier, quoteIdentifier, quoteIdentifier, quoteStringLiteral, quoteStringLiteral, quoteStringLiteralUnicode, quoteTimestampLiteral, requiresAliasForFromItems, rewriteMaxMin, rewriteMaxMinExpr, rewriteSingleValueExpr, supportBooleanCaseWhen, supportsAggregateFunctionFilter, supportsAliasedValues, supportsApproxCountDistinct, supportsDataType, supportsGroupByLiteral, supportsGroupByWithCube, supportsGroupByWithRollup, supportsImplicitTypeCoercion, supportsJoinType, supportsTimestampPrecision, supportsWindowFunctions, unparseBoolLiteral, unparseCall, unparseDateTimeLiteral, unparseFetchUsingAnsi, unparseFetchUsingLimit, unparseLimit, unparseOffset, unparseOffsetFetch, unparseSqlDatetimeArithmetic, unparseSqlIntervalLiteral, unparseSqlIntervalQualifier, unparseTableScanHints, unparseTopN, unquoteStringLiteral
-
Constructor Details
-
JethroDataSqlDialect
Creates a JethroDataSqlDialect.
-
-
Method Details
-
supportsCharSet
public boolean supportsCharSet()Description copied from class:SqlDialect
Returns whether the dialect supports character set names as part of a data type, for instanceVARCHAR(30) CHARACTER SET `ISO-8859-1`
.- Overrides:
supportsCharSet
in classSqlDialect
-
emulateNullDirection
Description copied from class:SqlDialect
Returns the SqlNode for emulating the null direction for the given field ornull
if no emulation needs to be done.- Overrides:
emulateNullDirection
in classSqlDialect
- Parameters:
node
- The SqlNode representing the expressionnullsFirst
- Whether nulls should come firstdesc
- Whether the sort direction isRelFieldCollation.Direction.DESCENDING
orRelFieldCollation.Direction.STRICTLY_DESCENDING
- Returns:
- A SqlNode for null direction emulation or
null
if not required
-
supportsAggregateFunction
- Overrides:
supportsAggregateFunction
in classSqlDialect
-
supportsFunction
public boolean supportsFunction(SqlOperator operator, RelDataType type, List<RelDataType> paramTypes) Description copied from class:SqlDialect
Returns whether this dialect supports a given function or operator. It only applies to built-in scalar functions and operators, since user-defined functions and procedures should be read by JdbcSchema.- Overrides:
supportsFunction
in classSqlDialect
-
supportsOffsetFetch
public boolean supportsOffsetFetch()Description copied from class:SqlDialect
Returns whether the dialect supports OFFSET/FETCH clauses introduced by SQL:2008, for instanceOFFSET 10 ROWS FETCH NEXT 20 ROWS ONLY
. If false, we assume that the dialect supports the alternative syntaxLIMIT 20 OFFSET 10
.- Overrides:
supportsOffsetFetch
in classSqlDialect
-
supportsNestedAggregations
public boolean supportsNestedAggregations()Description copied from class:SqlDialect
Returns whether the dialect supports nested aggregations, for instanceSELECT SUM(SUM(1))
.- Overrides:
supportsNestedAggregations
in classSqlDialect
-
createCache
-