PHP Class Phalcon\Db\Dialect\Oracle

Generates database specific SQL for the Oracle RDBMS. use Phalcon\Db\Adapter\Pdo\Oracle; use Phalcon\Db\Adapter\Pdo\Oracle as Connection; $connection = new Connection([ 'dbname' => '//localhost/enigma', 'username' => 'oracle', 'password' => 'secret', 'dialectClass' => Oracle::class, ]);
Inheritance: extends Phalcon\Db\Dialect
Mostra file Open project: phalcon/incubator Class Usage Examples

Protected Properties

Property Type Description
$_escapeChar @codingStandardsIgnoreStart

Public Methods

Method Description
addColumn ( string $tableName, string $schemaName, Phalcon\Db\ColumnInterface $column ) : string Generates SQL to add a column to a table.
addForeignKey ( string $tableName, string $schemaName, Phalcon\Db\ReferenceInterface $reference ) : string Generates SQL to add an index to a table.
addIndex ( string $tableName, string $schemaName, Phalcon\Db\IndexInterface $index ) : string Generates SQL to add an index to a table.
addPrimaryKey ( string $tableName, string $schemaName, Phalcon\Db\IndexInterface $index ) : string Generates SQL to add the primary key to a table.
createTable ( string $tableName, string $schemaName, array $definition ) : string Generates SQL to create a table in Oracle.
createView ( string $viewName, array $definition, string $schemaName = null ) : string Generates SQL to create a view.
describeColumns ( string $table, string $schema = null ) : string Generates SQL to describe a table.
describeIndexes ( string $table, string $schema = null ) : string Generates SQL to query indexes on a table.
describeReferences ( $table, $schema = null )
dropColumn ( string $tableName, string $schemaName, string $columnName ) : string Generates SQL to delete a column from a table.
dropForeignKey ( string $tableName, string $schemaName, string $referenceName ) : string Generates SQL to delete a foreign key from a table.
dropIndex ( string $tableName, string $schemaName, string $indexName ) : string Generates SQL to delete an index from a table.
dropPrimaryKey ( string $tableName, string $schemaName ) : string Generates SQL to delete primary key from a table.
dropTable ( string $tableName, string $schemaName, boolean $ifExists = true ) : string Generates SQL to drop a table.
dropView ( string $viewName, string $schemaName = null, boolean $ifExists = true ) : string Generates SQL to drop a view.
getColumnDefinition ( Phalcon\Db\ColumnInterface $column ) : string Gets the column name in Oracle.
limit ( string $sqlQuery, mixed $number ) : string Generates the SQL for LIMIT clause.
listTables ( string $schemaName = null ) : string List all tables in database.
listViews ( string $schemaName = null ) : string Generates the SQL to list all views of a schema or user.
modifyColumn ( string $tableName, string $schemaName, Phalcon\Db\ColumnInterface $column, Phalcon\Db\ColumnInterface $current = null ) : string Generates SQL to modify a column in a table.
supportsReleaseSavepoints ( ) : boolean Checks whether the platform supports releasing savepoints.
supportsSavepoints ( ) : boolean Checks whether the platform supports savepoints.
tableExists ( string $tableName, string $schemaName = null ) : string Generates SQL checking for the existence of a schema.table
tableOptions ( string $table, string $schema = null ) : string Generates the SQL to describe the table creation options.
viewExists ( string $viewName, string $schemaName = null ) : string Generates SQL checking for the existence of a schema.view

Protected Methods

Method Description
prepareTable ( string $table, string $schema = null, string $alias = null, string $escapeChar = null ) : string Prepares table for this RDBMS.

Method Details

addColumn() public method

Generates SQL to add a column to a table.
public addColumn ( string $tableName, string $schemaName, Phalcon\Db\ColumnInterface $column ) : string
$tableName string
$schemaName string
$column Phalcon\Db\ColumnInterface
return string

addForeignKey() public method

Generates SQL to add an index to a table.
public addForeignKey ( string $tableName, string $schemaName, Phalcon\Db\ReferenceInterface $reference ) : string
$tableName string
$schemaName string
$reference Phalcon\Db\ReferenceInterface
return string

addIndex() public method

Generates SQL to add an index to a table.
public addIndex ( string $tableName, string $schemaName, Phalcon\Db\IndexInterface $index ) : string
$tableName string
$schemaName string
$index Phalcon\Db\IndexInterface
return string

