PHP Class SqlParser\Statements\InsertStatement

INSERT [LOW_PRIORITY | DELAYED | HIGH_PRIORITY] [IGNORE] [INTO] tbl_name [PARTITION (partition_name,...)] [(col_name,...)] {VALUES | VALUE} ({expr | DEFAULT},...),(...),... [ ON DUPLICATE KEY UPDATE col_name=expr [, col_name=expr] ... ] or INSERT [LOW_PRIORITY | DELAYED | HIGH_PRIORITY] [IGNORE] [INTO] tbl_name [PARTITION (partition_name,...)] SET col_name={expr | DEFAULT}, ... [ ON DUPLICATE KEY UPDATE col_name=expr [, col_name=expr] ... ] or INSERT [LOW_PRIORITY | HIGH_PRIORITY] [IGNORE] [INTO] tbl_name [PARTITION (partition_name,...)] [(col_name,...)] SELECT ... [ ON DUPLICATE KEY UPDATE col_name=expr [, col_name=expr] ... ]
Inheritance: extends SqlParser\Statement
Mostrar archivo Open project: phpmyadmin/sql-parser

Public Properties

Property Type Description
$OPTIONS array Options for INSERT statements.
$into SqlParser\Components\IntoKeyword Tables used as target for this statement.
$onDuplicateSet SqlParser\Components\SetOperation[] If ON DUPLICATE KEY UPDATE clause is present holds the SetOperation
$select SelectStatement If SELECT clause is present holds the SelectStatement
$set SqlParser\Components\SetOperation[] If SET clause is present holds the SetOperation
$values SqlParser\Components\Array2d Values to be inserted.

Public Methods

Method Description
build ( ) : string
parse ( Parser $parser, TokensList $list ) : void

Method Details

build() public method

public build ( ) : string
return string

parse() public method

public parse ( Parser $parser, TokensList $list ) : void
$parser SqlParser\Parser The instance that requests parsing.
$list SqlParser\TokensList The list of tokens to be parsed.
return void

Property Details

$OPTIONS public_oe static_oe property

Options for INSERT statements.
public static array $OPTIONS
return array

$into public_oe property

Tables used as target for this statement.
public IntoKeyword,SqlParser\Components $into
return SqlParser\Components\IntoKeyword

$onDuplicateSet public_oe property

If ON DUPLICATE KEY UPDATE clause is present holds the SetOperation
public SetOperation[],SqlParser\Components $onDuplicateSet
return SqlParser\Components\SetOperation[]

$select public_oe property

If SELECT clause is present holds the SelectStatement
public SelectStatement,SqlParser\Statements $select
return SelectStatement

$set public_oe property

If SET clause is present holds the SetOperation
public SetOperation[],SqlParser\Components $set
return SqlParser\Components\SetOperation[]

$values public_oe property

Values to be inserted.
public Array2d,SqlParser\Components $values
return SqlParser\Components\Array2d