Commit b02ed32c authored by Alexander Butenko's avatar Alexander Butenko

Merge pull request #366 from KpuTuK/patch-1

Join: do not add 'on' if using() condition is used
parents c0e35756 8cffc845
......@@ -1225,7 +1225,9 @@ class MysqliDb
$joinStr = $joinTable;
}
$this->_query .= " " . $joinType . " JOIN " . $joinStr . " on " . $joinCondition;
$this->_query .= " " . $joinType . " JOIN " . $joinStr .
(false === stripos('using', $joinCondition) ? " " : " on ")
. $joinCondition;
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment