Documentation

OraclePlatform extends AbstractPlatform
in package

OraclePlatform.

Table of Contents

Constants

CREATE_FOREIGNKEYS  = 2
CREATE_INDEXES  = 1

Properties

$_eventManager  : EventManager|null
$_keywords  : KeywordList|null
Holds the KeywordList instance for the current platform.
$doctrineTypeComments  : array<string|int, string>|null
Contains a list of all columns that should generate parseable column comments for type-detection in reverse engineering scenarios.
$doctrineTypeMapping  : array<string|int, string>|null

Methods

appendLockHint()  : string
Honors that some SQL vendors such as MsSql use table hints for locking instead of the ANSI SQL FOR UPDATE specification.
assertValidIdentifier()  : void
Assertion for Oracle identifiers.
canEmulateSchemas()  : bool
Whether this platform can emulate schemas.
columnsEqual()  : bool
Compares the definitions of the given columns in the context of this platform.
convertBooleans()  : mixed
Some platforms need the boolean values to be converted.
convertBooleansToDatabaseValue()  : mixed
This method should handle the prepared statements case. When there is no distinction, it's OK to use the same method.
convertFromBoolean()  : mixed
Some platforms have boolean literals that needs to be correctly converted
createSavePoint()  : string
Returns the SQL to create a new savepoint.
createSchemaManager()  : OracleSchemaManager
Creates the schema manager that can be used to inspect and change the underlying database schema according to the dialect of the platform.
escapeStringForLike()  : string
Escapes metacharacters in a string intended to be used with a LIKE operator.
getAcosExpression()  : string
Returns the SQL to get the arccosine of a value.
getAdvancedForeignKeyOptionsSQL()  : string
Returns the FOREIGN KEY query section dealing with non-standard options as MATCH, INITIALLY DEFERRED, ON UPDATE, .
getAlterSchemaSQL()  : array<int, string>
Generates SQL statements that can be used to apply the diff.
getAlterSequenceSQL()  : string
Returns the SQL to change a sequence on this platform.
getAlterTableSQL()  : array<int, string>
Gets the SQL statements for altering an existing table.
getAsciiStringTypeDeclarationSQL()  : string
Returns the SQL snippet used to declare a column that can store characters in the ASCII character set
getAvgExpression()  : string
Returns the SQL snippet to get the average value of a column.
getBetweenExpression()  : string
Returns the SQL that checks if an expression evaluates to a value between two values.
getBigIntTypeDeclarationSQL()  : string
Returns the SQL snippet that declares an 8 byte integer column.
getBinaryDefaultLength()  : int
Gets the default length of a binary column.
getBinaryMaxLength()  : int
Gets the maximum length of a binary column.
getBinaryTypeDeclarationSQL()  : string
Returns the SQL snippet used to declare a BINARY/VARBINARY column type.
getBitAndComparisonExpression()  : string
Returns the SQL bit AND comparison expression.
getBitOrComparisonExpression()  : string
Returns the SQL bit OR comparison expression.
getBlobTypeDeclarationSQL()  : string
Returns the SQL Snippet used to declare a BLOB column type.
getBooleanTypeDeclarationSQL()  : string
Returns the SQL snippet that declares a boolean column.
getCharMaxLength()  : int
Gets the maximum length of a char column.
getCheckDeclarationSQL()  : string
Obtains DBMS specific SQL code portion needed to set a CHECK constraint declaration to be used in statements like CREATE TABLE.
getClobTypeDeclarationSQL()  : string
Returns the SQL snippet used to declare a CLOB column type.
getColumnCharsetDeclarationSQL()  : string
Obtains DBMS specific SQL code portion needed to set the CHARACTER SET of a column declaration to be used in statements like CREATE TABLE.
getColumnCollationDeclarationSQL()  : string
Obtains DBMS specific SQL code portion needed to set the COLLATION of a column declaration to be used in statements like CREATE TABLE.
getColumnDeclarationListSQL()  : string
Gets declaration of a number of columns in bulk.
getColumnDeclarationSQL()  : string
Obtains DBMS specific SQL code portion needed to declare a generic type column to be used in statements like CREATE TABLE.
getColumnsFieldDeclarationListSQL()  : string
Obtains DBMS specific SQL code portion needed to set an index declaration to be used in statements like CREATE TABLE.
getCommentOnColumnSQL()  : string
getConcatExpression()  : string
Returns a SQL snippet to concatenate the given expressions.
getCosExpression()  : string
Returns the SQL to get the cosine of a value.
getCountExpression()  : string
Returns the SQL snippet to get the number of rows (without a NULL value) of a column.
getCreateConstraintSQL()  : string
Returns the SQL to create a constraint on a table on this platform.
getCreateDatabaseSQL()  : string
Returns the SQL to create a new database.
getCreateForeignKeySQL()  : string
Returns the SQL to create a new foreign key.
getCreateIndexSQL()  : string
Returns the SQL to create an index on a table on this platform.
getCreatePrimaryKeySQL()  : string
Returns the SQL to create an unnamed primary key constraint.
getCreateSchemaSQL()  : string
Returns the SQL to create a named schema.
getCreateSequenceSQL()  : string
Returns the SQL to create a sequence on this platform.
getCreateTableSQL()  : array<int, string>
Returns the SQL statement(s) to create a table with the specified name, columns and constraints on this platform.
getCreateTablesSQL()  : array<int, string>
getCreateTemporaryTableSnippetSQL()  : string
getCreateUniqueConstraintSQL()  : string
Returns the SQL to create a unique constraint on a table on this platform.
getCreateViewSQL()  : string
getCurrentDatabaseExpression()  : string
Returns the SQL expression which represents the currently selected database.
getCurrentDateSQL()  : string
Returns the SQL specific for the platform to get the current date.
getCurrentTimeSQL()  : string
Returns the SQL specific for the platform to get the current time.
getCurrentTimestampSQL()  : string
Returns the SQL specific for the platform to get the current timestamp
getCustomTypeDeclarationSQL()  : string
Obtains SQL code portion needed to create a custom column, e.g. when a column has the "columnDefinition" keyword.
getDateAddDaysExpression()  : string
Returns the SQL to add the number of given days to a date.
getDateAddHourExpression()  : string
Returns the SQL to add the number of given hours to a date.
getDateAddMinutesExpression()  : string
Returns the SQL to add the number of given minutes to a date.
getDateAddMonthExpression()  : string
Returns the SQL to add the number of given months to a date.
getDateAddQuartersExpression()  : string
Returns the SQL to add the number of given quarters to a date.
getDateAddSecondsExpression()  : string
Returns the SQL to add the number of given seconds to a date.
getDateAddWeeksExpression()  : string
Returns the SQL to add the number of given weeks to a date.
getDateAddYearsExpression()  : string
Returns the SQL to add the number of given years to a date.
getDateDiffExpression()  : string
Returns the SQL to calculate the difference in days between the two passed dates.
getDateFormatString()  : string
Gets the format string, as accepted by the date() function, that describes the format of a stored date value of this platform.
getDateSubDaysExpression()  : string
Returns the SQL to subtract the number of given days to a date.
getDateSubHourExpression()  : string
Returns the SQL to subtract the number of given hours to a date.
getDateSubMinutesExpression()  : string
Returns the SQL to subtract the number of given minutes from a date.
getDateSubMonthExpression()  : string
Returns the SQL to subtract the number of given months to a date.
getDateSubQuartersExpression()  : string
Returns the SQL to subtract the number of given quarters from a date.
getDateSubSecondsExpression()  : string
Returns the SQL to subtract the number of given seconds from a date.
getDateSubWeeksExpression()  : string
Returns the SQL to subtract the number of given weeks from a date.
getDateSubYearsExpression()  : string
Returns the SQL to subtract the number of given years from a date.
getDateTimeFormatString()  : string
Gets the format string, as accepted by the date() function, that describes the format of a stored datetime value of this platform.
getDateTimeTypeDeclarationSQL()  : string
Obtains DBMS specific SQL to be used to create datetime columns in statements like CREATE TABLE.
getDateTimeTzFormatString()  : string
Gets the format string, as accepted by the date() function, that describes the format of a stored datetime with timezone value of this platform.
getDateTimeTzTypeDeclarationSQL()  : string
Obtains DBMS specific SQL to be used to create datetime with timezone offset columns.
getDateTypeDeclarationSQL()  : string
Obtains DBMS specific SQL to be used to create date columns in statements like CREATE TABLE.
getDecimalTypeDeclarationSQL()  : string
Returns the SQL snippet that declares a floating point column of arbitrary precision.
getDefaultSchemaName()  : string
Returns the default schema name.
getDefaultTransactionIsolationLevel()  : TransactionIsolationLevel::*
Gets the default transaction isolation level of the platform.
getDefaultValueDeclarationSQL()  : string
Obtains DBMS specific SQL code portion needed to set a default value declaration to be used in statements like CREATE TABLE.
getDoctrineTypeComment()  : string
Gets the comment to append to a column comment that helps parsing this type in reverse engineering.
getDoctrineTypeMapping()  : string
Gets the Doctrine type that is mapped for the given database column type.
getDropDatabaseSQL()  : string
Returns the SQL snippet to drop an existing database.
getDropForeignKeySQL()  : string
Returns the SQL to drop a foreign key.
getDropIndexSQL()  : string
Returns the SQL to drop an index from a table.
getDropSchemaSQL()  : string
Returns the SQL snippet to drop a schema.
getDropSequenceSQL()  : string
Returns the SQL snippet to drop an existing sequence.
getDropTableSQL()  : string
Returns the SQL snippet to drop an existing table.
getDropTablesSQL()  : array<int, string>
getDropTemporaryTableSQL()  : string
Returns the SQL to safely drop a temporary table WITHOUT implicitly committing an open transaction.
getDropUniqueConstraintSQL()  : string
Returns the SQL to drop a unique constraint.
getDropViewSQL()  : string
getDummySelectSQL()  : string
This is for test reasons, many vendors have special requirements for dummy statements.
getEmptyIdentityInsertSQL()  : string
Returns the insert SQL for an empty insert statement.
getEventManager()  : EventManager|null
Gets the EventManager used by the Platform.
getFloatDeclarationSQL()  : string
getForeignKeyBaseDeclarationSQL()  : string
Obtains DBMS specific SQL code portion needed to set the FOREIGN KEY constraint of a column declaration to be used in statements like CREATE TABLE.
getForeignKeyDeclarationSQL()  : string
Obtain DBMS specific SQL code portion needed to set the FOREIGN KEY constraint of a column declaration to be used in statements like CREATE TABLE.
getForeignKeyReferentialActionSQL()  : string
Returns the given referential action in uppercase if valid, otherwise throws an exception.
getForUpdateSQL()  : string
Returns the FOR UPDATE expression.
getGuidTypeDeclarationSQL()  : string
Returns the SQL snippet to declare a GUID/UUID column.
getIdentifierQuoteCharacter()  : string
Gets the character used for identifier quoting.
getIdentitySequenceName()  : string
Returns the name of the sequence for a particular identity column in a particular table.
getIndexDeclarationSQL()  : string
Obtains DBMS specific SQL code portion needed to set an index declaration to be used in statements like CREATE TABLE.
getIndexFieldDeclarationListSQL()  : string
Obtains DBMS specific SQL code portion needed to set an index declaration to be used in statements like CREATE TABLE.
getInlineColumnCommentSQL()  : string
Returns the SQL to create inline comment on a column.
getIntegerTypeDeclarationSQL()  : string
Returns the SQL snippet that declares a 4 byte integer column.
getIsNotNullExpression()  : string
Returns the SQL that checks if an expression is not null.
getIsNullExpression()  : string
Returns the SQL that checks if an expression is null.
getJsonTypeDeclarationSQL()  : string
Returns the SQL snippet to declare a JSON column.
getLengthExpression()  : string
Returns the SQL snippet to get the length of a text column in characters.
getListNamespacesSQL()  : string
Returns the SQL statement for retrieving the namespaces defined in the database.
getListTableColumnsSQL()  : string
getListTableCommentsSQL()  : string
getListTableConstraintsSQL()  : string
getListTableForeignKeysSQL()  : string
getListTableIndexesSQL()  : string
getListTablesSQL()  : string
getListUsersSQL()  : string
getLocateExpression()  : string
Returns the SQL snippet to get the position of the first occurrence of substring $substr in string $str.
getLowerExpression()  : string
Returns the SQL snippet to change all characters from the expression to lowercase, according to the current character set mapping.
getLtrimExpression()  : string
Returns the SQL snippet to trim leading space characters from the expression.
getMaxExpression()  : string
Returns the SQL snippet to get the highest value of a column.
getMaxIdentifierLength()  : int
Maximum length of any given database identifier, like tables or column names.
getMd5Expression()  : string
Returns the SQL snippet to get the md5 sum of a column.
getMinExpression()  : string
Returns the SQL snippet to get the lowest value of a column.
getModExpression()  : string
Returns the SQL snippet to get the remainder of the division operation $expression1 / $expression2.
getName()  : string
Gets the name of the platform.
getNotExpression()  : string
Returns the SQL for a logical not.
getNowExpression()  : string
Returns the SQL snippet to get the current system date.
getPiExpression()  : string
Returns the SQL to get the PI value.
getReadLockSQL()  : string
Returns the SQL snippet to append to any SELECT statement which locks rows in shared read lock.
getRegexpExpression()  : string
Returns the regular expression operator.
getRenameTableSQL()  : array<int, string>
getReservedKeywordsList()  : KeywordList
Returns the keyword list instance of this platform.
getRoundExpression()  : string
Returns the SQL snippet to round a numeric column to the number of decimals specified.
getRtrimExpression()  : string
Returns the SQL snippet to trim trailing space characters from the expression.
getSequenceNextValSQL()  : string
getSetTransactionIsolationSQL()  : string
Returns the SQL to set the transaction isolation level.
getSinExpression()  : string
Returns the SQL to get the sine of a value.
getSmallIntTypeDeclarationSQL()  : string
Returns the SQL snippet that declares a 2 byte integer column.
getSqlCommentEndString()  : string
Gets the string portion that ends an SQL comment.
getSqlCommentStartString()  : string
Gets the string portion that starts an SQL comment.
getSqrtExpression()  : string
Returns the SQL snippet to get the squared value of a column.
getStringLiteralQuoteCharacter()  : string
Gets the character used for string literal quoting.
getStringTypeDeclarationSQL()  : string
Returns the SQL snippet used to declare a string column type.
getSubstringExpression()  : string
Returns a SQL snippet to get a substring inside an SQL statement.
getSumExpression()  : string
Returns the SQL snippet to get the total sum of a column.
getTemporaryTableName()  : string
Some vendors require temporary table names to be qualified specially.
getTemporaryTableSQL()  : string
Returns the required SQL string that fits between CREATE ... TABLE to create the table as a temporary table.
getTimeFormatString()  : string
Gets the format string, as accepted by the date() function, that describes the format of a stored time value of this platform.
getTimeTypeDeclarationSQL()  : string
Obtains DBMS specific SQL to be used to create time columns in statements like CREATE TABLE.
getTrimExpression()  : string
Returns the SQL snippet to trim a string.
getTruncateTableSQL()  : string
Generates a Truncate Table SQL statement for a given table.
getUniqueConstraintDeclarationSQL()  : string
Obtains DBMS specific SQL code portion needed to set a unique constraint declaration to be used in statements like CREATE TABLE.
getUniqueFieldDeclarationSQL()  : string
Obtains DBMS specific SQL code portion needed to set the UNIQUE constraint of a column declaration to be used in statements like CREATE TABLE.
getUpperExpression()  : string
Returns the SQL snippet to change all characters from the expression to uppercase, according to the current character set mapping.
getVarcharDefaultLength()  : int
Gets the default length of a varchar column.
getVarcharMaxLength()  : int
Gets the maximum length of a varchar column.
getVarcharTypeDeclarationSQL()  : string
Returns the SQL snippet used to declare a VARCHAR column type.
getWildcards()  : array<string|int, string>
Gets all SQL wildcard characters of the platform.
getWriteLockSQL()  : string
Returns the SQL snippet to append to any SELECT statement which obtains an exclusive lock on the rows.
hasDoctrineTypeMappingFor()  : bool
Checks if a database type is currently supported by this platform.
hasNativeGuidType()  : bool
Does this platform have native guid type.
hasNativeJsonType()  : bool
Does this platform have native JSON type.
isCommentedDoctrineType()  : bool
Is it necessary for the platform to add a parsable type comment to allow reverse engineering the given type?
markDoctrineTypeCommented()  : void
Marks this type as to be commented in ALTER TABLE and CREATE TABLE statements.
modifyLimitQuery()  : string
Adds an driver-specific LIMIT clause to the query.
prefersIdentityColumns()  : bool
Whether the platform prefers identity columns (eg. autoincrement) for ID generation.
quoteIdentifier()  : string
Quotes a string so that it can be safely used as a table or column name, even if it is a reserved word of the platform. This also detects identifier chains separated by dot and quotes them independently.
quoteSingleIdentifier()  : string
Quotes a single identifier (no dot chain separation).
quoteStringLiteral()  : string
Quotes a literal string.
registerDoctrineTypeMapping()  : void
Registers a doctrine type to be used in conjunction with a column type of this platform.
releaseSavePoint()  : string
Returns the SQL to release a savepoint.
rollbackSavePoint()  : string
Returns the SQL to rollback a savepoint.
setEventManager()  : void
Sets the EventManager used by the Platform.
supportsAlterTable()  : bool
Whether the platform supports altering tables.
supportsColumnCollation()  : bool
Does this platform support column collation?
supportsColumnLengthIndexes()  : bool
Whether the platform supports indexes with column length definitions.
supportsCommentOnStatement()  : bool
Whether this platform support the proprietary syntax "COMMENT ON asset".
supportsCreateDropDatabase()  : bool
Whether this platform supports create database.
supportsForeignKeyConstraints()  : bool
Whether the platform supports foreign key constraints.
supportsGettingAffectedRows()  : bool
Whether the platform supports getting the affected rows of a recent update/delete type query.
supportsIdentityColumns()  : bool
Whether the platform supports identity columns.
supportsIndexes()  : bool
Whether the platform supports indexes.
supportsInlineColumnComments()  : bool
Whether this platform support to add inline column comments as postfix.
supportsLimitOffset()  : bool
Whether the database platform support offsets in modify limit clauses.
supportsPartialIndexes()  : bool
Whether the platform supports partial indexes.
supportsPrimaryConstraints()  : bool
Whether the platform supports primary key constraints.
supportsReleaseSavepoints()  : bool
Whether the platform supports releasing savepoints.
supportsSavepoints()  : bool
Whether the platform supports savepoints.
supportsSchemas()  : bool
Whether the platform supports database schemas.
supportsSequences()  : bool
Whether the platform supports sequences.
supportsTransactions()  : bool
Whether the platform supports transactions.
supportsViews()  : bool
Whether this platform supports views.
usesSequenceEmulatedIdentityColumns()  : bool
Whether the platform emulates identity columns through sequences.
_getCommonIntegerTypeDeclarationSQL()  : string
Returns the SQL snippet that declares common properties of an integer column.
_getCreateTableSQL()  : array<string|int, string>
Returns the SQL used to create a table.
_getTransactionIsolationLevelSQL()  : string
Returns the SQL for a given transaction isolation level Connection constant.
createReservedKeywordsList()  : KeywordList
Creates an instance of the reserved keyword list of this platform.
doModifyLimitQuery()  : string
Adds an platform-specific LIMIT clause to the query.
getBinaryTypeDeclarationSQLSnippet()  : string
Returns the SQL snippet used to declare a BINARY/VARBINARY column type.
getColumnComment()  : string|null
Gets the comment of a passed column modified by potential doctrine type comment hints.
getCommentOnTableSQL()  : string
getCreateIndexSQLFlags()  : string
Adds additional flags for index generation.
getDateArithmeticIntervalExpression()  : string
Returns the SQL for a date arithmetic expression.
getLikeWildcardCharacters()  : string
getPartialIndexSQL()  : string
Adds condition for partial index.
getPostAlterTableIndexForeignKeySQL()  : array<string|int, string>
getPreAlterTableIndexForeignKeySQL()  : array<string|int, string>
getRenameIndexSQL()  : array<string|int, string>
Returns the SQL for renaming an index on a table.
getReservedKeywordsClass()  : string
Returns the class name of the reserved keywords list.
getVarcharTypeDeclarationSQLSnippet()  : string
initializeCommentedDoctrineTypes()  : void
Initializes the Doctrine Type comments instance variable for in_array() checks.
initializeDoctrineTypeMappings()  : void
Lazy load Doctrine Type Mappings.
onSchemaAlterTable()  : bool
onSchemaAlterTableAddColumn()  : bool
onSchemaAlterTableChangeColumn()  : bool
onSchemaAlterTableRemoveColumn()  : bool
onSchemaAlterTableRenameColumn()  : bool
addSuffix()  : string
Adds suffix to identifier,
buildCreateTableSQL()  : array<int, string>
columnToArray()  : array<string, mixed>
getAutoincrementIdentifierName()  : string
Returns the autoincrement primary key identifier name for the given table identifier.
getSequenceCacheSQL()  : string
Cache definition for sequences
initializeAllDoctrineTypeMappings()  : void
Initializes Doctrine Type Mappings with the platform defaults and with all additional type mappings.
normalizeIdentifier()  : Identifier
Normalizes the given identifier.