addPrimaryKey() public method

Generates SQL to add the primary key to a table.
public addPrimaryKey ( string $tableName, string $schemaName, Phalcon\Db\IndexInterface $index ) : string
$tableName string
$schemaName string
$index Phalcon\Db\IndexInterface
return string

createTable() public method

Generates SQL to create a table in Oracle.
public createTable ( string $tableName, string $schemaName, array $definition ) : string
$tableName string
$schemaName string
$definition array
return string

createView() public method

Generates SQL to create a view.
public createView ( string $viewName, array $definition, string $schemaName = null ) : string
$viewName string
$definition array
$schemaName string
return string

describeColumns() public method

Generates SQL to describe a table.
public describeColumns ( string $table, string $schema = null ) : string
$table string
$schema string
return string

describeIndexes() public method

Generates SQL to query indexes on a table.
public describeIndexes ( string $table, string $schema = null ) : string
$table string
$schema string
return string

describeReferences() public method

public describeReferences ( $table, $schema = null )

dropColumn() public method

Generates SQL to delete a column from a table.
public dropColumn ( string $tableName, string $schemaName, string $columnName ) : string
$tableName string
$schemaName string
$columnName string
return string

dropForeignKey() public method

Generates SQL to delete a foreign key from a table.
public dropForeignKey ( string $tableName, string $schemaName, string $referenceName ) : string
$tableName string
$schemaName string
$referenceName string
return string

dropIndex() public method

Generates SQL to delete an index from a table.
public dropIndex ( string $tableName, string $schemaName, string $indexName ) : string
$tableName string
$schemaName string
$indexName string
return string

dropPrimaryKey() public method

Generates SQL to delete primary key from a table.
public dropPrimaryKey ( string $tableName, string $schemaName ) : string
$tableName string
$schemaName string
return string

dropTable() public method

Generates SQL to drop a table.
public dropTable ( string $tableName, string $schemaName, boolean $ifExists = true ) : string
$tableName string
$schemaName string
$ifExists boolean
return string

dropView() public method

Generates SQL to drop a view.
public dropView ( string $viewName, string $schemaName = null, boolean $ifExists = true ) : string
$viewName string
$schemaName string
$ifExists boolean
return string

getColumnDefinition() public method

Gets the column name in Oracle.
public getColumnDefinition ( Phalcon\Db\ColumnInterface $column ) : string
$column Phalcon\Db\ColumnInterface
return string

limit() public method

Generates the SQL for LIMIT clause.
public limit ( string $sqlQuery, mixed $number ) : string
$sqlQuery string
$number mixed
return string

listTables() public method

print_r($dialect->listTables('blog'));
public listTables ( string $schemaName = null ) : string
$schemaName string
return string

listViews() public method

Generates the SQL to list all views of a schema or user.
public listViews ( string $schemaName = null ) : string
$schemaName string
return string

modifyColumn() public method

Generates SQL to modify a column in a table.
public modifyColumn ( string $tableName, string $schemaName, Phalcon\Db\ColumnInterface $column, Phalcon\Db\ColumnInterface $current = null ) : string
$tableName string
$schemaName string
$column Phalcon\Db\ColumnInterface
$current Phalcon\Db\ColumnInterface
return string

prepareTable() protected method

Prepares table for this RDBMS.
protected prepareTable ( string $table, string $schema = null, string $alias = null, string $escapeChar = null ) : string
$table string
$schema string
$alias string
$escapeChar string
return string

supportsReleaseSavepoints() public method

Checks whether the platform supports releasing savepoints.

supportsSavepoints() public method

Checks whether the platform supports savepoints.
public supportsSavepoints ( ) : boolean
return boolean

tableExists() public method

echo $dialect->tableExists('posts', 'blog'); echo $dialect->tableExists('posts');
public tableExists ( string $tableName, string $schemaName = null ) : string
$tableName string
$schemaName string
return string

tableOptions() public method

Generates the SQL to describe the table creation options.
public tableOptions ( string $table, string $schema = null ) : string
$table string
$schema string
return string

viewExists() public method

Generates SQL checking for the existence of a schema.view
public viewExists ( string $viewName, string $schemaName = null ) : string
$viewName string
$schemaName string
return string

Property Details

$_escapeChar protected_oe property

@codingStandardsIgnoreStart
protected $_escapeChar