@@ 90-104 (lines=15) @@ | ||
87 | $sqlParts = $this->queriesParts['from']->getColumns()->generate(); |
|
88 | ||
89 | $joinKeyList = ['join', 'joinLeft', 'joinRight']; |
|
90 | foreach ($joinKeyList as $joinKeyName) { |
|
91 | foreach ($this->queriesParts[$joinKeyName] as $join) { |
|
92 | $joinSql = $join->getColumns()->generate(); |
|
93 | ||
94 | if (empty($joinSql)) { |
|
95 | continue; |
|
96 | } |
|
97 | ||
98 | if ($sqlParts !== '') { |
|
99 | $sqlParts .= ','; |
|
100 | } |
|
101 | ||
102 | $sqlParts .= $joinSql; |
|
103 | } |
|
104 | } |
|
105 | ||
106 | $sqlSubQueries = $this->queriesParts['subQuery']->generate(); |
|
107 | if ($sqlParts !== '' && $sqlSubQueries !== '') { |
@@ 109-123 (lines=15) @@ | ||
106 | $sqlSet = $this->queriesParts['table']->getColumns()->generate(); |
|
107 | ||
108 | $joinKeyList = ['join', 'joinLeft', 'joinRight']; |
|
109 | foreach ($joinKeyList as $joinKeyName) { |
|
110 | foreach ($this->queriesParts[$joinKeyName] as $join) { |
|
111 | $joinSql = $join->getColumns()->generate(); |
|
112 | ||
113 | if (empty($joinSql)) { |
|
114 | continue; |
|
115 | } |
|
116 | ||
117 | if ($sqlSet !== '') { |
|
118 | $sqlSet .= ','; |
|
119 | } |
|
120 | ||
121 | $sqlSet .= $joinSql; |
|
122 | } |
|
123 | } |
|
124 | ||
125 | if ($sqlSet === '') { |
|
126 | throw new Exception( |