Constants

Properties

$doctrineTypeComments

Contains a list of all columns that should generate parseable column comments for type-detection in reverse engineering scenarios.

protected array<string|int, string>|null $doctrineTypeComments
Tags
deprecated

This property is deprecated and will be removed in Doctrine DBAL 4.0.

$doctrineTypeMapping

protected array<string|int, string>|null $doctrineTypeMapping

Methods

appendLockHint()

Honors that some SQL vendors such as MsSql use table hints for locking instead of the ANSI SQL FOR UPDATE specification.

public appendLockHint(string $fromClause, int $lockMode) : string
Parameters
$fromClause : string

The FROM clause to append the hint for the given lock mode to

$lockMode : int

One of the Doctrine\DBAL\LockMode::* constants

Tags
psalm-param

LockMode::* $lockMode

Return values
string

canEmulateSchemas()

Whether this platform can emulate schemas.

public canEmulateSchemas() : bool
Tags
deprecated

Platforms that either support or emulate schemas don't automatically filter a schema for the namespaced elements in AbstractManager::introspectSchema().

Return values
bool

columnsEqual()

Compares the definitions of the given columns in the context of this platform.

public columnsEqual(Column $column1, Column $column2) : bool
Parameters
$column1 : Column
$column2 : Column
Tags
throws
Exception
Return values
bool

