refine example in README.md

Signed-off-by: TennyZhuang <zty0826@gmail.com>
This commit is contained in:
庄天翼 2020-06-03 23:38:03 +08:00 committed by TennyZhuang
parent 2dfaa2b672
commit a18f03e0bc
1 changed files with 2 additions and 2 deletions

View File

@ -40,8 +40,8 @@ To use the SQL parser in your own projects you simply have to follow these few s
if (result.isValid() && result.size() > 0) { if (result.isValid() && result.size() > 0) {
const hsql::SQLStatement* statement = result.getStatement(0); const hsql::SQLStatement* statement = result.getStatement(0);
if (statement.isType(hsql::SelectStatement)) { if (statement->isType(hsql::kSelectStmt)) {
const hsql::SelectStatement* select = (const hsql::SelectStatement*) statement; const auto* select = static_cast<const hsql::SelectStatement*> statement;
/* ... */ /* ... */
} }
} }