wangweianger / mysqls

It is written in JavaScript,crud for mysql.You can also use transactions very easily.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

多表查询报错

Lkx2217 opened this issue · comments

commented

sql.table({'node_table1': 'a', 'node_table2': 'b'}).where('id=1').select()

完全复制的示例,运行报错:(node:23224) UnhandledPromiseRejectionWarning: TypeError: opt.indexOf is not a function

commented

在补充一个:
mysql.union(mysql.table("table_1").select()).union(mysql.table("table_2").select()).select(),
这个运行的结果是:((SELECT * FROM table_1 ))