convertBooleans()

Some platforms need the boolean values to be converted.

public convertBooleans(mixed $item) : mixed

The default conversion in this implementation converts to integers (false => 0, true => 1).

Note: if the input is not a boolean the original input might be returned.

There are two contexts when converting booleans: Literals and Prepared Statements. This method should handle the literal case

Parameters
$item : mixed

A boolean or an array of them.

Return values
mixed

A boolean database value or an array of them.

convertBooleansToDatabaseValue()

This method should handle the prepared statements case. When there is no distinction, it's OK to use the same method.

public convertBooleansToDatabaseValue(mixed $item) : mixed

Note: if the input is not a boolean the original input might be returned.

Parameters
$item : mixed

A boolean or an array of them.

Return values
mixed

A boolean database value or an array of them.

convertFromBoolean()

Some platforms have boolean literals that needs to be correctly converted

public convertFromBoolean(T $item) : mixed

The default conversion tries to convert value into bool "(bool)$item"

Parameters
$item : T
Tags
template

T

createSavePoint()

Returns the SQL to create a new savepoint.

public createSavePoint(string $savepoint) : string
Parameters
$savepoint : string
Return values
string

createSchemaManager()

Creates the schema manager that can be used to inspect and change the underlying database schema according to the dialect of the platform.

public createSchemaManager(Connection $connection) : OracleSchemaManager
Parameters
$connection : Connection
Return values
OracleSchemaManager

escapeStringForLike()

Escapes metacharacters in a string intended to be used with a LIKE operator.

public final escapeStringForLike(string $inputString, string $escapeChar) : string
Parameters
$inputString : string

a literal, unquoted string

$escapeChar : string

should be reused by the caller in the LIKE expression.

Return values
string

getAcosExpression()

Returns the SQL to get the arccosine of a value.

public getAcosExpression(string $value) : string
Parameters
$value : string
Tags
deprecated

Use ACOS() in SQL instead.

Return values
string

getAdvancedForeignKeyOptionsSQL()

Returns the FOREIGN KEY query section dealing with non-standard options as MATCH, INITIALLY DEFERRED, ON UPDATE, .

public getAdvancedForeignKeyOptionsSQL(ForeignKeyConstraint $foreignKey) : string

..

Parameters
$foreignKey : ForeignKeyConstraint

The foreign key definition.

Return values
string

getAlterSchemaSQL()

Generates SQL statements that can be used to apply the diff.

public getAlterSchemaSQL(SchemaDiff $diff) : array<int, string>
Parameters
$diff : SchemaDiff
Return values
array<int, string>

getAlterSequenceSQL()

Returns the SQL to change a sequence on this platform.

public getAlterSequenceSQL(Sequence $sequence) : string
Parameters
$sequence : Sequence
Return values
string

getAlterTableSQL()

Gets the SQL statements for altering an existing table.

public getAlterTableSQL(TableDiff $diff) : array<int, string>
Parameters
$diff : TableDiff
Return values
array<int, string>

getAsciiStringTypeDeclarationSQL()

Returns the SQL snippet used to declare a column that can store characters in the ASCII character set

public getAsciiStringTypeDeclarationSQL(array<string|int, mixed> $column) : string
Parameters
$column : array<string|int, mixed>
Return values
string

getAvgExpression()

Returns the SQL snippet to get the average value of a column.

public getAvgExpression(string $column) : string
Parameters
$column : string

The column to use.

Tags
deprecated

Use AVG() in SQL instead.

Return values
string

Generated SQL including an AVG aggregate function.

getBetweenExpression()

Returns the SQL that checks if an expression evaluates to a value between two values.

public getBetweenExpression(string $expression, string $value1, string $value2) : string

The parameter $expression is checked if it is between $value1 and $value2.

Note: There is a slight difference in the way BETWEEN works on some databases. http://www.w3schools.com/sql/sql_between.asp. If you want complete database independence you should avoid using between().

Parameters
$expression : string

The value to compare to.

$value1 : string

The lower value to compare with.

$value2 : string

The higher value to compare with.

Tags
deprecated

Use BETWEEN in SQL instead.

Return values
string

The logical expression.

getBigIntTypeDeclarationSQL()

Returns the SQL snippet that declares an 8 byte integer column.

public getBigIntTypeDeclarationSQL(array<string|int, mixed> $column) : string
Parameters
$column : array<string|int, mixed>
Return values
string

getBinaryDefaultLength()

Gets the default length of a binary column.

public getBinaryDefaultLength() : int
Tags
deprecated
Return values
int

getBinaryMaxLength()

Gets the maximum length of a binary column.

public getBinaryMaxLength() : int
Tags
deprecated
Return values
int

getBinaryTypeDeclarationSQL()

Returns the SQL snippet used to declare a BINARY/VARBINARY column type.

public getBinaryTypeDeclarationSQL(array<string|int, mixed> $column) : string
Parameters
$column : array<string|int, mixed>

The column definition.

Return values
string

getBitAndComparisonExpression()

Returns the SQL bit AND comparison expression.

public getBitAndComparisonExpression(mixed $value1, mixed $value2) : string
Parameters
$value1 : mixed
$value2 : mixed
Return values
string

getBitOrComparisonExpression()

Returns the SQL bit OR comparison expression.

public getBitOrComparisonExpression(mixed $value1, mixed $value2) : string
Parameters
$value1 : mixed
$value2 : mixed
Return values
string

getBlobTypeDeclarationSQL()

Returns the SQL Snippet used to declare a BLOB column type.

public getBlobTypeDeclarationSQL(array<string|int, mixed> $column) : string
Parameters
$column : array<string|int, mixed>
Return values
string

getBooleanTypeDeclarationSQL()

Returns the SQL snippet that declares a boolean column.

public getBooleanTypeDeclarationSQL(array<string|int, mixed> $column) : string
Parameters
$column : array<string|int, mixed>
Return values
string

getCharMaxLength()

Gets the maximum length of a char column.

public getCharMaxLength() : int
Tags
deprecated
Return values
int

getCheckDeclarationSQL()

Obtains DBMS specific SQL code portion needed to set a CHECK constraint declaration to be used in statements like CREATE TABLE.

public getCheckDeclarationSQL(array<string|int, string>|array<string|int, array<string|int, mixed>> $definition) : string
Parameters
$definition : array<string|int, string>|array<string|int, array<string|int, mixed>>

