SQL Query Generator Bugfix
This commit is contained in:
parent
b337e5748f
commit
9142f3b3e0
@ -148,7 +148,12 @@ function sqlGenerator({ tableName, genObject }) {
|
||||
|
||||
if (sqlSearhString) {
|
||||
const stringOperator = genObject?.searchOperator || "AND";
|
||||
queryString += ` WHERE ${sqlSearhString.join(` ${stringOperator} `)} `;
|
||||
queryString += ` WHERE ${sqlSearhString
|
||||
.map((str) => {
|
||||
if (genObject.join) return `${tableName}.${str}`;
|
||||
return str;
|
||||
})
|
||||
.join(` ${stringOperator} `)} `;
|
||||
}
|
||||
|
||||
if (genObject.order)
|
||||
|
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "datasquirel",
|
||||
"version": "2.5.1",
|
||||
"version": "2.5.2",
|
||||
"description": "Cloud-based SQL data management tool",
|
||||
"main": "index.js",
|
||||
"bin": {
|
||||
|
Loading…
Reference in New Issue
Block a user