package Default
inherited_from \Zend\Db\Sql\AbstractSql

 Methods

__construct()

__construct(string $table = ''

Parameters

$table

string

addColumn()

addColumn(\Zend\Db\Sql\Ddl\Column\ColumnInterface $column) : \Zend\Db\Sql\Ddl\AlterTable
fluent This method is part of a fluent interface and will return the same instance

Parameters

$column

\Zend\Db\Sql\Ddl\Column\ColumnInterface

Returns

\Zend\Db\Sql\Ddl\AlterTable

addConstraint()

addConstraint(\Zend\Db\Sql\Ddl\Constraint\ConstraintInterface $constraint) : \Zend\Db\Sql\Ddl\AlterTable
fluent This method is part of a fluent interface and will return the same instance

Parameters

$constraint

\Zend\Db\Sql\Ddl\Constraint\ConstraintInterface

Returns

\Zend\Db\Sql\Ddl\AlterTable

changeColumn()

changeColumn(string $name, \Zend\Db\Sql\Ddl\Column\ColumnInterface $column) : \Zend\Db\Sql\Ddl\AlterTable
fluent This method is part of a fluent interface and will return the same instance

Parameters

$name

string

$column

\Zend\Db\Sql\Ddl\Column\ColumnInterface

Returns

\Zend\Db\Sql\Ddl\AlterTable

dropColumn()

dropColumn(string $name) : \Zend\Db\Sql\Ddl\AlterTable
fluent This method is part of a fluent interface and will return the same instance

Parameters

$name

string

Returns

\Zend\Db\Sql\Ddl\AlterTable

dropConstraint()

dropConstraint(string $name) : \Zend\Db\Sql\Ddl\AlterTable
fluent This method is part of a fluent interface and will return the same instance

Parameters

$name

string

Returns

\Zend\Db\Sql\Ddl\AlterTable

getRawState()

getRawState(string|null $key = null) : array

Parameters

$key

stringnull

Returns

array

Get SQL string for statement

getSqlString(\Zend\Db\Adapter\Platform\PlatformInterface $adapterPlatform = null
Inherited
inherited_from \Zend\Db\Sql\SqlInterface::getSqlString()

Parameters

$adapterPlatform

setTable()

setTable(string $name) : \Zend\Db\Sql\Ddl\AlterTable
fluent This method is part of a fluent interface and will return the same instance

Parameters

$name

string

Returns

\Zend\Db\Sql\Ddl\AlterTable

buildSqlString()

buildSqlString(\Zend\Db\Adapter\Platform\PlatformInterface $platform, null|\Zend\Db\Adapter\Driver\DriverInterface $driver = null, null|\Zend\Db\Adapter\ParameterContainer $parameterContainer = null) : string
Inherited

Parameters

$platform

\Zend\Db\Adapter\Platform\PlatformInterface

$driver

null\Zend\Db\Adapter\Driver\DriverInterface

$parameterContainer

null\Zend\Db\Adapter\ParameterContainer

Returns

string

createSqlFromSpecificationAndParameters()

createSqlFromSpecificationAndParameters(string|array $specifications, string|array $parameters) : string
Inherited

Parameters

$specifications

stringarray

$parameters

stringarray

Exceptions

\Zend\Db\Sql\Exception\RuntimeException

Returns

string

Copy variables from the subject into the local properties

localizeVariables() 
Inherited

processAddColumns()

processAddColumns(\Zend\Db\Adapter\Platform\PlatformInterface $adapterPlatform = null

Parameters

$adapterPlatform

processAddConstraints()

processAddConstraints(\Zend\Db\Adapter\Platform\PlatformInterface $adapterPlatform = null

Parameters

$adapterPlatform

processChangeColumns()

processChangeColumns(\Zend\Db\Adapter\Platform\PlatformInterface $adapterPlatform = null

Parameters

$adapterPlatform

processDropColumns()

processDropColumns(\Zend\Db\Adapter\Platform\PlatformInterface $adapterPlatform = null

Parameters

$adapterPlatform

processDropConstraints()

processDropConstraints(\Zend\Db\Adapter\Platform\PlatformInterface $adapterPlatform = null

Parameters

$adapterPlatform

processExpression()

processExpression(\Zend\Db\Sql\ExpressionInterface $expression, \Zend\Db\Adapter\Platform\PlatformInterface $platform, null|\Zend\Db\Adapter\Driver\DriverInterface $driver = null, null|\Zend\Db\Adapter\ParameterContainer $parameterContainer = null, null|string $namedParameterPrefix = null) : string
Inherited
staticvar int $runtimeExpressionPrefix

Parameters

$expression

\Zend\Db\Sql\ExpressionInterface

$platform

\Zend\Db\Adapter\Platform\PlatformInterface

$driver

null\Zend\Db\Adapter\Driver\DriverInterface

$parameterContainer

null\Zend\Db\Adapter\ParameterContainer

$namedParameterPrefix

nullstring

Exceptions

\Zend\Db\Sql\Exception\RuntimeException

Returns

string

processSubSelect()

processSubSelect(\Zend\Db\Sql\Select $subselect, \Zend\Db\Adapter\Platform\PlatformInterface $platform, null|\Zend\Db\Adapter\Driver\DriverInterface $driver = null, null|\Zend\Db\Adapter\ParameterContainer $parameterContainer = null) : string
Inherited

Parameters

$subselect

\Zend\Db\Sql\Select

$platform

\Zend\Db\Adapter\Platform\PlatformInterface

$driver

null\Zend\Db\Adapter\Driver\DriverInterface

$parameterContainer

null\Zend\Db\Adapter\ParameterContainer

Returns

string

processTable()

processTable(\Zend\Db\Adapter\Platform\PlatformInterface $adapterPlatform = null

Parameters

$adapterPlatform

resolveColumnValue()

resolveColumnValue(null|array|\Zend\Db\Sql\ExpressionInterface|\Zend\Db\Sql\Select $column, \Zend\Db\Adapter\Platform\PlatformInterface $platform, null|\Zend\Db\Adapter\Driver\DriverInterface $driver = null, null|\Zend\Db\Adapter\ParameterContainer $parameterContainer = null, null|string $namedParameterPrefix = null) : string
Inherited

Parameters

$column

nullarray\Zend\Db\Sql\ExpressionInterface\Zend\Db\Sql\Select

$platform

\Zend\Db\Adapter\Platform\PlatformInterface

$driver

null\Zend\Db\Adapter\Driver\DriverInterface

$parameterContainer

null\Zend\Db\Adapter\ParameterContainer

$namedParameterPrefix

nullstring

Returns

string

resolveTable()

resolveTable(string|\Zend\Db\Sql\TableIdentifier|\Zend\Db\Sql\Select $table, \Zend\Db\Adapter\Platform\PlatformInterface $platform, \Zend\Db\Adapter\Driver\DriverInterface $driver = null, \Zend\Db\Adapter\ParameterContainer $parameterContainer = null) : string
Inherited

Parameters

$table

string\Zend\Db\Sql\TableIdentifier\Zend\Db\Sql\Select

$platform

\Zend\Db\Adapter\Platform\PlatformInterface

$driver

\Zend\Db\Adapter\Driver\DriverInterface

$parameterContainer

\Zend\Db\Adapter\ParameterContainer

Returns

string

 Properties

 

$addColumns

$addColumns : array

Default

array()
 

$addConstraints

$addConstraints : array

Default

array()
 

$changeColumns

$changeColumns : array

Default

array()
 

$dropColumns

$dropColumns : array

Default

array()
 

$dropConstraints

$dropConstraints : array

Default

array()
 

$instanceParameterIndex

$instanceParameterIndex : array

Default

array()
 

$processInfo

$processInfo : string

Default

array('paramPrefix' => '', 'subselectCount' => 0)
 

Specifications for Sql String generation

$specifications : array

Default

array(self::TABLE => "ALTER TABLE %1\$s\n", self::ADD_COLUMNS => array("%1\$s" => array(array(1 => "ADD COLUMN %1\$s,\n", 'combinedby' => ""))), self::CHANGE_COLUMNS => array("%1\$s" => array(array(2 => "CHANGE COLUMN %1\$s %2\$s,\n", 'combinedby' => ""))), self::DROP_COLUMNS => array("%1\$s" => array(array(1 => "DROP COLUMN %1\$s,\n", 'combinedby' => ""))), self::ADD_CONSTRAINTS => array("%1\$s" => array(array(1 => "ADD %1\$s,\n", 'combinedby' => ""))), self::DROP_CONSTRAINTS => array("%1\$s" => array(array(1 => "DROP CONSTRAINT %1\$s,\n", 'combinedby' => ""))))
inherited_from \Zend\Db\Sql\AbstractSql::specifications
 

Specifications for Sql String generation

$specifications : array<mixed,string> | array<mixed,array>

Default

array()
 

$table

$table : string

Default

''

 Constants

 

ADD_COLUMNS

ADD_COLUMNS = 'addColumns' 
 

ADD_CONSTRAINTS

ADD_CONSTRAINTS = 'addConstraints' 
 

CHANGE_COLUMNS

CHANGE_COLUMNS = 'changeColumns' 
 

DROP_COLUMNS

DROP_COLUMNS = 'dropColumns' 
 

DROP_CONSTRAINTS

DROP_CONSTRAINTS = 'dropConstraints' 
 

TABLE

TABLE = 'table'