|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectmondrian.spi.impl.JdbcDialectImpl
mondrian.spi.impl.DerbyDialect
public class DerbyDialect
Implementation of Dialect for the Apache Derby database.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface mondrian.spi.Dialect |
|---|
Dialect.DatabaseProduct, Dialect.Datatype |
| Field Summary | |
|---|---|
static JdbcDialectFactory |
FACTORY
|
| Fields inherited from class mondrian.spi.impl.JdbcDialectImpl |
|---|
databaseProduct, permitsSelectNotInGroupBy, productVersion |
| Constructor Summary | |
|---|---|
DerbyDialect(Connection connection)
Creates a DerbyDialect. |
|
| Method Summary | |
|---|---|
boolean |
allowsMultipleCountDistinct()
Returns whether this Dialect supports more than one distinct aggregation in the same query. |
String |
generateInline(List<String> columnNames,
List<String> columnTypes,
List<String[]> valueList)
Generates a SQL statement to represent an inline dataset. |
protected void |
quoteDateLiteral(StringBuilder buf,
String value,
Date date)
Helper method for JdbcDialectImpl.quoteDateLiteral(StringBuilder, String). |
boolean |
requiresAliasForFromQuery()
Returns whether this Dialect requires subqueries in the FROM clause to have an alias. |
boolean |
supportsGroupByExpressions()
Returns whether this Dialect supports expressions in the GROUP BY clause. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final JdbcDialectFactory FACTORY
| Constructor Detail |
|---|
public DerbyDialect(Connection connection)
throws SQLException
connection - Connection
SQLException| Method Detail |
|---|
protected void quoteDateLiteral(StringBuilder buf,
String value,
Date date)
JdbcDialectImplJdbcDialectImpl.quoteDateLiteral(StringBuilder, String).
quoteDateLiteral in class JdbcDialectImplbuf - Buffer to append tovalue - Value as stringdate - Value as datepublic boolean requiresAliasForFromQuery()
Dialect
requiresAliasForFromQuery in interface DialectrequiresAliasForFromQuery in class JdbcDialectImplDialect.allowsFromQuery()public boolean allowsMultipleCountDistinct()
DialectIn Derby 10.1,
select couunt(distinct x) from t
is OK, but
select couunt(distinct x), count(distinct y) from t
gives "Multiple DISTINCT aggregates are not supported at this time."
allowsMultipleCountDistinct in interface DialectallowsMultipleCountDistinct in class JdbcDialectImpl
public String generateInline(List<String> columnNames,
List<String> columnTypes,
List<String[]> valueList)
DialectFor example, for Oracle, generates
SELECT 1 AS FOO, 'a' AS BAR FROM dual UNION ALL SELECT 2 AS FOO, 'b' AS BAR FROM dual
For ANSI SQL, generates:
VALUES (1, 'a'), (2, 'b')
generateInline in interface DialectgenerateInline in class JdbcDialectImplcolumnNames - List of column namescolumnTypes - List of column types ("String" or "Numeric")valueList - List of rows values
public boolean supportsGroupByExpressions()
Dialect
supportsGroupByExpressions in interface DialectsupportsGroupByExpressions in class JdbcDialectImpl
|
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||