1
0
Fork 0
MySQLDumper/library/Msd/Sql/Parser/Statement/Create.php
DSB e95ab08945 SQl-Parser:
- changes and fixes for parsing statements
- QA

SQl-Browser / SQL-Box:
-  added semicolon to table select box
2011-06-20 13:39:03 +00:00

35 Zeilen
869 B
PHP

<?php
/**
* This file is part of MySQLDumper released under the GNU/GPL 2 license
* http://www.mysqldumper.net
*
* @package MySQLDumper
* @subpackage SQL-Parser
* @version SVN: $Rev$
* @author $Author$
*/
/**
* Class to parse MySQL CREATE statements.
* This enables you to analyze and modify MySQL queries, which the user has entered.
*
* @package MySQLDumper
* @subpackage SQL-Parser
*/
class Msd_Sql_Parser_Statement_Create implements Msd_Sql_Parser_Interface
{
/**
* Parse the statement.
*
* @param Msd_Sql_Object $statement MySQL CREATE statement.
*
* @return void
*/
public function parse(Msd_Sql_Object $sql)
{
$sql->setState('Create');
$endOfStatement = $sql->getPosition(';');
$statement = $sql->getData($endOfStatement);
return $statement;
}
}