@Translator(name="mysql", description="A translator for open source MySQL Database, used with any version lower than 5") public class MySQLExecutionFactory extends JDBCExecutionFactory
ExecutionFactory.Format, ExecutionFactory.NullOrder, ExecutionFactory.SupportedJoinCriteria
DEFAULT_MAX_DEPENDENT_PREDICATES, DEFAULT_MAX_IN_CRITERIA, DEFAULT_TIME_ZONE
DEFAULT_MAX_FROM_GROUPS, DEFAULT_MAX_IN_CRITERIA_SIZE
Constructor and Description |
---|
MySQLExecutionFactory() |
Modifier and Type | Method and Description |
---|---|
List<String> |
getSupportedFunctions()
Get list of all supported function names.
|
int |
getTimestampNanoPrecision()
Return the precision of timestamp literals.
|
void |
start()
Initialize the connector with supplied configuration
|
boolean |
supportsAggregatesDistinct()
Support indicates connector can accept DISTINCT within aggregate functions
|
boolean |
supportsRowLimit()
Gets whether the connector can limit the number of rows returned by a query.
|
boolean |
supportsRowOffset()
Gets whether the connector supports a SQL clause (similar to the LIMIT with an offset) that can return
result sets that start in the middle of the resulting rows returned by a query
|
String |
translateLiteralDate(Date dateValue)
Subclasses should override this method to provide a different sql translation
of the literal date value.
|
String |
translateLiteralTime(Time timeValue)
Subclasses should override this method to provide a different sql translation
of the literal time value.
|
String |
translateLiteralTimestamp(Timestamp timestampValue)
Subclasses should override this method to provide a different sql translation
of the literal timestamp value.
|
boolean |
useParensForJoins()
Set to true to indicate that every branch of a join
should have parenthesis.
|
boolean |
useParensForSetQueries()
Set to true to indicate that every branch of a set query
should have parenthesis, i.e.
|
addSourceComment, afterInitialConnectionObtained, bindValue, closeConnection, createMetadataProcessor, createProcedureExecution, createResultSetExecution, createUpdateExecution, executeStoredProcedure, formatDateValue, getConnection, getDatabaseCalendar, getDatabaseTimeZone, getDatabaseVersion, getDefaultNullOrder, getDefaultSupportedFunctions, getFunctionModifiers, getLikeRegexString, getMaxPreparedInsertBatchSize, getMetadata, getSetOperationString, getSourceComment, getSQLConversionVisitor, hasTimeType, isSourceRequired, isTrimStrings, obtainedConnection, parseName, registerFunctionModifier, registerSpecificTypeOfOutParameter, replaceElementName, retrieveValue, retrieveValue, setDatabaseTimeZone, setDatabaseVersion, setFetchSize, setMaxPreparedInsertBatchSize, setTrimStrings, setUseBindVariables, setUseCommentsInSourceQuery, supportsAggregatesAvg, supportsAggregatesCount, supportsAggregatesCountStar, supportsAggregatesMax, supportsAggregatesMin, supportsAggregatesSum, supportsAliasedTable, supportsBatchedUpdates, supportsBulkUpdate, supportsCompareCriteriaEquals, supportsCompareCriteriaOrdered, supportsCorrelatedSubqueries, supportsExistsCriteria, supportsGroupBy, supportsHaving, supportsInCriteria, supportsInCriteriaSubquery, supportsInlineViews, supportsInsertWithQueryExpression, supportsIsNullCriteria, supportsLikeCriteria, supportsLikeCriteriaEscapeCharacter, supportsNotCriteria, supportsOrCriteria, supportsOrderByUnrelated, supportsQuantifiedCompareCriteriaAll, supportsQuantifiedCompareCriteriaSome, supportsScalarSubqueries, supportsSearchedCaseExpressions, supportsSelectExpression, supportsSelfJoins, supportsSetQueryOrderBy, supportsUnions, translate, translateCommand, translateLimit, translateLiteralBoolean, useAsInGroupAlias, useBindVariables, useCommentsInSourceQuery, usePreparedStatements, useSelectLimit
addPushDownFunction, areLobsUsableAfterClose, createExecution, getConnection, getInstance, getLanguageFactory, getMaxDependentInPredicates, getMaxFromGroups, getMaxInCriteriaSize, getPushDownFunctions, getSupportedJoinCriteria, getTypeFacility, isCopyLobs, isImmutable, requiresCriteria, setCopyLobs, setImmutable, setMaxDependentInPredicates, setMaxInCriteriaSize, setRequiresCriteria, setSourceRequired, setSupportedJoinCriteria, setSupportsFullOuterJoins, setSupportsInnerJoins, setSupportsOrderBy, setSupportsOuterJoins, setSupportsSelectDistinct, supportsAdvancedOlapOperations, supportsAggregatesEnhancedNumeric, supportsArrayAgg, supportsCommonTableExpressions, supportsConvert, supportsDependentJoins, supportsElementaryOlapOperations, supportsExcept, supportsFormatLiteral, supportsFullOuterJoins, supportsFunctionsInGroupBy, supportsInnerJoins, supportsIntersect, supportsLikeRegex, supportsOnlyFormatLiterals, supportsOnlyLiteralComparison, supportsOnlySingleTableGroupBy, supportsOrderBy, supportsOrderByNullOrdering, supportsOuterJoins, supportsSelectDistinct, supportsSimilarTo, supportsWindowDistinctAggregates, supportsWindowOrderByWithAggregates, useAnsiJoin
public void start() throws TranslatorException
ExecutionFactory
start
in class JDBCExecutionFactory
TranslatorException
public String translateLiteralDate(Date dateValue)
JDBCExecutionFactory
{d '2002-12-31'}
translateLiteralDate
in class JDBCExecutionFactory
dateValue
- Date value, never nullpublic String translateLiteralTime(Time timeValue)
JDBCExecutionFactory
{t '23:59:59'}
See JDBCExecutionFactory.hasTimeType()
to represent literal times as timestamps.translateLiteralTime
in class JDBCExecutionFactory
timeValue
- Time value, never nullpublic String translateLiteralTimestamp(Timestamp timestampValue)
JDBCExecutionFactory
{ts '2002-12-31 23:59:59'}
.
See JDBCExecutionFactory.getTimestampNanoPrecision()
to control the literal
precision.translateLiteralTimestamp
in class JDBCExecutionFactory
timestampValue
- Timestamp value, never nullpublic boolean useParensForSetQueries()
JDBCExecutionFactory
useParensForSetQueries
in class JDBCExecutionFactory
public int getTimestampNanoPrecision()
JDBCExecutionFactory
getTimestampNanoPrecision
in class JDBCExecutionFactory
public boolean useParensForJoins()
JDBCExecutionFactory
useParensForJoins
in class JDBCExecutionFactory
public List<String> getSupportedFunctions()
ExecutionFactory
getSupportedFunctions
in class JDBCExecutionFactory
for a listing of system pushdown functions. Note that
not all system functions are listed as some functions will use a common name
such as CONCAT vs. the || operator, and other functions will be rewritten and
not pushed down, such as SPACE.
public boolean supportsAggregatesDistinct()
ExecutionFactory
supportsAggregatesDistinct
in class JDBCExecutionFactory
public boolean supportsRowLimit()
ExecutionFactory
supportsRowLimit
in class ExecutionFactory<DataSource,Connection>
public boolean supportsRowOffset()
ExecutionFactory
supportsRowOffset
in class ExecutionFactory<DataSource,Connection>
Copyright © 2012 JBoss by Red Hat. All Rights Reserved.