Update code sample in README

This commit is contained in:
Andy Grove 2018-09-08 08:43:15 -06:00
parent e16b92763a
commit 48e78f99dd

View file

@ -20,7 +20,9 @@ let sql = "SELECT a, b, 123, myfunc(b) \
WHERE a > b AND b < 100 \
ORDER BY a DESC, b";
let ast = Parser::parse_sql(sql.to_string()).unwrap();
let dialect = GenericSqlDialect{}; // or AnsiSqlDialect, or your own dialect ...
let ast = Parser::parse_sql(&dialect,sql.to_string()).unwrap();
println!("AST: {:?}", ast);
```