The check definition.

Return values
string

DBMS specific SQL code portion needed to set a CHECK constraint.

getClobTypeDeclarationSQL()

Returns the SQL snippet used to declare a CLOB column type.

public getClobTypeDeclarationSQL(array<string|int, mixed> $column) : string
Parameters
$column : array<string|int, mixed>
Return values
string

getColumnCharsetDeclarationSQL()

Obtains DBMS specific SQL code portion needed to set the CHARACTER SET of a column declaration to be used in statements like CREATE TABLE.

public getColumnCharsetDeclarationSQL(string $charset) : string
Parameters
$charset : string

The name of the charset.

Return values
string

DBMS specific SQL code portion needed to set the CHARACTER SET of a column declaration.

getColumnCollationDeclarationSQL()

Obtains DBMS specific SQL code portion needed to set the COLLATION of a column declaration to be used in statements like CREATE TABLE.

public getColumnCollationDeclarationSQL(string $collation) : string
Parameters
$collation : string

The name of the collation.

Return values
string

DBMS specific SQL code portion needed to set the COLLATION of a column declaration.

getColumnDeclarationListSQL()

Gets declaration of a number of columns in bulk.

public getColumnDeclarationListSQL(array<string|int, array<string|int, mixed>> $columns) : string
Parameters
$columns : array<string|int, array<string|int, mixed>>

A multidimensional associative array. The first dimension determines the column name, while the second dimension is keyed with the name of the properties of the column being declared as array indexes. Currently, the types of supported column properties are as follows:

length Integer value that determines the maximum length of the text column. If this argument is missing the column should be declared to have the longest length allowed by the DBMS.

default Text value to be used as default for this column.

notnull Boolean flag that indicates whether this column is constrained to not be set to null. charset Text value with the default CHARACTER SET for this column. collation Text value with the default COLLATION for this column. unique unique constraint

Return values
string

getColumnDeclarationSQL()

Obtains DBMS specific SQL code portion needed to declare a generic type column to be used in statements like CREATE TABLE.

public getColumnDeclarationSQL(string $name, array<string|int, mixed> $column) : string
Parameters
$name : string

The name the column to be declared.

$column : array<string|int, mixed>

An associative array with the name of the properties of the column being declared as array indexes. Currently, the types of supported column properties are as follows:

length Integer value that determines the maximum length of the text column. If this argument is missing the column should be declared to have the longest length allowed by the DBMS.

default Text value to be used as default for this column.

notnull Boolean flag that indicates whether this column is constrained to not be set to null. charset Text value with the default CHARACTER SET for this column. collation Text value with the default COLLATION for this column. unique unique constraint check column check constraint columnDefinition a string that defines the complete column

Tags
throws
Exception
Return values
string

DBMS specific SQL code portion that should be used to declare the column.

getColumnsFieldDeclarationListSQL()

Obtains DBMS specific SQL code portion needed to set an index declaration to be used in statements like CREATE TABLE.

public getColumnsFieldDeclarationListSQL(array<string|int, mixed> $columns) : string
Parameters
$columns : array<string|int, mixed>
Tags
deprecated
Return values
string

getCommentOnColumnSQL()

public getCommentOnColumnSQL(string $tableName, string $columnName, string|null $comment) : string
Parameters
$tableName : string
$columnName : string
$comment : string|null
Return values
string

getConcatExpression()

Returns a SQL snippet to concatenate the given expressions.

public getConcatExpression() : string

Accepts an arbitrary number of string parameters. Each parameter must contain an expression.

Return values
string

getCosExpression()

Returns the SQL to get the cosine of a value.

public getCosExpression(string $value) : string
Parameters
$value : string
Tags
deprecated

Use COS() in SQL instead.

Return values
string

getCountExpression()

Returns the SQL snippet to get the number of rows (without a NULL value) of a column.

public getCountExpression(string|int $column) : string

If a '*' is used instead of a column the number of selected rows is returned.

Parameters
$column : string|int

The column to use.

Tags
deprecated

Use COUNT() in SQL instead.

Return values
string

Generated SQL including a COUNT aggregate function.

getCreateConstraintSQL()

Returns the SQL to create a constraint on a table on this platform.

public getCreateConstraintSQL(Constraint $constraint, Table|string $table) : string
Parameters
$constraint : Constraint
$table : Table|string
Tags
deprecated

Use getCreateIndexSQL(), getCreateForeignKeySQL() or getCreateUniqueConstraintSQL() instead.

throws
InvalidArgumentException
Return values
string

getCreateDatabaseSQL()

Returns the SQL to create a new database.

public getCreateDatabaseSQL(mixed $name) : string
Parameters
$name : mixed

The name of the database that should be created.

Return values
string

getCreateForeignKeySQL()

Returns the SQL to create a new foreign key.

public getCreateForeignKeySQL(ForeignKeyConstraint $foreignKey, Table|string $table) : string
Parameters
$foreignKey : ForeignKeyConstraint

The foreign key constraint.

$table : Table|string

The name of the table on which the foreign key is to be created.

Return values
string

getCreateIndexSQL()

Returns the SQL to create an index on a table on this platform.

public getCreateIndexSQL(Index $index, Table|string $table) : string
Parameters
$index : Index
$table : Table|string

The name of the table on which the index is to be created.

Tags
throws
InvalidArgumentException
Return values
string

getCreatePrimaryKeySQL()

Returns the SQL to create an unnamed primary key constraint.

public getCreatePrimaryKeySQL(Index $index, mixed $table) : string
Parameters
$index : Index
$table : mixed
Return values
string

getCreateSchemaSQL()

Returns the SQL to create a named schema.

public getCreateSchemaSQL(string $schemaName) : string
Parameters
$schemaName : string
Tags
throws
Exception

If not supported on this platform.

Return values
string

getCreateSequenceSQL()

Returns the SQL to create a sequence on this platform.

public getCreateSequenceSQL(Sequence $sequence) : string

Need to specifiy minvalue, since start with is hidden in the system and MINVALUE <= START WITH. Therefore we can use MINVALUE to be able to get a hint what START WITH was for later introspection in listSequences()

Parameters
$sequence : Sequence
Return values
string

getCreateTableSQL()

Returns the SQL statement(s) to create a table with the specified name, columns and constraints on this platform.

public getCreateTableSQL(Table $table[, int $createFlags = self::CREATE_INDEXES ]) : array<int, string>
Parameters
$table : Table
$createFlags : int = self::CREATE_INDEXES
Tags
psalm-param

int-mask-ofself::CREATE_* $createFlags

throws
Exception
throws
InvalidArgumentException
Return values
array<int, string>

The list of SQL statements.

getCreateTablesSQL()

public getCreateTablesSQL(array<int, Table$tables) : array<int, string>
Parameters
$tables : array<int, Table>
Tags
throws
Exception
Return values
array<int, string>

getCreateTemporaryTableSnippetSQL()

public getCreateTemporaryTableSnippetSQL() : string
Return values
string

getCreateUniqueConstraintSQL()

Returns the SQL to create a unique constraint on a table on this platform.

public getCreateUniqueConstraintSQL(UniqueConstraint $constraint, string $tableName) : string
Parameters
$constraint : UniqueConstraint
$tableName : string
Return values
string

getCreateViewSQL()

public getCreateViewSQL(string $name, string $sql) : string
Parameters
$name : string
$sql : string
Return values
string

getCurrentDatabaseExpression()

Returns the SQL expression which represents the currently selected database.

public getCurrentDatabaseExpression() : string
Return values
string

getCurrentDateSQL()

Returns the SQL specific for the platform to get the current date.

public getCurrentDateSQL() : string
Return values
string

getCurrentTimeSQL()

Returns the SQL specific for the platform to get the current time.

public getCurrentTimeSQL() : string
Return values
string

getCurrentTimestampSQL()

Returns the SQL specific for the platform to get the current timestamp

public getCurrentTimestampSQL() : string
Return values
string

getCustomTypeDeclarationSQL()

Obtains SQL code portion needed to create a custom column, e.g. when a column has the "columnDefinition" keyword.

public getCustomTypeDeclarationSQL(array<string|int, mixed> $column) : string

Only "AUTOINCREMENT" and "PRIMARY KEY" are added if appropriate.

Parameters
$column : array<string|int, mixed>
Tags
deprecated
Return values
string

getDateAddDaysExpression()

Returns the SQL to add the number of given days to a date.

public getDateAddDaysExpression(string $date, int|numeric-string $days) : string
Parameters
$date : string
$days : int|numeric-string
Tags
throws
Exception

If not supported on this platform.

Return values
string

getDateAddHourExpression()

Returns the SQL to add the number of given hours to a date.

public getDateAddHourExpression(string $date, int|numeric-string $hours) : string
Parameters
$date : string
$hours : int|numeric-string
Tags
throws
Exception

If not supported on this platform.

Return values
string

getDateAddMinutesExpression()

Returns the SQL to add the number of given minutes to a date.

public getDateAddMinutesExpression(string $date, int|numeric-string $minutes) : string
Parameters
$date : string
$minutes : int|numeric-string
Tags
throws
Exception

If not supported on this platform.

Return values
string

getDateAddMonthExpression()

Returns the SQL to add the number of given months to a date.

public getDateAddMonthExpression(string $date, int|numeric-string $months) : string
Parameters
$date : string
$months : int|numeric-string
Tags
throws
Exception

If not supported on this platform.

Return values
string

getDateAddQuartersExpression()

Returns the SQL to add the number of given quarters to a date.

public getDateAddQuartersExpression(string $date, int|numeric-string $quarters) : string
Parameters
$date : string
$quarters : int|numeric-string
Tags
throws
Exception

