]> git.pld-linux.org Git - packages/php-propel.git/blob - escape.patch
7d568671bd9df16ecb494a80f3ff3d0f3d482f1d
[packages/php-propel.git] / escape.patch
1 --- a/runtime/classes/propel/util/BasePeer.php  2018-06-08 09:24:24.133168452 +0200
2 +++ b/runtime/classes/propel/util/BasePeer.php  2018-06-08 10:26:40.142239018 +0200
3 @@ -353,8 +353,13 @@
4  
5                         $stmt = null;
6                         try {
7 -
8 -                               $sql = "UPDATE " . $tableName . " SET ";
9 +                               $sql = "UPDATE ";
10 +                                if ($db->useQuoteIdentifier()) {
11 +                                        $sql .= $db->quoteIdentifierTable($tableName);
12 +                                } else {
13 +                                        $sql .= $tableName;
14 +                                }
15 +                                $sql .= " SET ";
16                                 $p = 1;
17                                 foreach ($updateTablesColumns[$tableName] as $col) {
18                                         $updateColumnName = substr($col, strrpos($col, '.') + 1);
19 @@ -886,15 +891,19 @@
20                                         $condition .= ' AND ';
21                                 }
22                         }
23 -
24 +                       if ($db->useQuoteIdentifier()) {
25 +                               $_rightTable = $db->quoteIdentifierTable($rightTable);
26 +                       } else {
27 +                               $_rightTable = $rightTable;
28 +                       }
29                         // add 'em to the queues..
30                         if ($joinType = $join->getJoinType()) {
31                           // real join
32                                 if (!$fromClause) {
33                                         $fromClause[] = $leftTable . $leftTableAlias;
34                                 }
35 -                               $joinTables[] = $rightTable . $rightTableAlias;
36 -                               $joinClause[] = $join->getJoinType() . ' ' . $rightTable . $rightTableAlias . " ON ($condition)";
37 +                               $joinTables[] = $_rightTable . $rightTableAlias;
38 +                               $joinClause[] = $join->getJoinType() . ' ' . $_rightTable . $rightTableAlias . " ON ($condition)";
39                         } else {
40                           // implicit join, translates to a where
41                                 $fromClause[] = $leftTable . $leftTableAlias;
This page took 0.024511 seconds and 2 git commands to generate.