@qinglian/sql-parser
v0.0.2-beta.0
Published
A SQL parser build with Rust
Downloads
3
Readme
@qinglian/sql-parser
基于Rust实现的SQL Parser工具。
example
const { parser } = require("@qinglian/sql-parser");
const MockSQL = `
create table room_user
(
id varchar(50) not null,
openid varchar(50) not null,
roomid varchar(50) not null,
status tinyint default 1 not null,
create_time datetime default CURRENT_TIMESTAMP not null,
update_time datetime default CURRENT_TIMESTAMP not null
);
`;
const sqlAst = parser(MockSQL);
console.log(sqlAst)