If not supported on this platform.

Return values
string

getDateAddSecondsExpression()

Returns the SQL to add the number of given seconds to a date.

public getDateAddSecondsExpression(string $date, int|numeric-string $seconds) : string
Parameters
$date : string
$seconds : int|numeric-string
Tags
throws
Exception

If not supported on this platform.

Return values
string

getDateAddWeeksExpression()

Returns the SQL to add the number of given weeks to a date.

public getDateAddWeeksExpression(string $date, int|numeric-string $weeks) : string
Parameters
$date : string
$weeks : int|numeric-string
Tags
throws
Exception

If not supported on this platform.

Return values
string

getDateAddYearsExpression()

Returns the SQL to add the number of given years to a date.

public getDateAddYearsExpression(string $date, int|numeric-string $years) : string
Parameters
$date : string
$years : int|numeric-string
Tags
throws
Exception

If not supported on this platform.

Return values
string

getDateDiffExpression()

Returns the SQL to calculate the difference in days between the two passed dates.

public getDateDiffExpression(mixed $date1, mixed $date2) : string
Parameters
$date1 : mixed
$date2 : mixed
Return values
string

getDateFormatString()

Gets the format string, as accepted by the date() function, that describes the format of a stored date value of this platform.

public getDateFormatString() : string
Return values
string

The format string.

getDateSubDaysExpression()

Returns the SQL to subtract the number of given days to a date.

public getDateSubDaysExpression(string $date, int|numeric-string $days) : string
Parameters
$date : string
$days : int|numeric-string
Tags
throws
Exception

If not supported on this platform.

Return values
string

getDateSubHourExpression()

Returns the SQL to subtract the number of given hours to a date.

public getDateSubHourExpression(string $date, int|numeric-string $hours) : string
Parameters
$date : string
$hours : int|numeric-string
Tags
throws
Exception

If not supported on this platform.

Return values
string

getDateSubMinutesExpression()

Returns the SQL to subtract the number of given minutes from a date.

public getDateSubMinutesExpression(string $date, int|numeric-string $minutes) : string
Parameters
$date : string
$minutes : int|numeric-string
Tags
throws
Exception

If not supported on this platform.

Return values
string

getDateSubMonthExpression()

Returns the SQL to subtract the number of given months to a date.

public getDateSubMonthExpression(string $date, int|numeric-string $months) : string
Parameters
$date : string
$months : int|numeric-string
Tags
throws
Exception

If not supported on this platform.

Return values
string

getDateSubQuartersExpression()

Returns the SQL to subtract the number of given quarters from a date.

public getDateSubQuartersExpression(string $date, int|numeric-string $quarters) : string
Parameters
$date : string
$quarters : int|numeric-string
Tags
throws
Exception

If not supported on this platform.

Return values
string

getDateSubSecondsExpression()

Returns the SQL to subtract the number of given seconds from a date.

public getDateSubSecondsExpression(string $date, int|numeric-string $seconds) : string
Parameters
$date : string
$seconds : int|numeric-string
Tags
throws
Exception

If not supported on this platform.

Return values
string

getDateSubWeeksExpression()

Returns the SQL to subtract the number of given weeks from a date.

public getDateSubWeeksExpression(string $date, int|numeric-string $weeks) : string
Parameters
$date : string
$weeks : int|numeric-string
Tags
throws
Exception

If not supported on this platform.

Return values
string

getDateSubYearsExpression()

Returns the SQL to subtract the number of given years from a date.

public getDateSubYearsExpression(string $date, int|numeric-string $years) : string
Parameters
$date : string
$years : int|numeric-string
Tags
throws
Exception

If not supported on this platform.

Return values
string

getDateTimeFormatString()

Gets the format string, as accepted by the date() function, that describes the format of a stored datetime value of this platform.

public getDateTimeFormatString() : string
Return values
string

The format string.

getDateTimeTypeDeclarationSQL()

Obtains DBMS specific SQL to be used to create datetime columns in statements like CREATE TABLE.

public getDateTimeTypeDeclarationSQL(array<string|int, mixed> $column) : string
Parameters
$column : array<string|int, mixed>
Return values
string

getDateTimeTzFormatString()

Gets the format string, as accepted by the date() function, that describes the format of a stored datetime with timezone value of this platform.

public getDateTimeTzFormatString() : string
Return values
string

The format string.

getDateTimeTzTypeDeclarationSQL()

Obtains DBMS specific SQL to be used to create datetime with timezone offset columns.

public getDateTimeTzTypeDeclarationSQL(array<string|int, mixed> $column) : string
Parameters
$column : array<string|int, mixed>
Return values
string

getDateTypeDeclarationSQL()

Obtains DBMS specific SQL to be used to create date columns in statements like CREATE TABLE.

public getDateTypeDeclarationSQL(array<string|int, mixed> $column) : string
Parameters
$column : array<string|int, mixed>
Return values
string

getDecimalTypeDeclarationSQL()

Returns the SQL snippet that declares a floating point column of arbitrary precision.

public getDecimalTypeDeclarationSQL(array<string|int, mixed> $column) : string
Parameters
$column : array<string|int, mixed>
Return values
string

getDefaultSchemaName()

Returns the default schema name.

public getDefaultSchemaName() : string
Tags
deprecated
throws
Exception

If not supported on this platform.

Return values
string

getDefaultTransactionIsolationLevel()

Gets the default transaction isolation level of the platform.

public getDefaultTransactionIsolationLevel() : TransactionIsolationLevel::*
Tags
see
TransactionIsolationLevel
Return values
TransactionIsolationLevel::*

The default isolation level.

getDefaultValueDeclarationSQL()

Obtains DBMS specific SQL code portion needed to set a default value declaration to be used in statements like CREATE TABLE.

public getDefaultValueDeclarationSQL(array<string|int, mixed> $column) : string
Parameters
$column : array<string|int, mixed>

The column definition array.

Return values
string

DBMS specific SQL code portion needed to set a default value.

getDoctrineTypeComment()

Gets the comment to append to a column comment that helps parsing this type in reverse engineering.

public getDoctrineTypeComment(Type $doctrineType) : string
Parameters
$doctrineType : Type
Tags
deprecated

This method will be removed without replacement.

Return values
string

getDoctrineTypeMapping()

Gets the Doctrine type that is mapped for the given database column type.

public getDoctrineTypeMapping(string $dbType) : string
Parameters
$dbType : string
Tags
throws
Exception
Return values
string

getDropDatabaseSQL()

Returns the SQL snippet to drop an existing database.

public getDropDatabaseSQL(mixed $name) : string
Parameters
$name : mixed

The name of the database that should be dropped.

Return values
string

getDropForeignKeySQL()

Returns the SQL to drop a foreign key.

public getDropForeignKeySQL(mixed $foreignKey, mixed $table) : string
Parameters
$foreignKey : mixed
$table : mixed
Return values
string

getDropIndexSQL()

Returns the SQL to drop an index from a table.

public getDropIndexSQL(Index|string $index[, Table|string|null $table = null ]) : string
Parameters
$index : Index|string
$table : Table|string|null = null
Tags
throws
InvalidArgumentException
Return values
string

getDropSchemaSQL()

Returns the SQL snippet to drop a schema.

public getDropSchemaSQL(string $schemaName) : string
Parameters
$schemaName : string
Tags
throws
Exception

If not supported on this platform.

Return values
string

getDropSequenceSQL()

Returns the SQL snippet to drop an existing sequence.

public getDropSequenceSQL(Sequence|string $sequence) : string
Parameters
$sequence : Sequence|string
Tags
throws
Exception

If not supported on this platform.

Return values
string

getDropTableSQL()

Returns the SQL snippet to drop an existing table.

public getDropTableSQL(Table|string $table) : string
Parameters
$table : Table|string
Tags
throws
InvalidArgumentException
Return values
string

getDropTablesSQL()

public getDropTablesSQL(array<int, Table$tables) : array<int, string>
Parameters
$tables : array<int, Table>
Return values
array<int, string>

getDropTemporaryTableSQL()

Returns the SQL to safely drop a temporary table WITHOUT implicitly committing an open transaction.

public getDropTemporaryTableSQL(Table|string $table) : string
Parameters
$table : Table|string
Return values
string

getDropUniqueConstraintSQL()

Returns the SQL to drop a unique constraint.

public getDropUniqueConstraintSQL(string $name, string $tableName) : string
Parameters
$name : string
$tableName : string
Return values
string

getDropViewSQL()

public getDropViewSQL(string $name) : string
Parameters
$name : string
Return values
string

getDummySelectSQL()

This is for test reasons, many vendors have special requirements for dummy statements.

public getDummySelectSQL() : string
Return values
string

getEmptyIdentityInsertSQL()

Returns the insert SQL for an empty insert statement.

public getEmptyIdentityInsertSQL(string $quotedTableName, string $quotedIdentifierColumnName) : string
Parameters
$quotedTableName : string
$quotedIdentifierColumnName : string
Return values
string

getFloatDeclarationSQL()

public getFloatDeclarationSQL(array<string|int, mixed> $column) : string
Parameters
$column : array<string|int, mixed>
Return values
string

getForeignKeyBaseDeclarationSQL()

Obtains DBMS specific SQL code portion needed to set the FOREIGN KEY constraint of a column declaration to be used in statements like CREATE TABLE.

public getForeignKeyBaseDeclarationSQL(ForeignKeyConstraint $foreignKey) : string
Parameters
$foreignKey : ForeignKeyConstraint
Tags
throws
InvalidArgumentException
Return values
string

getForeignKeyDeclarationSQL()

Obtain DBMS specific SQL code portion needed to set the FOREIGN KEY constraint of a column declaration to be used in statements like CREATE TABLE.

