Index: trunk/phase3/includes/db/Database.php |
— | — | @@ -950,7 +950,10 @@ |
951 | 951 | } |
952 | 952 | |
953 | 953 | if ( isset( $options['GROUP BY'] ) ) { |
954 | | - $preLimitTail .= " GROUP BY {$options['GROUP BY']}"; |
| 954 | + $gb = is_array( $options['GROUP BY'] ) |
| 955 | + ? implode( ',', $options['GROUP BY'] ) |
| 956 | + : $options['GROUP BY']; |
| 957 | + $preLimitTail .= " GROUP BY {$gb}"; |
955 | 958 | } |
956 | 959 | |
957 | 960 | if ( isset( $options['HAVING'] ) ) { |
— | — | @@ -958,7 +961,10 @@ |
959 | 962 | } |
960 | 963 | |
961 | 964 | if ( isset( $options['ORDER BY'] ) ) { |
962 | | - $preLimitTail .= " ORDER BY {$options['ORDER BY']}"; |
| 965 | + $ob = is_array( $options['ORDER BY'] ) |
| 966 | + ? implode( ',', $options['ORDER BY'] ) |
| 967 | + : $options['ORDER BY']; |
| 968 | + $preLimitTail .= " ORDER BY {$ob}"; |
963 | 969 | } |
964 | 970 | |
965 | 971 | // if (isset($options['LIMIT'])) { |