You've already forked phpmyadmin
mirror of
https://github.com/phpmyadmin/phpmyadmin.git
synced 2026-11-03 11:53:04 +03:00
Fix failing tests.
Updated sql-parser library. Signed-off-by: Dan Ungureanu <udan1107@gmail.com>
This commit is contained in:
@@ -97,6 +97,8 @@ class AlterStatement extends NotImplementedStatement
|
||||
);
|
||||
|
||||
/**
|
||||
* Function called after the token was processed.
|
||||
*
|
||||
* Extracts the name of affected column.
|
||||
*
|
||||
* @param Parser $parser The instance that requests parsing.
|
||||
@@ -124,5 +126,4 @@ class AlterStatement extends NotImplementedStatement
|
||||
//
|
||||
parent::after($parser, $list, $token);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -100,6 +100,8 @@ class CreateStatement extends Statement
|
||||
public $body;
|
||||
|
||||
/**
|
||||
* Function called before the token is processed.
|
||||
*
|
||||
* Parsing the `CREATE` statement.
|
||||
*
|
||||
* @param Parser $parser The instance that requests parsing.
|
||||
|
||||
@@ -37,6 +37,8 @@ class MaintenanceStatement extends Statement
|
||||
public $tables;
|
||||
|
||||
/**
|
||||
* Function called after the token was processed.
|
||||
*
|
||||
* Parses the additional options fragment at the end.
|
||||
*
|
||||
* @param Parser $parser The instance that requests parsing.
|
||||
|
||||
@@ -28,6 +28,8 @@ class NotImplementedStatement extends Statement
|
||||
{
|
||||
|
||||
/**
|
||||
* Function called after the token was processed.
|
||||
*
|
||||
* Jump to the end of the delimiter.
|
||||
*
|
||||
* @param Parser $parser The instance that requests parsing.
|
||||
|
||||
@@ -36,6 +36,8 @@ class RenameStatement extends Statement
|
||||
public $renames;
|
||||
|
||||
/**
|
||||
* Function called before the token is processed.
|
||||
*
|
||||
* Skips the `TABLE` keyword after `RENAME`.
|
||||
*
|
||||
* @param Parser $parser The instance that requests parsing.
|
||||
|
||||
@@ -68,17 +68,29 @@ class SelectStatement extends Statement
|
||||
);
|
||||
|
||||
/**
|
||||
* The sections of this statement, in order.
|
||||
* The clauses of this statement, in order.
|
||||
*
|
||||
* Used by the query builder to arrange the clauses.
|
||||
* @see Statement::$CLAUSES
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
public static $SECTIONS = array(
|
||||
'SELECT' => 0, '%OPTIONS' => 1,'FROM' => 2, 'PARTITION' => 3,
|
||||
'WHERE' => 4, 'GROUP BY' => 5, 'HAVING' => 6, 'ORDER BY' => 7,
|
||||
'LIMIT' => 8, 'PROCEDURE' => 9, 'INTO' => 10, 'UNION' => 11,
|
||||
'JOIN' => 12, '%OPTIONS' => 13
|
||||
public static $CLAUSES = array(
|
||||
'SELECT' => array('SELECT', 2),
|
||||
// Used for options.
|
||||
'_OPTIONS' => array('_OPTIONS', 1),
|
||||
// Used for select expressions.
|
||||
'_SELECT' => array('SELECT', 1),
|
||||
'FROM' => array('FROM', 3),
|
||||
'PARTITION' => array('PARTITION', 3),
|
||||
'WHERE' => array('WHERE', 3),
|
||||
'GROUP BY' => array('GROUP BY', 3),
|
||||
'HAVING' => array('HAVING', 3),
|
||||
'ORDER BY' => array('ORDER BY', 3),
|
||||
'LIMIT' => array('LIMIT', 3),
|
||||
'PROCEDURE' => array('PROCEDURE', 3),
|
||||
'INTO' => array('INTO', 3),
|
||||
'UNION' => array('UNION', 3),
|
||||
'JOIN' => array('JOIN', 3),
|
||||
);
|
||||
|
||||
/**
|
||||
@@ -86,33 +98,33 @@ class SelectStatement extends Statement
|
||||
*
|
||||
* @var FieldFragment[]
|
||||
*/
|
||||
public $expr;
|
||||
public $expr = array();
|
||||
|
||||
/**
|
||||
* Tables used as sources for this statement.
|
||||
*
|
||||
* @var FieldFragment[]
|
||||
*/
|
||||
public $from;
|
||||
public $from = array();
|
||||
|
||||
/**
|
||||
* Partitions used as source for this statement.
|
||||
*
|
||||
* @var ArrayFragment[]
|
||||
* @var ArrayFragment
|
||||
*/
|
||||
public $partition;
|
||||
|
||||
/**
|
||||
* Conditions used for filtering each row of the result set.
|
||||
*
|
||||
* @var WhereKeyword
|
||||
* @var WhereKeyword[]
|
||||
*/
|
||||
public $where;
|
||||
|
||||
/**
|
||||
* Conditions used for grouping the result set.
|
||||
*
|
||||
* @var GroupKeyword
|
||||
* @var OrderKeyword[]
|
||||
*/
|
||||
public $group;
|
||||
|
||||
@@ -157,4 +169,11 @@ class SelectStatement extends Statement
|
||||
* @var JoinKeyword
|
||||
*/
|
||||
public $join;
|
||||
|
||||
/**
|
||||
* Unions.
|
||||
*
|
||||
* @var SelectStatement[]
|
||||
*/
|
||||
public $union = array();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user