public getForeignKeyDeclarationSQL(ForeignKeyConstraint $foreignKey) : string
Parameters
$foreignKey : ForeignKeyConstraint
Return values
string

DBMS specific SQL code portion needed to set the FOREIGN KEY constraint of a column declaration.

getForeignKeyReferentialActionSQL()

Returns the given referential action in uppercase if valid, otherwise throws an exception.

public getForeignKeyReferentialActionSQL(string $action) : string
Parameters
$action : string

The foreign key referential action.

Tags
throws
InvalidArgumentException

If unknown referential action given.

Return values
string

getForUpdateSQL()

Returns the FOR UPDATE expression.

public getForUpdateSQL() : string
Return values
string

getGuidTypeDeclarationSQL()

Returns the SQL snippet to declare a GUID/UUID column.

public getGuidTypeDeclarationSQL(array<string|int, mixed> $column) : string

By default this maps directly to a CHAR(36) and only maps to more special datatypes when the underlying databases support this datatype.

Parameters
$column : array<string|int, mixed>
Return values
string

getIdentifierQuoteCharacter()

Gets the character used for identifier quoting.

public getIdentifierQuoteCharacter() : string
Tags
deprecated

Use quoteIdentifier() to quote identifiers instead.

Return values
string

getIdentitySequenceName()

Returns the name of the sequence for a particular identity column in a particular table.

public getIdentitySequenceName(string $tableName, string $columnName) : string
Parameters
$tableName : string

The name of the table to return the sequence name for.

$columnName : string

The name of the identity column in the table to return the sequence name for.

Tags
deprecated
see
usesSequenceEmulatedIdentityColumns
throws
Exception

If not supported on this platform.

Return values
string

getIndexDeclarationSQL()

Obtains DBMS specific SQL code portion needed to set an index declaration to be used in statements like CREATE TABLE.

public getIndexDeclarationSQL(string $name, Index $index) : string
Parameters
$name : string

The name of the index.

$index : Index

The index definition.

Tags
throws
InvalidArgumentException
Return values
string

DBMS specific SQL code portion needed to set an index.

getIndexFieldDeclarationListSQL()

Obtains DBMS specific SQL code portion needed to set an index declaration to be used in statements like CREATE TABLE.

public getIndexFieldDeclarationListSQL(Index $index) : string
Parameters
$index : Index
Tags
deprecated
Return values
string

getInlineColumnCommentSQL()

Returns the SQL to create inline comment on a column.

public getInlineColumnCommentSQL(string $comment) : string
Parameters
$comment : string
Tags
throws
Exception

If not supported on this platform.

Return values
string

getIntegerTypeDeclarationSQL()

Returns the SQL snippet that declares a 4 byte integer column.

public getIntegerTypeDeclarationSQL(array<string|int, mixed> $column) : string
Parameters
$column : array<string|int, mixed>
Return values
string

getIsNotNullExpression()

Returns the SQL that checks if an expression is not null.

public getIsNotNullExpression(string $expression) : string
Parameters
$expression : string

The expression that should be compared to null.

Tags
deprecated

Use IS NOT NULL in SQL instead.

Return values
string

The logical expression.

getIsNullExpression()

Returns the SQL that checks if an expression is null.

public getIsNullExpression(string $expression) : string
Parameters
$expression : string

The expression that should be compared to null.

Tags
deprecated

Use IS NULL in SQL instead.

Return values
string

The logical expression.

getJsonTypeDeclarationSQL()

Returns the SQL snippet to declare a JSON column.

public getJsonTypeDeclarationSQL(array<string|int, mixed> $column) : string

By default this maps directly to a CLOB and only maps to more special datatypes when the underlying databases support this datatype.

Parameters
$column : array<string|int, mixed>
Return values
string

getLengthExpression()

Returns the SQL snippet to get the length of a text column in characters.

public getLengthExpression(string $column) : string
Parameters
$column : string
Return values
string

getListTableColumnsSQL()

public getListTableColumnsSQL(mixed $table[, mixed $database = null ]) : string
Parameters
$table : mixed
$database : mixed = null
Tags
deprecated

The SQL used for schema introspection is an implementation detail and should not be relied upon.

Return values
string

getListTableCommentsSQL()

public getListTableCommentsSQL(string $table[, string|null $database = null ]) : string
Parameters
$table : string
$database : string|null = null
Tags
deprecated

The SQL used for schema introspection is an implementation detail and should not be relied upon.

Return values
string

getListTableConstraintsSQL()

public getListTableConstraintsSQL(mixed $table) : string
Parameters
$table : mixed
Tags
deprecated
Return values
string

getListTableForeignKeysSQL()

public getListTableForeignKeysSQL(mixed $table) : string
Parameters
$table : mixed
Tags
deprecated

The SQL used for schema introspection is an implementation detail and should not be relied upon.

Return values
string

getListTablesSQL()

public getListTablesSQL() : string
Tags
deprecated

The SQL used for schema introspection is an implementation detail and should not be relied upon.

Return values
string

getListUsersSQL()

public getListUsersSQL() : string
Tags
deprecated
throws
Exception

If not supported on this platform.

Return values
string

getLocateExpression()

Returns the SQL snippet to get the position of the first occurrence of substring $substr in string $str.

public getLocateExpression(mixed $str, mixed $substr[, mixed $startPos = false ]) : string
Parameters
$str : mixed

Literal string.

$substr : mixed

Literal string to find.

$startPos : mixed = false

Position to start at, beginning of string by default.

Return values
string

getLowerExpression()

Returns the SQL snippet to change all characters from the expression to lowercase, according to the current character set mapping.

public getLowerExpression(string $str) : string
Parameters
$str : string

Literal string or column name.

Tags
deprecated

Use LOWER() in SQL instead.

Return values
string

getLtrimExpression()

Returns the SQL snippet to trim leading space characters from the expression.

public getLtrimExpression(string $str) : string
Parameters
$str : string

Literal string or column name.

Tags
deprecated

Use LTRIM() in SQL instead.

Return values
string

getMaxExpression()

Returns the SQL snippet to get the highest value of a column.

public getMaxExpression(string $column) : string
Parameters
$column : string

The column to use.

Tags
deprecated

Use MAX() in SQL instead.

Return values
string

Generated SQL including a MAX aggregate function.

getMaxIdentifierLength()

Maximum length of any given database identifier, like tables or column names.

public getMaxIdentifierLength() : int
Return values
int

getMd5Expression()

Returns the SQL snippet to get the md5 sum of a column.

public getMd5Expression(string $column) : string

Note: Not SQL92, but common functionality.

Parameters
$column : string
Tags
deprecated
Return values
string

getMinExpression()

Returns the SQL snippet to get the lowest value of a column.

public getMinExpression(string $column) : string
Parameters
$column : string

The column to use.

Tags
deprecated

Use MIN() in SQL instead.

Return values
string

Generated SQL including a MIN aggregate function.

getModExpression()

Returns the SQL snippet to get the remainder of the division operation $expression1 / $expression2.

public getModExpression(string $expression1, string $expression2) : string
Parameters
$expression1 : string
$expression2 : string
Return values
string

getName()

Gets the name of the platform.

public getName() : string
Return values
string

getNotExpression()

Returns the SQL for a logical not.

public getNotExpression(string $expression) : string

