Merge pull request #112 from creatronics-de/mysql-fix-quotes

missing quotes added in mysql class
This commit is contained in:
OpenXE-ERP 2023-12-15 18:56:15 +01:00 committed by GitHub
commit 53b228b06c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1230,7 +1230,7 @@ class DB{
$sql = "UPDATE `$tablename` SET "; $sql = "UPDATE `$tablename` SET ";
foreach($ArrCols as $key=>$value) { foreach($ArrCols as $key=>$value) {
if($key!=$pkname && (isset($ziel[$key]) || !$zielspalten)) { if($key!=$pkname && (isset($ziel[$key]) || !$zielspalten)) {
$sqla[] = $key." = '".($escape?$this->real_escape_string($value):$value)."' "; $sqla[] = "`".$key."` = '".($escape?$this->real_escape_string($value):$value)."' ";
} }
} }
if(!empty($sqla)) { if(!empty($sqla)) {