blob: 55144dcea18b9a1644640833e85be54b74054776 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
#include "formatbegintrans.h"
#include "parser/ast/sqlitebegintrans.h"
FormatBeginTrans::FormatBeginTrans(SqliteBeginTrans* bt) :
bt(bt)
{
}
void FormatBeginTrans::formatInternal()
{
handleExplainQuery(bt);
withKeyword("BEGIN");
if (bt->type != SqliteBeginTrans::Type::null)
withKeyword(SqliteBeginTrans::typeToString(bt->type));
if (bt->transactionKw)
{
withKeyword("TRANSACTION");
if (!bt->name.isNull())
withId(bt->name);
}
withConflict(bt->onConflict).withSemicolon();
}
|