Doctrine\DBAL\Platforms\SqlitePlatform
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 35
Class SqlitePlatform
Class:SqlitePlatform - Superclass: AbstractPlatform
AbstractPlatform
⌊ SqlitePlatform
public class SqlitePlatform
extends AbstractPlatform
- Since:
- 2.0
- Author:
- Roman Borschel
- Benjamin Eberlei
- Todo:
- Rename: SQLitePlatform
- License:
- http://www.opensource.org/licenses/lgpl-license.php LGPL
- See Also:
www.doctrine-project.org
- Version:
- $Revision: 3938 $
Method Summary |
string |
getBigIntTypeDeclarationSQL(mixed field, array columnDef) |
string |
getBooleanTypeDeclarationSQL(mixed field, array columnDef) |
void |
getClobTypeDeclarationSQL(array field) Gets the SQL snippet used to declare a CLOB column type. |
void |
getCreateViewSQL(mixed name, mixed sql) |
string |
getDateTimeTypeDeclarationSQL(array fieldDeclaration) |
string |
getDateTypeDeclarationSQL(array fieldDeclaration) |
void |
getDropViewSQL(mixed name) |
string |
getIntegerTypeDeclarationSQL(mixed field, array columnDef) |
void |
getListTableColumnsSQL(mixed table) |
void |
getListTableConstraintsSQL(mixed table) |
void |
getListTableIndexesSQL(mixed table) |
void |
getListTablesSQL() |
string |
getListViewsSQL(string database) Get the SQL to list all views of a database or user. |
integer |
getLocateExpression(string str, string substr, mixed startPos, int pos) returns the position of the first occurrence of substring $substr in string $str |
void |
getMediumIntTypeDeclarationSql(mixed field) |
string |
getName() Get the platform name for this instance |
string |
getNowExpression(mixed type) Return string to call a variable with the current timestamp inside an SQL statement
There are three special variables for current date and time. |
string |
getRegexpExpression() returns the regular expression operator |
void |
getSetTransactionIsolationSQL(integer level) Get sql to set the transaction isolation level |
string |
getSmallIntTypeDeclarationSQL(mixed field, array columnDef) |
string |
getSubstringExpression(string value, integer position, integer length, integer from, integer len) return string to call a function to get a substring inside an SQL statementNote: Not SQL92, but common functionality.
|
string |
getTimeTypeDeclarationSQL(array fieldDeclaration) |
void |
getTinyIntTypeDeclarationSql(mixed field) |
string |
getTrimExpression(string str, int pos, string char) Trim a string, leading/trailing/both and with a given char which defaults to space. |
string |
getTruncateTableSQL(string tableName, bool cascade) |
void |
getVarcharTypeDeclarationSQL(array field) {@inheritdoc} |
boolean |
prefersIdentityColumns() |
void |
supportsAlterTable() |
boolean |
supportsForeignKeyConstraints() SQLite does support foreign key constraints, but only in CREATE TABLE statements...
|
static void |
udfLocate(string str, string substr, int offset) |
static void |
udfMod(mixed a, mixed b) User-defined function for Sqlite that implements MOD(a, b) |
static float |
udfSqrt(int|float value) User-defined function for Sqlite that is used with PDO::sqliteCreateFunction() |
Methods inherited from Doctrine\DBAL\Platforms\AbstractPlatform |
convertBooleans, createsExplicitIndexForForeignKeys, fixSchemaElementName, getAcosExpression, getAdvancedForeignKeyOptionsSQL, getAlterTableSQL, getAvgExpression, getBetweenExpression, getBigIntTypeDeclarationSQL, getBooleanTypeDeclarationSQL, getCheckDeclarationSQL, getClobTypeDeclarationSQL, getColumnCharsetDeclarationSQL, getColumnCollationDeclarationSQL, getColumnDeclarationListSQL, getColumnDeclarationSQL, getConcatExpression, getCosExpression, getCountExpression, getCreateConstraintSQL, getCreateDatabaseSQL, getCreateForeignKeySQL, getCreateIndexSQL, getCreateSequenceSQL, getCreateTableSQL, getCreateTemporaryTableSnippetSQL, getCreateViewSQL, getCurrentDateSQL, getCurrentTimeSQL, getCurrentTimestampSQL, getCustomTypeDeclarationSQL, getDateFormatString, getDateTimeFormatString, getDateTimeTypeDeclarationSQL, getDateTypeDeclarationSQL, getDecimalTypeDeclarationSQL, getDefaultTransactionIsolationLevel, getDefaultValueDeclarationSQL, getDropConstraintSQL, getDropDatabaseSQL, getDropForeignKeySQL, getDropIndexSQL, getDropSequenceSQL, getDropTableSQL, getDropViewSQL, getEmptyIdentityInsertSQL, getForUpdateSql, getForeignKeyBaseDeclarationSQL, getForeignKeyDeclarationSQL, getForeignKeyReferentialActionSQL, getIdentifierQuoteCharacter, getIdentityColumnNullInsertSQL, getInExpression, getIndexDeclarationSQL, getIndexFieldDeclarationListSQL, getIntegerTypeDeclarationSQL, getIsNotNullExpression, getIsNullExpression, getLengthExpression, getListDatabasesSQL, getListSequencesSQL, getListTableColumnsSQL, getListTableConstraintsSQL, getListTableForeignKeysSQL, getListTableIndexesSQL, getListTablesSQL, getListUsersSQL, getListViewsSQL, getLocateExpression, getLowerExpression, getLtrimExpression, getMaxExpression, getMaxIdentifierLength, getMd5Expression, getMinExpression, getModExpression, getName, getNotExpression, getNowExpression, getPiExpression, getRegexpExpression, getRoundExpression, getRtrimExpression, getSQLResultCasing, getSequenceNextValSQL, getSetCharsetSQL, getSetTransactionIsolationSQL, getShowDatabasesSQL, getSinExpression, getSmallIntTypeDeclarationSQL, getSqlCommentEndString, getSqlCommentStartString, getSubstringExpression, getSumExpression, getTemporaryTableSQL, getTimeFormatString, getTimeTypeDeclarationSQL, getTrimExpression, getTruncateTableSQL, getUniqueConstraintDeclarationSQL, getUniqueFieldDeclarationSQL, getUpperExpression, getVarcharMaxLength, getVarcharTypeDeclarationSQL, getWildcards, modifyLimitQuery, prefersIdentityColumns, prefersSequences, quoteIdentifier, supportsAlterTable, supportsForeignKeyConstraints, supportsForeignKeyOnUpdate, supportsGettingAffectedRows, supportsIdentityColumns, supportsIndexes, supportsPrimaryConstraints, supportsSavepoints, supportsSchemas, supportsSequences, supportsTransactions |
Method Detail
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 176
getBigIntTypeDeclarationSQL
public string getBigIntTypeDeclarationSQL(mixed field, array columnDef)
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 160
getBooleanTypeDeclarationSQL
public string getBooleanTypeDeclarationSQL(mixed field, array columnDef)
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 321
getClobTypeDeclarationSQL
public void getClobTypeDeclarationSQL(array field)
Gets the SQL snippet used to declare a CLOB column type.
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 353
getCreateViewSQL
public void getCreateViewSQL(mixed name, mixed sql)
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 208
getDateTimeTypeDeclarationSQL
public string getDateTimeTypeDeclarationSQL(array fieldDeclaration)
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 216
getDateTypeDeclarationSQL
public string getDateTypeDeclarationSQL(array fieldDeclaration)
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 358
getDropViewSQL
public void getDropViewSQL(mixed name)
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 168
getIntegerTypeDeclarationSQL
public string getIntegerTypeDeclarationSQL(mixed field, array columnDef)
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 331
getListTableColumnsSQL
public void getListTableColumnsSQL(mixed table)
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 326
getListTableConstraintsSQL
public void getListTableConstraintsSQL(mixed table)
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 336
getListTableIndexesSQL
public void getListTableIndexesSQL(mixed table)
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 341
getListTablesSQL
public void getListTablesSQL()
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 348
getListViewsSQL
public string getListViewsSQL(string database)
Get the SQL to list all views of a database or user.
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 121
getLocateExpression
public integer getLocateExpression(string str, string substr, mixed startPos, int pos)
returns the position of the first occurrence of substring $substr in string $str
- Parameters:
- substr - literal string to find
- str - literal string
- pos - position to start at, beginning of string by default
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 200
getMediumIntTypeDeclarationSql
public void getMediumIntTypeDeclarationSql(mixed field)
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 386
getName
public string getName()
Get the platform name for this instance
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 55
getNowExpression
public string getNowExpression(mixed type)
Return string to call a variable with the current timestamp inside an SQL statement
There are three special variables for current date and time.
- Returns:
- sqlite function as string
- Override.
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 43
getRegexpExpression
public string getRegexpExpression()
returns the regular expression operator
- Override.
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 144
getSetTransactionIsolationSQL
public void getSetTransactionIsolationSQL(integer level)
Get sql to set the transaction isolation level
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 192
getSmallIntTypeDeclarationSQL
public string getSmallIntTypeDeclarationSQL(mixed field, array columnDef)
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 105
getSubstringExpression
public string getSubstringExpression(string value, integer position, integer length, integer from, integer len)
return string to call a function to get a substring inside an SQL statement
Note: Not SQL92, but common functionality.
SQLite only supports the 2 parameter variant of this function
- Parameters:
- value - an sql string literal or column name/alias
- position - where to start the substring portion
- length - the substring portion length
- Returns:
- SQL substring function with given parameters
- Override.
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 224
getTimeTypeDeclarationSQL
public string getTimeTypeDeclarationSQL(array fieldDeclaration)
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 184
getTinyIntTypeDeclarationSql
public void getTinyIntTypeDeclarationSql(mixed field)
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 76
getTrimExpression
public string getTrimExpression(string str, int pos, string char)
Trim a string, leading/trailing/both and with a given char which defaults to space.
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 394
getTruncateTableSQL
public string getTruncateTableSQL(string tableName, bool cascade)
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 305
getVarcharTypeDeclarationSQL
public void getVarcharTypeDeclarationSQL(array field)
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 152
prefersIdentityColumns
public boolean prefersIdentityColumns()
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 376
supportsAlterTable
public void supportsAlterTable()
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 371
supportsForeignKeyConstraints
public boolean supportsForeignKeyConstraints()
SQLite does support foreign key constraints, but only in CREATE TABLE statements...
This really limits their usefulness and requires SQLite specific handling, so
we simply say that SQLite does NOT support foreign keys for now...
- Returns:
- FALSE
- Override.
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 423
udfLocate
public static void udfLocate(string str, string substr, int offset)
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 413
udfMod
public static void udfMod(mixed a, mixed b)
User-defined function for Sqlite that implements MOD(a, b)
/Doctrine/DBAL/Platforms/SqlitePlatform.php at line 405
udfSqrt
public static float udfSqrt(int|float value)
User-defined function for Sqlite that is used with PDO::sqliteCreateFunction()
The SqlitePlatform class describes the specifics and dialects of the SQLite database platform.