HyriseSQLParser/src/sql/InsertStatement.h
root 1922210f70 1. add scheme name support for tables names
2. add IF EXIST support for DROP TABLE/VIEW
3. fix memory free bug: delete -> free
4. add features in sqlhelper.cpp
2017-09-13 17:37:31 +08:00

30 lines
643 B
C++
Executable File

#ifndef __SQLPARSER__INSERT_STATEMENT_H__
#define __SQLPARSER__INSERT_STATEMENT_H__
#include "SQLStatement.h"
#include "SelectStatement.h"
namespace hsql {
enum InsertType {
kInsertValues,
kInsertSelect
};
// Represents SQL Insert statements.
// Example: "INSERT INTO students VALUES ('Max', 1112233, 'Musterhausen', 2.3)"
struct InsertStatement : SQLStatement {
InsertStatement(InsertType type);
virtual ~InsertStatement();
InsertType type;
char* schema;
char* tableName;
std::vector<char*>* columns;
std::vector<Expr*>* values;
SelectStatement* select;
};
} // namsepace hsql
#endif