Example: $q = new Doctrine_Query(); $e = $q->expr; $q->select('*')->from('table') ->where($e->eq('id', $e->not('null'));

Parameters
$expression : string
Tags
deprecated

Use NOT() in SQL instead.

Return values
string

The logical expression.

getNowExpression()

Returns the SQL snippet to get the current system date.

public getNowExpression([string $type = 'timestamp' ]) : string
Parameters
$type : string = 'timestamp'
Tags
deprecated

Generate dates within the application.

Return values
string

getPiExpression()

Returns the SQL to get the PI value.

public getPiExpression() : string
Tags
deprecated

Use PI() in SQL instead.

Return values
string

getReadLockSQL()

Returns the SQL snippet to append to any SELECT statement which locks rows in shared read lock.

public getReadLockSQL() : string

This defaults to the ANSI SQL "FOR UPDATE", which is an exclusive lock (Write). Some database vendors allow to lighten this constraint up to be a real read lock.

Return values
string

getRegexpExpression()

Returns the regular expression operator.

public getRegexpExpression() : string
Tags
throws
Exception

If not supported on this platform.

Return values
string

getRenameTableSQL()

public getRenameTableSQL(string $oldName, string $newName) : array<int, string>
Parameters
$oldName : string
$newName : string
Return values
array<int, string>

getRoundExpression()

Returns the SQL snippet to round a numeric column to the number of decimals specified.

public getRoundExpression(string $column[, string|int $decimals = 0 ]) : string
Parameters
$column : string
$decimals : string|int = 0
Tags
deprecated

Use ROUND() in SQL instead.

Return values
string

getRtrimExpression()

Returns the SQL snippet to trim trailing space characters from the expression.

public getRtrimExpression(string $str) : string
Parameters
$str : string

Literal string or column name.

Tags
deprecated

Use RTRIM() in SQL instead.

Return values
string

getSequenceNextValSQL()

public getSequenceNextValSQL(mixed $sequence) : string
Parameters
$sequence : mixed
Return values
string

getSetTransactionIsolationSQL()

Returns the SQL to set the transaction isolation level.

public getSetTransactionIsolationSQL(mixed $level) : string
Parameters
$level : mixed
Return values
string

getSinExpression()

Returns the SQL to get the sine of a value.

public getSinExpression(string $value) : string
Parameters
$value : string
Tags
deprecated

Use SIN() in SQL instead.

Return values
string

getSmallIntTypeDeclarationSQL()

Returns the SQL snippet that declares a 2 byte integer column.

public getSmallIntTypeDeclarationSQL(array<string|int, mixed> $column) : string
Parameters
$column : array<string|int, mixed>
Return values
string

getSqlCommentEndString()

Gets the string portion that ends an SQL comment.

public getSqlCommentEndString() : string
Tags
deprecated
Return values
string

getSqlCommentStartString()

Gets the string portion that starts an SQL comment.

public getSqlCommentStartString() : string
Tags
deprecated
Return values
string

getSqrtExpression()

Returns the SQL snippet to get the squared value of a column.

public getSqrtExpression(string $column) : string
Parameters
$column : string

The column to use.

Tags
deprecated

Use SQRT() in SQL instead.

Return values
string

Generated SQL including an SQRT aggregate function.

getStringLiteralQuoteCharacter()

Gets the character used for string literal quoting.

public getStringLiteralQuoteCharacter() : string
Tags
deprecated

Use quoteStringLiteral() to quote string literals instead.

Return values
string

getStringTypeDeclarationSQL()

Returns the SQL snippet used to declare a string column type.

public getStringTypeDeclarationSQL(array<string|int, mixed> $column) : string
Parameters
$column : array<string|int, mixed>
Return values
string

getSubstringExpression()

Returns a SQL snippet to get a substring inside an SQL statement.

public getSubstringExpression(mixed $string, mixed $start[, mixed $length = null ]) : string
Parameters
$string : mixed

An sql string literal or column name/alias.

$start : mixed

Where to start the substring portion.

$length : mixed = null

The substring portion length.

Return values
string

getSumExpression()

Returns the SQL snippet to get the total sum of a column.

public getSumExpression(string $column) : string
Parameters
$column : string

The column to use.

Tags
deprecated

Use SUM() in SQL instead.

Return values
string

Generated SQL including a SUM aggregate function.

getTemporaryTableName()

Some vendors require temporary table names to be qualified specially.

public getTemporaryTableName(string $tableName) : string
Parameters
$tableName : string
Return values
string

getTemporaryTableSQL()

Returns the required SQL string that fits between CREATE ... TABLE to create the table as a temporary table.

public getTemporaryTableSQL() : string

Should be overridden in driver classes to return the correct string for the specific database type.

The default is to return the string "TEMPORARY" - this will result in a SQL error for any database that does not support temporary tables, or that requires a different SQL command from "CREATE TEMPORARY TABLE".

Tags
deprecated
Return values
string

The string required to be placed between "CREATE" and "TABLE" to generate a temporary table, if possible.

getTimeFormatString()

Gets the format string, as accepted by the date() function, that describes the format of a stored time value of this platform.

public getTimeFormatString() : string
Return values
string

The format string.

getTimeTypeDeclarationSQL()

Obtains DBMS specific SQL to be used to create time columns in statements like CREATE TABLE.

public getTimeTypeDeclarationSQL(array<string|int, mixed> $column) : string
Parameters
$column : array<string|int, mixed>
Return values
string

getTrimExpression()

Returns the SQL snippet to trim a string.

public getTrimExpression(string $str[, int $mode = TrimMode::UNSPECIFIED ][, string|bool $char = false ]) : string
Parameters
$str : string

The expression to apply the trim to.

$mode : int = TrimMode::UNSPECIFIED

The position of the trim (leading/trailing/both).

$char : string|bool = false

The char to trim, has to be quoted already. Defaults to space.

Return values
string

getTruncateTableSQL()

Generates a Truncate Table SQL statement for a given table.

public getTruncateTableSQL(mixed $tableName[, mixed $cascade = false ]) : string
Parameters
$tableName : mixed
$cascade : mixed = false
Return values
string

getUniqueConstraintDeclarationSQL()

Obtains DBMS specific SQL code portion needed to set a unique constraint declaration to be used in statements like CREATE TABLE.

public getUniqueConstraintDeclarationSQL(string $name, UniqueConstraint $constraint) : string
Parameters
$name : string

The name of the unique constraint.

$constraint : UniqueConstraint

The unique constraint definition.

Tags
throws
InvalidArgumentException
Return values
string

DBMS specific SQL code portion needed to set a constraint.

getUniqueFieldDeclarationSQL()

Obtains DBMS specific SQL code portion needed to set the UNIQUE constraint of a column declaration to be used in statements like CREATE TABLE.

public getUniqueFieldDeclarationSQL() : string
Tags
deprecated

Use UNIQUE in SQL instead.

Return values
string

DBMS specific SQL code portion needed to set the UNIQUE constraint of a column declaration.

getUpperExpression()

Returns the SQL snippet to change all characters from the expression to uppercase, according to the current character set mapping.

public getUpperExpression(string $str) : string
Parameters
$str : string

Literal string or column name.

Tags
deprecated

Use UPPER() in SQL instead.

Return values
string

getVarcharDefaultLength()

Gets the default length of a varchar column.

public getVarcharDefaultLength() : int
Tags
deprecated
Return values
int

getVarcharMaxLength()

Gets the maximum length of a varchar column.

public getVarcharMaxLength() : int
Tags
deprecated
Return values
int

getVarcharTypeDeclarationSQL()

Returns the SQL snippet used to declare a VARCHAR column type.

public getVarcharTypeDeclarationSQL(array<string|int, mixed> $column) : string
Parameters
$column : array<string|int, mixed>
Tags
deprecated

Use instead.

Return values
string

getWriteLockSQL()

Returns the SQL snippet to append to any SELECT statement which obtains an exclusive lock on the rows.

public getWriteLockSQL() : string

The semantics of this lock mode should equal the SELECT .. FOR UPDATE of the ANSI SQL standard.

Return values
string

hasDoctrineTypeMappingFor()

Checks if a database type is currently supported by this platform.

public hasDoctrineTypeMappingFor(string $dbType) : bool
Parameters
$dbType : string
Return values
bool

hasNativeGuidType()

Does this platform have native guid type.

public hasNativeGuidType() : bool
Tags
deprecated
Return values
bool

hasNativeJsonType()

Does this platform have native JSON type.

public hasNativeJsonType() : bool
Tags
deprecated
Return values
bool

isCommentedDoctrineType()

Is it necessary for the platform to add a parsable type comment to allow reverse engineering the given type?

public isCommentedDoctrineType(Type $doctrineType) : bool
Parameters
$doctrineType : Type
Tags
deprecated

Use instead.

Return values
bool

markDoctrineTypeCommented()

Marks this type as to be commented in ALTER TABLE and CREATE TABLE statements.

public markDoctrineTypeCommented(string|Type $doctrineType) : void
Parameters
$doctrineType : string|Type

modifyLimitQuery()

Adds an driver-specific LIMIT clause to the query.

public final modifyLimitQuery(string $query, int|null $limit[, int $offset = 0 ]) : string
Parameters
$query : string
$limit : int|null
$offset : int = 0
Tags
throws
Exception
Return values
string

prefersIdentityColumns()

Whether the platform prefers identity columns (eg. autoincrement) for ID generation.

public prefersIdentityColumns() : bool

Subclasses should override this method to return TRUE if they prefer identity columns.

Tags
deprecated
Return values
bool

quoteIdentifier()

Quotes a string so that it can be safely used as a table or column name, even if it is a reserved word of the platform. This also detects identifier chains separated by dot and quotes them independently.

public quoteIdentifier(string $str) : string

NOTE: Just because you CAN use quoted identifiers doesn't mean you SHOULD use them. In general, they end up causing way more problems than they solve.

Parameters
$str : string

The identifier name to be quoted.

Return values
string

The quoted identifier string.

quoteSingleIdentifier()

Quotes a single identifier (no dot chain separation).

public quoteSingleIdentifier(string $str) : string
Parameters
$str : string

The identifier name to be quoted.

Return values
string

The quoted identifier string.

quoteStringLiteral()

Quotes a literal string.

public quoteStringLiteral(string $str) : string

This method is NOT meant to fix SQL injections! It is only meant to escape this platform's string literal quote character inside the given literal string.

Parameters
$str : string

The literal string to be quoted.

Return values
string

The quoted literal string.

registerDoctrineTypeMapping()

Registers a doctrine type to be used in conjunction with a column type of this platform.

public registerDoctrineTypeMapping(string $dbType, string $doctrineType) : void
Parameters
$dbType : string
$doctrineType : string
Tags
throws
Exception

If the type is not found.

releaseSavePoint()

Returns the SQL to release a savepoint.

public releaseSavePoint(mixed $savepoint) : string
Parameters
$savepoint : mixed
Return values
string

rollbackSavePoint()

Returns the SQL to rollback a savepoint.

public rollbackSavePoint(string $savepoint) : string
Parameters
$savepoint : string
Return values
string

supportsAlterTable()

Whether the platform supports altering tables.

public supportsAlterTable() : bool
Tags
deprecated

All platforms must implement altering tables.

Return values
bool

supportsColumnCollation()

Does this platform support column collation?

public supportsColumnCollation() : bool
Return values
bool

supportsColumnLengthIndexes()

Whether the platform supports indexes with column length definitions.

public supportsColumnLengthIndexes() : bool
Return values
bool

supportsCommentOnStatement()

Whether this platform support the proprietary syntax "COMMENT ON asset".

public supportsCommentOnStatement() : bool
Return values
bool

supportsCreateDropDatabase()

Whether this platform supports create database.

public supportsCreateDropDatabase() : bool

Some databases don't allow to create and drop databases at all or only with certain tools.

Tags
deprecated
Return values
bool

supportsForeignKeyConstraints()

Whether the platform supports foreign key constraints.

public supportsForeignKeyConstraints() : bool
Tags
deprecated

All platforms should support foreign key constraints.

Return values
bool

supportsGettingAffectedRows()

Whether the platform supports getting the affected rows of a recent update/delete type query.

public supportsGettingAffectedRows() : bool
Tags
deprecated
Return values
bool

supportsIdentityColumns()

Whether the platform supports identity columns.

public supportsIdentityColumns() : bool

Identity columns are columns that receive an auto-generated value from the database on insert of a row.

Return values
bool

supportsIndexes()

Whether the platform supports indexes.

public supportsIndexes() : bool
Tags
deprecated
Return values
bool

supportsInlineColumnComments()

Whether this platform support to add inline column comments as postfix.

public supportsInlineColumnComments() : bool
Return values
bool

supportsLimitOffset()

Whether the database platform support offsets in modify limit clauses.

public supportsLimitOffset() : bool
Tags
deprecated

All platforms must implement support for offsets in modify limit clauses.

Return values
bool

supportsPartialIndexes()

Whether the platform supports partial indexes.

public supportsPartialIndexes() : bool
Return values
bool

supportsPrimaryConstraints()

Whether the platform supports primary key constraints.

public supportsPrimaryConstraints() : bool
Tags
deprecated
Return values
bool

supportsReleaseSavepoints()

Whether the platform supports releasing savepoints.

public supportsReleaseSavepoints() : bool
Return values
bool

supportsSavepoints()

Whether the platform supports savepoints.

public supportsSavepoints() : bool
Return values
bool

supportsSchemas()

Whether the platform supports database schemas.

public supportsSchemas() : bool
Return values
bool

supportsSequences()

Whether the platform supports sequences.

public supportsSequences() : bool
Return values
bool

supportsTransactions()

Whether the platform supports transactions.

public supportsTransactions() : bool
Tags
deprecated
Return values
bool

supportsViews()

Whether this platform supports views.

public supportsViews() : bool
Tags
deprecated

All platforms must implement support for views.

Return values
bool

usesSequenceEmulatedIdentityColumns()

Whether the platform emulates identity columns through sequences.

public usesSequenceEmulatedIdentityColumns() : bool
Tags
deprecated
Return values
bool

_getCommonIntegerTypeDeclarationSQL()

Returns the SQL snippet that declares common properties of an integer column.

protected _getCommonIntegerTypeDeclarationSQL(array<string|int, mixed> $column) : string
Parameters
$column : array<string|int, mixed>
Return values
string

_getCreateTableSQL()

Returns the SQL used to create a table.

protected _getCreateTableSQL(mixed $name, array<string|int, mixed> $columns[, array<string|int, mixed> $options = [] ]) : array<string|int, string>
Parameters
$name : mixed
$columns : array<string|int, mixed>
$options : array<string|int, mixed> = []
Return values
array<string|int, string>

_getTransactionIsolationLevelSQL()

Returns the SQL for a given transaction isolation level Connection constant.

protected _getTransactionIsolationLevelSQL(mixed $level) : string
Parameters
$level : mixed
Return values
string

createReservedKeywordsList()

Creates an instance of the reserved keyword list of this platform.

protected createReservedKeywordsList() : KeywordList

This method will become @abstract in DBAL 4.0.0.

Tags
throws
Exception
Return values
KeywordList

doModifyLimitQuery()

Adds an platform-specific LIMIT clause to the query.

protected doModifyLimitQuery(mixed $query, mixed $limit, mixed $offset) : string
Parameters
$query : mixed
$limit : mixed
$offset : mixed
Return values
string

getBinaryTypeDeclarationSQLSnippet()

Returns the SQL snippet used to declare a BINARY/VARBINARY column type.

protected getBinaryTypeDeclarationSQLSnippet(mixed $length, mixed $fixed) : string
Parameters
$length : mixed

The length of the column.

$fixed : mixed

Whether the column length is fixed.

Return values
string

getColumnComment()

Gets the comment of a passed column modified by potential doctrine type comment hints.

protected getColumnComment(Column $column) : string|null
Parameters
$column : Column
Tags
deprecated

This method will be removed without replacement.

Return values
string|null

getCommentOnTableSQL()

protected getCommentOnTableSQL(string $tableName, string|null $comment) : string
Parameters
$tableName : string
$comment : string|null
Return values
string

getCreateIndexSQLFlags()

Adds additional flags for index generation.

protected getCreateIndexSQLFlags(Index $index) : string
Parameters
$index : Index
Return values
string

getDateArithmeticIntervalExpression()

Returns the SQL for a date arithmetic expression.

protected getDateArithmeticIntervalExpression(mixed $date, mixed $operator, mixed $interval, mixed $unit) : string
Parameters
$date : mixed

The column or literal representing a date to perform the arithmetic operation on.

$operator : mixed

The arithmetic operator (+ or -).

$interval : mixed

The interval that shall be calculated into the date.

$unit : mixed

The unit of the interval that shall be calculated into the date. One of the DateIntervalUnit constants.

Return values
string

getLikeWildcardCharacters()

protected getLikeWildcardCharacters() : string
Return values
string

getPartialIndexSQL()

Adds condition for partial index.

protected getPartialIndexSQL(Index $index) : string
Parameters
$index : Index
Return values
string

getPostAlterTableIndexForeignKeySQL()

protected getPostAlterTableIndexForeignKeySQL(TableDiff $diff) : array<string|int, string>
Parameters
$diff : TableDiff
Return values
array<string|int, string>

getPreAlterTableIndexForeignKeySQL()

protected getPreAlterTableIndexForeignKeySQL(TableDiff $diff) : array<string|int, string>
Parameters
$diff : TableDiff
Return values
array<string|int, string>

getRenameIndexSQL()

Returns the SQL for renaming an index on a table.

protected getRenameIndexSQL(mixed $oldIndexName, Index $index, mixed $tableName) : array<string|int, string>
Parameters
$oldIndexName : mixed

The name of the index to rename from.

$index : Index

The definition of the index to rename to.

$tableName : mixed

The table to rename the given index on.

Return values
array<string|int, string>

The sequence of SQL statements for renaming the given index.

getReservedKeywordsClass()

Returns the class name of the reserved keywords list.

protected getReservedKeywordsClass() : string
Tags
deprecated

Implement createReservedKeywordsList() instead.

Return values
string

getVarcharTypeDeclarationSQLSnippet()

protected getVarcharTypeDeclarationSQLSnippet(mixed $length, mixed $fixed) : string
Parameters
$length : mixed
$fixed : mixed
Return values
string

initializeCommentedDoctrineTypes()

Initializes the Doctrine Type comments instance variable for in_array() checks.

protected initializeCommentedDoctrineTypes() : void
Tags
deprecated

This API will be removed in Doctrine DBAL 4.0.

initializeDoctrineTypeMappings()

Lazy load Doctrine Type Mappings.

protected initializeDoctrineTypeMappings() : void

onSchemaAlterTable()

protected onSchemaAlterTable(TableDiff $diff, array<string|int, string> &$sql) : bool
Parameters
$diff : TableDiff
$sql : array<string|int, string>
Return values
bool

onSchemaAlterTableAddColumn()

protected onSchemaAlterTableAddColumn(Column $column, TableDiff $diff, array<string|int, mixed> &$columnSql) : bool
Parameters
$column : Column
$diff : TableDiff
$columnSql : array<string|int, mixed>
Return values
bool

onSchemaAlterTableChangeColumn()

protected onSchemaAlterTableChangeColumn(ColumnDiff $columnDiff, TableDiff $diff, array<string|int, string> &$columnSql) : bool
Parameters
$columnDiff : ColumnDiff
$diff : TableDiff
$columnSql : array<string|int, string>
Return values
bool

onSchemaAlterTableRemoveColumn()

protected onSchemaAlterTableRemoveColumn(Column $column, TableDiff $diff, array<string|int, string> &$columnSql) : bool
Parameters
$column : Column
$diff : TableDiff
$columnSql : array<string|int, string>
Return values
bool

onSchemaAlterTableRenameColumn()

protected onSchemaAlterTableRenameColumn(string $oldColumnName, Column $column, TableDiff $diff, array<string|int, string> &$columnSql) : bool
Parameters
$oldColumnName : string
$column : Column
$diff : TableDiff
$columnSql : array<string|int, string>
Return values
bool

addSuffix()

Adds suffix to identifier,

private addSuffix(string $identifier, string $suffix) : string

if the new string exceeds max identifier length, keeps $suffix, cuts from $identifier as much as the part exceeding.

Parameters
$identifier : string
$suffix : string
Return values
string

buildCreateTableSQL()

private buildCreateTableSQL(Table $table, bool $createIndexes, bool $createForeignKeys) : array<int, string>
Parameters
$table : Table
$createIndexes : bool
$createForeignKeys : bool
Tags
throws
Exception
Return values
array<int, string>

columnToArray()

private columnToArray(Column $column) : array<string, mixed>
Parameters
$column : Column
Return values
array<string, mixed>

An associative array with the name of the properties of the column being declared as array indexes.

getAutoincrementIdentifierName()

Returns the autoincrement primary key identifier name for the given table identifier.

private getAutoincrementIdentifierName(Identifier $table) : string

Quotes the autoincrement primary key identifier name if the given table name is quoted by intention.

Parameters
$table : Identifier
Return values
string

getSequenceCacheSQL()

Cache definition for sequences

private getSequenceCacheSQL(Sequence $sequence) : string
Parameters
$sequence : Sequence
Return values
string

initializeAllDoctrineTypeMappings()

Initializes Doctrine Type Mappings with the platform defaults and with all additional type mappings.

private initializeAllDoctrineTypeMappings() : void

normalizeIdentifier()

Normalizes the given identifier.

private normalizeIdentifier(string $name) : Identifier

Uppercases the given identifier if it is not quoted by intention to reflect Oracle's internal auto uppercasing strategy of unquoted identifiers.

Parameters
$name : string

The identifier to normalize.

Return values
Identifier

        
On this page

Search results