DropStatement
extends Query
in package
uses
NodeFunction, NumberFunction, StringFunction, DateFunction
Represents a CREATE query
Table of Contents
Properties
Methods
- __construct() : mixed
- abs() : Abs
- Apply the ABS function to the number
- accept() : mixed
- Visit the current Node
- add() : AddOperator
- Apply the ADD operator to the number
- as() : AliasOperator
- Construct an alias for the current node
- asc() : AscOperator
- Construct an ascending order for the current node
- average() : AverageFunction
- Apply the AVERAGE function to the number
- caseWhen() : WhenNode
- Construct a CASE WHEN expression (without value)
- cast() : Cast
- Cast the current node to a given type
- coalesce() : mixed
- collate() : Collate
- Construct a COLLATE call expression on a string expression
- collateAi() : Collate
- Construct a COLLATE call expression on a string expression with accent-insensitive collation and case-sensitive collation
- collateCi() : Collate
- Construct a COLLATE call expression on a string expression with case-insensitive collation and accent-insensitive collation
- collateCiAi() : Collate
- Construct a COLLATE call expression on a string expression with case-insensitive and accent-insensitive collation
- collateCsAs() : Collate
- Construct a COLLATE call expression on a string expression with case-sensitive and accent-sensitive collation
- collateMatch() : CollateMatch
- Construct a COLLATE call expression on a string expression
- collateMatchAi() : CollateMatch
- Construct a COLLATE call expression on a string expression with accent-insensitive collation and case-sensitive collation
- collateMatchCi() : CollateMatch
- Construct a COLLATE call expression on a string expression with case-insensitive collation and accent-insensitive collation
- collateMatchCiAi() : CollateMatch
- Construct a COLLATE call expression on a string expression with case-insensitive and accent-insensitive collation
- collateMatchCsAs() : CollateMatch
- Construct a COLLATE call expression on a string expression with case-sensitive and accent-sensitive collation
- collation() : Collate
- Construct a COLLATE call expression on a string expression
- concat() : ConcatOperator
- Concatenate two string expressions
- count() : CountFunction
- Apply the COUNT function to the number
- dateAdd() : mixed
- dateDuration() : mixed
- dateSubPart() : mixed
- day() : mixed
- desc() : DescOperator
- Construct a descending order for the current node
- div() : DivOperator
- Apply the DIV operator to the number
- eq() : EqualityOperator|IsNullOperator
- Construct a '=' boolean expression
- false() : EqualityOperator|IsNullOperator
- Construct a Node corresponding to a non tautology
- firstValue() : mixed
- Construct a FIRST_VALUE function from the current node
- floor() : Floor
- Apply the FLOOR function to the number
- format() : Format
- Format the number
- formatDate() : mixed
- getPrecedence() : int
- getTable() : mixed
- getType() : Type|null
- Get the type of the Node
- groupConcat() : GroupConcatFunction
- Construct a GROUP_CONCAT call expression on a string expression
- grouping() : Grouping
- Construct a Grouping node
- gt() : GreaterThanOperator
- Apply the GREATER THAN operator to the number
- gteq() : GreaterOrEqualOperator
- Apply the GREATER OR EQUAL operator to the number
- hour() : mixed
- in() : InOperator|NotInOperator
- Construct a 'IN' boolean expression
- isCheck() : mixed
- json() : mixed
- lastValue() : mixed
- Construct a LAST_VALUE function from the current node
- length() : LengthOperator
- Construct a length call expression on a string expression
- locate() : Locate
- Construct a LOCATE call expression on a string expression
- log() : Log
- Apply the LOG function to the number
- log10() : Log
- Apply the LOG function to the number with base 10
- lower() : Lower
- Construct a LOWER call expression on a string expression
- lt() : LesserThanOperator
- Apply the LESS THAN operator to the number
- lteq() : LesserOrEqualOperator
- Apply the LESS OR EQUAL operator to the number
- match() : MatchOperator
- Construct a boolean 'like' expression
- maximum() : MaximumFunction
- Apply the MAXIMUM function to the number
- minimum() : MinimumFunction
- Apply the MINIMUM function to the number
- minute() : mixed
- month() : mixed
- mul() : MulOperator
- Apply the MUL operator to the number
- neq() : NotEqualityOperator|IsNotNullOperator
- Construct a '!=' boolean expression
- nodeArray() : array<string|int, mixed>
- transform any object into a array of Node
- notIn() : NotInOperator|InOperator
- Construct a 'NOT IN' boolean expression
- notMatch() : NotMatchOperator
- Construct a boolean 'not like' expression
- of() : Literal|Node
- Transform any object into a Node (does nothing on a Node)
- pow() : Pow
- Apply the POW function to the number
- present() : BooleanOr
- Construct an expression that will evaluate if a string expression is not null or its length is greater than 0
- regexpInstr() : RegexInstrFunction
- Construct a REGEXP_INSTR call expression on a string expression
- regexpMatch() : RegexMatchOperator
- Construct a boolean REGEXP expression
- regexpReplace() : RegexReplaceFunction
- Construct a REGEXP_REPLACE call expression on a string expression
- regexpSubStr() : RegexSubStrFunction
- Construct a REGEXP_SUBSTR call expression on a string expression
- repeat() : Repeat
- Repeat the current node $times times
- replace() : mixed
- Construct a REPLACE call expression on a string expression
- second() : mixed
- setType() : void
- Set the type of the Node
- standardizeArray() : array<string|int, mixed>
- Transform any object into a array
- sub() : SubOperator
- Apply the SUB operator to the number
- substring() : Substring
- Construct a SUBSTRING call expression on a string expression
- sum() : SumFunction
- Apply the SUM function to the number
- table() : Table
- Construct a Table node
- toSql() : mixed
- transform the node into a SQL query string
- trim() : Trim
- Construct a TRIM call expression on a string expression
- true() : EqualityOperator|IsNullOperator
- Construct a Node corresponding to a tautology
- tuple() : ExpressionList
- Construct a Tuple node
- typed() : Node
- Set the type of the Node and return the Node
- union() : Union
- Union the current query with another one
- upper() : Upper
- Construct an UPPER call expression on a string expression
- weekDay() : mixed
- when() : WhenNode
- Construct a CASE expression from the current node and define the first WHEN clause with a given condition
- year() : mixed
Properties
$check
private
bool
$check
= false
$precedence
private
static mixed
$precedence
= [[\PhpParser\Node\Expr\Cast::class, \FND\QueryBuilder\Nodes\FunctionCall::class, \FND\QueryBuilder\Nodes\Literal::class], [\FND\QueryBuilder\Nodes\ExpressionList::class], [\FND\QueryBuilder\Nodes\Column::class], [\FND\QueryBuilder\Nodes\BinaryOperators\MulOperator::class, \FND\QueryBuilder\Nodes\BinaryOperators\DivOperator::class], [\FND\QueryBuilder\Nodes\BinaryOperators\AddOperator::class, \FND\QueryBuilder\Nodes\BinaryOperators\SubOperator::class], [\FND\QueryBuilder\Nodes\UnaryOperators\IsNullOperator::class, \FND\QueryBuilder\Nodes\UnaryOperators\IsNotNullOperator::class], [\FND\QueryBuilder\Nodes\BinaryOperators\InOperator::class, \FND\QueryBuilder\Nodes\BinaryOperators\NotInOperator::class], [\FND\QueryBuilder\Nodes\BinaryOperators\MatchOperator::class], [\FND\QueryBuilder\Nodes\BinaryOperators\LesserOrEqualOperator::class, \FND\QueryBuilder\Nodes\BinaryOperators\LesserThanOperator::class, \FND\QueryBuilder\Nodes\BinaryOperators\GreaterOrEqualOperator::class, \FND\QueryBuilder\Nodes\BinaryOperators\GreaterThanOperator::class], [\FND\QueryBuilder\Nodes\BinaryOperators\EqualityOperator::class, \FND\QueryBuilder\Nodes\BinaryOperators\NotEqualityOperator::class], [\FND\QueryBuilder\Nodes\NotOperator::class], [\FND\QueryBuilder\Nodes\BinaryOperators\AndOperator::class], [\FND\QueryBuilder\Nodes\BinaryOperators\OrOperator::class], [\FND\QueryBuilder\Nodes\BinaryOperators\AliasOperator::class]]
$table
private
Table|string
$table
$type
private
Type|null
$type
= null
Methods
__construct()
public
__construct(Table|string $table, bool $check) : mixed
Parameters
- $table : Table|string
- $check : bool
abs()
Apply the ABS function to the number
public
abs() : Abs
Return values
Abs —the ABS function
accept()
Visit the current Node
public
accept(mixed $visitor) : mixed
Parameters
- $visitor : mixed
-
a visitor
Return values
mixed —the result string of the visit
add()
Apply the ADD operator to the number
public
add(mixed $other) : AddOperator
Parameters
- $other : mixed
-
mixed the other number
Return values
AddOperator —the ADD operator
as()
Construct an alias for the current node
public
as(mixed $alias) : AliasOperator
Parameters
- $alias : mixed
-
the alias
Return values
AliasOperator —the alias node
asc()
Construct an ascending order for the current node
public
asc() : AscOperator
Return values
AscOperator —the ascending order node
average()
Apply the AVERAGE function to the number
public
average([mixed $groups = NULL ][, mixed $orders = NULL ]) : AverageFunction
Parameters
- $groups : mixed = NULL
-
mixed the groups
- $orders : mixed = NULL
-
mixed the orders
Return values
AverageFunction —the AVERAGE function
caseWhen()
Construct a CASE WHEN expression (without value)
public
static caseWhen(mixed $condition) : WhenNode
Parameters
- $condition : mixed
-
the first WHEN clause condition
Return values
WhenNode —the CASE WHEN expression
cast()
Cast the current node to a given type
public
cast(Type $type) : Cast
Parameters
- $type : Type
-
the type to cast to
Return values
Cast —the cast node
coalesce()
public
coalesce(mixed $args) : mixed
Parameters
- $args : mixed
collate()
Construct a COLLATE call expression on a string expression
public
collate(mixed $ci, mixed $ai[, mixed $charset = "" ]) : Collate
Parameters
- $ci : mixed
-
bool case-insensitive
- $ai : mixed
-
bool accent insensitive
- $charset : mixed = ""
-
string (optional) charset to use
Return values
Collate —a new Collate
collateAi()
Construct a COLLATE call expression on a string expression with accent-insensitive collation and case-sensitive collation
public
collateAi([mixed $charset = "" ]) : Collate
Parameters
- $charset : mixed = ""
-
string (optional) charset to use
Return values
Collate —a new Collate
collateCi()
Construct a COLLATE call expression on a string expression with case-insensitive collation and accent-insensitive collation
public
collateCi([mixed $charset = "" ]) : Collate
Parameters
- $charset : mixed = ""
-
string (optional) charset to use
Return values
Collate —a new Collate
collateCiAi()
Construct a COLLATE call expression on a string expression with case-insensitive and accent-insensitive collation
public
collateCiAi([mixed $charset = "" ]) : Collate
Parameters
- $charset : mixed = ""
-
string (optional) charset to use
Return values
Collate —a new Collate
collateCsAs()
Construct a COLLATE call expression on a string expression with case-sensitive and accent-sensitive collation
public
collateCsAs([mixed $charset = "" ]) : Collate
Parameters
- $charset : mixed = ""
-
string (optional) charset to use
Return values
Collate —a new Collate
collateMatch()
Construct a COLLATE call expression on a string expression
public
collateMatch(mixed $other, mixed $ci, mixed $ai[, mixed $charset = "" ]) : CollateMatch
Parameters
- $other : mixed
-
mixed expression to compare with
- $ci : mixed
-
bool case-insensitive
- $ai : mixed
-
bool accent insensitive
- $charset : mixed = ""
-
string (optional) charset to use
Return values
CollateMatch —a new CollateMatch
collateMatchAi()
Construct a COLLATE call expression on a string expression with accent-insensitive collation and case-sensitive collation
public
collateMatchAi(mixed $other[, mixed $charset = "" ]) : CollateMatch
Parameters
- $other : mixed
-
mixed expression to compare with
- $charset : mixed = ""
-
string (optional) charset to use
Return values
CollateMatch —a new CollateMatch
collateMatchCi()
Construct a COLLATE call expression on a string expression with case-insensitive collation and accent-insensitive collation
public
collateMatchCi(mixed $other[, mixed $charset = "" ]) : CollateMatch
Parameters
- $other : mixed
-
mixed expression to compare with
- $charset : mixed = ""
-
string (optional) charset to use
Return values
CollateMatch —a new CollateMatch
collateMatchCiAi()
Construct a COLLATE call expression on a string expression with case-insensitive and accent-insensitive collation
public
collateMatchCiAi(mixed $other[, mixed $charset = "" ]) : CollateMatch
Parameters
- $other : mixed
-
mixed expression to compare with
- $charset : mixed = ""
-
string (optional) charset to use
Return values
CollateMatch —a new CollateMatch
collateMatchCsAs()
Construct a COLLATE call expression on a string expression with case-sensitive and accent-sensitive collation
public
collateMatchCsAs(mixed $other[, mixed $charset = "" ]) : CollateMatch
Parameters
- $other : mixed
-
mixed expression to compare with
- $charset : mixed = ""
-
string (optional) charset to use
Return values
CollateMatch —a new CollateMatch
collation()
Construct a COLLATE call expression on a string expression
public
collation(mixed $collation) : Collate
Parameters
- $collation : mixed
-
string (optional) collation to use
Return values
Collate —a new Collate
concat()
Concatenate two string expressions
public
concat(mixed $other) : ConcatOperator
Parameters
- $other : mixed
-
mixed expression to concatenate with
Return values
ConcatOperator —a new ConcatOperator
count()
Apply the COUNT function to the number
public
count([mixed $groups = NULL ][, mixed $orders = NULL ]) : CountFunction
Parameters
- $groups : mixed = NULL
-
mixed the groups
- $orders : mixed = NULL
-
mixed the orders
Return values
CountFunction —the COUNT function
dateAdd()
public
dateAdd(mixed $number[, DateSubPartKind $interval = DateSubPartKind::DAY ]) : mixed
Parameters
- $number : mixed
- $interval : DateSubPartKind = DateSubPartKind::DAY
dateDuration()
public
dateDuration(mixed $to[, DateSubPartKind $datePart = DateSubPartKind::DAY ]) : mixed
Parameters
- $to : mixed
- $datePart : DateSubPartKind = DateSubPartKind::DAY
dateSubPart()
public
dateSubPart(mixed $kind) : mixed
Parameters
- $kind : mixed
day()
public
day() : mixed
desc()
Construct a descending order for the current node
public
desc() : DescOperator
Return values
DescOperator —the descending order node
div()
Apply the DIV operator to the number
public
div(mixed $other) : DivOperator
Parameters
- $other : mixed
-
mixed the other number
Return values
DivOperator —the DIV operator
eq()
Construct a '=' boolean expression
public
eq(mixed $other) : EqualityOperator|IsNullOperator
Parameters
- $other : mixed
-
the other operand
Return values
EqualityOperator|IsNullOperator —the equality node
false()
Construct a Node corresponding to a non tautology
public
static false() : EqualityOperator|IsNullOperator
Return values
EqualityOperator|IsNullOperatorfirstValue()
Construct a FIRST_VALUE function from the current node
public
firstValue([mixed $groups = [] ][, mixed $orders = [] ][, mixed $rows = [] ][, mixed $nullsDirective = 0 ]) : mixed
Parameters
- $groups : mixed = []
-
values to partitioned by (for window functions)
- $orders : mixed = []
-
values to order with (for window functions)
- $rows : mixed = []
-
values to bound with (for window functions)
- $nullsDirective : mixed = 0
floor()
Apply the FLOOR function to the number
public
floor() : Floor
Return values
Floor —the FLOOR function
format()
Format the number
public
format(mixed $format[, mixed $locale = NULL ]) : Format
Parameters
- $format : mixed
-
string the format to apply
- $locale : mixed = NULL
-
string the locale to use
Return values
Format —the formatted number
formatDate()
public
formatDate(mixed $format[, mixed $kind = 0 ][, mixed $toTimeZone = "" ][, mixed $fromTimeZone = "" ]) : mixed
Parameters
- $format : mixed
- $kind : mixed = 0
- $toTimeZone : mixed = ""
- $fromTimeZone : mixed = ""
getPrecedence()
public
getPrecedence() : int
Return values
intgetTable()
public
getTable() : mixed
getType()
Get the type of the Node
public
getType() : Type|null
Return values
Type|null —the type
groupConcat()
Construct a GROUP_CONCAT call expression on a string expression
public
groupConcat([mixed $separator = ', ' ][, mixed $groups = NULL ][, mixed $orders = NULL ]) : GroupConcatFunction
Parameters
- $separator : mixed = ', '
-
string separator to use
- $groups : mixed = NULL
-
array groups to concatenate
- $orders : mixed = NULL
-
array orders to use
Return values
GroupConcatFunction —a new GroupConcatFunction
grouping()
Construct a Grouping node
public
static grouping(mixed $node) : Grouping
Parameters
- $node : mixed
-
a node
Return values
Grouping —the new Grouping node
gt()
Apply the GREATER THAN operator to the number
public
gt(mixed $other) : GreaterThanOperator
Parameters
- $other : mixed
Return values
GreaterThanOperator —the GREATER THAN operator
gteq()
Apply the GREATER OR EQUAL operator to the number
public
gteq(mixed $other) : GreaterOrEqualOperator
Parameters
- $other : mixed
-
mixed the other number
Return values
GreaterOrEqualOperator —the GREATER OR EQUAL operator
hour()
public
hour() : mixed
in()
Construct a 'IN' boolean expression
public
in([mixed $others = NULL ]) : InOperator|NotInOperator
Parameters
- $others : mixed = NULL
-
the other operands
Return values
InOperator|NotInOperatorisCheck()
public
isCheck() : mixed
json()
public
json() : mixed
lastValue()
Construct a LAST_VALUE function from the current node
public
lastValue([mixed $groups = [] ][, mixed $orders = [] ][, mixed $rows = [] ][, mixed $nullsDirective = 0 ]) : mixed
Parameters
- $groups : mixed = []
-
values to partitioned by (for window functions)
- $orders : mixed = []
-
values to order with (for window functions)
- $rows : mixed = []
-
values to bound with (for window functions)
- $nullsDirective : mixed = 0
length()
Construct a length call expression on a string expression
public
length() : LengthOperator
Return values
LengthOperator —a new LengthOperator
locate()
Construct a LOCATE call expression on a string expression
public
locate(mixed $substring[, mixed $start = 1 ]) : Locate
Parameters
- $substring : mixed
-
mixed substring to locate
- $start : mixed = 1
-
int start position
Return values
Locate —a new Locate
log()
Apply the LOG function to the number
public
log([mixed $base = NULL ]) : Log
Parameters
- $base : mixed = NULL
-
mixed the base of the logarithm
Return values
Log —the LOG function
log10()
Apply the LOG function to the number with base 10
public
log10() : Log
Return values
Log —the LOG function
lower()
Construct a LOWER call expression on a string expression
public
lower() : Lower
Return values
Lower —a new Lower
lt()
Apply the LESS THAN operator to the number
public
lt(mixed $other) : LesserThanOperator
Parameters
- $other : mixed
-
mixed the other number
Return values
LesserThanOperator —the LESS THAN operator
lteq()
Apply the LESS OR EQUAL operator to the number
public
lteq(mixed $other) : LesserOrEqualOperator
Parameters
- $other : mixed
-
mixed the other number
Return values
LesserOrEqualOperator —the LESS OR EQUAL operator
match()
Construct a boolean 'like' expression
public
match(mixed $other) : MatchOperator
Parameters
- $other : mixed
-
mixed expression to compare with
Return values
MatchOperator —a new MatchOperator
maximum()
Apply the MAXIMUM function to the number
public
maximum([mixed $groups = NULL ][, mixed $orders = NULL ]) : MaximumFunction
Parameters
- $groups : mixed = NULL
-
mixed the groups
- $orders : mixed = NULL
-
mixed the orders
Return values
MaximumFunction —the MAXIMUM function
minimum()
Apply the MINIMUM function to the number
public
minimum([mixed $groups = NULL ][, mixed $orders = NULL ]) : MinimumFunction
Parameters
- $groups : mixed = NULL
-
mixed the groups
- $orders : mixed = NULL
-
mixed the orders
Return values
MinimumFunction —the MINIMUM function
minute()
public
minute() : mixed
month()
public
month() : mixed
mul()
Apply the MUL operator to the number
public
mul(mixed $other) : MulOperator
Parameters
- $other : mixed
-
mixed the other number
Return values
MulOperator —the MUL operator
neq()
Construct a '!=' boolean expression
public
neq(mixed $other) : NotEqualityOperator|IsNotNullOperator
Parameters
- $other : mixed
-
the other operand
Return values
NotEqualityOperator|IsNotNullOperatornodeArray()
transform any object into a array of Node
public
static nodeArray(mixed $args) : array<string|int, mixed>
Parameters
- $args : mixed
-
any object
Return values
array<string|int, mixed> —an array of Node
notIn()
Construct a 'NOT IN' boolean expression
public
notIn([mixed $others = NULL ]) : NotInOperator|InOperator
Parameters
- $others : mixed = NULL
-
the other operands
Return values
NotInOperator|InOperatornotMatch()
Construct a boolean 'not like' expression
public
notMatch(mixed $other) : NotMatchOperator
Parameters
- $other : mixed
-
mixed expression to compare with
Return values
NotMatchOperator —a new NotMatchOperator
of()
Transform any object into a Node (does nothing on a Node)
public
static of(mixed $value) : Literal|Node
Parameters
- $value : mixed
-
any value
Return values
Literal|Node —a Node
pow()
Apply the POW function to the number
public
pow(mixed $exponent) : Pow
Parameters
- $exponent : mixed
-
mixed the exponent
Return values
Pow —the POW function
present()
Construct an expression that will evaluate if a string expression is not null or its length is greater than 0
public
present() : BooleanOr
Return values
BooleanOr —a new BooleanOr
regexpInstr()
Construct a REGEXP_INSTR call expression on a string expression
public
regexpInstr(mixed $pattern[, mixed $start = 1 ][, mixed $occurrence = 1 ][, mixed $return = 0 ][, mixed $flags = 'c' ]) : RegexInstrFunction
Parameters
- $pattern : mixed
-
string pattern to search
- $start : mixed = 1
-
int start position (default 1)
- $occurrence : mixed = 1
-
int occurrence to replace (default 1)
- $return : mixed = 0
-
int return option (default 0)
- $flags : mixed = 'c'
-
string flags to use (default 'c')
Return values
RegexInstrFunction —a new RegexInstrFunction
regexpMatch()
Construct a boolean REGEXP expression
public
regexpMatch(mixed $regex) : RegexMatchOperator
Parameters
- $regex : mixed
-
mixed the regex operand
Return values
RegexMatchOperator —a new RegexMatchOperator
regexpReplace()
Construct a REGEXP_REPLACE call expression on a string expression
public
regexpReplace(mixed $pattern, mixed $replacement[, mixed $start = 1 ][, mixed $occurrence = 0 ][, mixed $flags = 'c' ]) : RegexReplaceFunction
Parameters
- $pattern : mixed
-
string pattern to search
- $replacement : mixed
-
string replacement
- $start : mixed = 1
-
int start position (default 1)
- $occurrence : mixed = 0
-
int occurrence to replace (default 0)
- $flags : mixed = 'c'
-
string flags to use (default 'c')
Return values
RegexReplaceFunction —a new RegexReplaceFunction
regexpSubStr()
Construct a REGEXP_SUBSTR call expression on a string expression
public
regexpSubStr(mixed $pattern[, mixed $start = 1 ][, mixed $occurrence = 1 ][, mixed $flags = 'c' ]) : RegexSubStrFunction
Parameters
- $pattern : mixed
-
string pattern to search
- $start : mixed = 1
-
int start position (default 1)
- $occurrence : mixed = 1
-
int occurrence to replace (default 1)
- $flags : mixed = 'c'
-
string flags to use (default 'c')
Return values
RegexSubStrFunction —a new RegexSubStrFunction
repeat()
Repeat the current node $times times
public
repeat(mixed $times) : Repeat
Parameters
- $times : mixed
-
the number of times to repeat the current node
Return values
Repeat —the repeated node
replace()
Construct a REPLACE call expression on a string expression
public
replace(mixed $oldString, mixed $newString) : mixed
Parameters
- $oldString : mixed
-
mixed old string to replace
- $newString : mixed
-
mixed new string to use
second()
public
second() : mixed
setType()
Set the type of the Node
public
setType(Type $type) : void
Parameters
- $type : Type
-
the type
standardizeArray()
Transform any object into a array
public
static standardizeArray(mixed $args) : array<string|int, mixed>
Parameters
- $args : mixed
-
the object
Return values
array<string|int, mixed> —the array
sub()
Apply the SUB operator to the number
public
sub(mixed $other) : SubOperator
Parameters
- $other : mixed
-
mixed the other number
Return values
SubOperator —the SUB operator
substring()
Construct a SUBSTRING call expression on a string expression
public
substring(mixed $start[, mixed $length = NULL ]) : Substring
Parameters
- $start : mixed
-
int start position
- $length : mixed = NULL
-
mixed length of the substring
Return values
Substring —a new Substring
sum()
Apply the SUM function to the number
public
sum([mixed $groups = NULL ][, mixed $orders = NULL ]) : SumFunction
Parameters
- $groups : mixed = NULL
-
mixed the groups
- $orders : mixed = NULL
-
mixed the orders
Return values
SumFunction —the SUM function
table()
Construct a Table node
public
static table(mixed $name) : Table
Parameters
- $name : mixed
-
the table name
Return values
Table —the table
toSql()
transform the node into a SQL query string
public
toSql([mixed $connection = NULL ]) : mixed
Parameters
- $connection : mixed = NULL
-
the DB connection concerned (to select the right visitor)
Return values
mixed —the SQL string
trim()
Construct a TRIM call expression on a string expression
public
trim() : Trim
Return values
Trim —a new Trim
true()
Construct a Node corresponding to a tautology
public
static true() : EqualityOperator|IsNullOperator
Return values
EqualityOperator|IsNullOperatortuple()
Construct a Tuple node
public
static tuple(mixed $array) : ExpressionList
Parameters
- $array : mixed
-
a list
Return values
ExpressionList —the new Tuple node
typed()
Set the type of the Node and return the Node
public
typed(Type $type) : Node
Parameters
- $type : Type
-
the type
Return values
Node —the current Node
union()
Union the current query with another one
public
union(mixed $query[, mixed $all = false ]) : Union
Parameters
- $query : mixed
-
mixed
- $all : mixed = false
-
boolean
Return values
Union —the union node
upper()
Construct an UPPER call expression on a string expression
public
upper() : Upper
Return values
Upper —a new Upper
weekDay()
public
weekDay() : mixed
when()
Construct a CASE expression from the current node and define the first WHEN clause with a given condition
public
when(mixed $condition) : WhenNode
Parameters
- $condition : mixed
Return values
WhenNode —the case node
year()
public
year() : mixed