Skip to content

How to use node-sql-parser #1922

Closed Answered by taozhi8833998
huxiaoyan0824 asked this question in Q&A
Discussion options

You must be logged in to vote
const sql = `SELECT d.Fdrug_hash_id FROM t_xxxx d where  d.Fapproval_number like '\tH20190022%'`
const { Parser } = require('node-sql-parser/build/mysql')
const parser = new Parser()
const ast = parser.astify(sql)
console.log(ast)

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by huxiaoyan0824
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants