Skip to content

Commit

Permalink
Apply fixes from StyleCI
Browse files Browse the repository at this point in the history
  • Loading branch information
StyleCIBot committed Aug 9, 2024
1 parent c86fb73 commit a2d31c6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Oci8/Query/Grammars/OracleGrammar.php
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ protected function compileTableExpression($sql, $constraint, $query)
}

$orders = $query->orders;
foreach($orders as $key => $order) {
foreach ($orders as $key => $order) {
if (isset($order['sql'])) {
[$column, $direction] = explode(' ', $order['sql']);
if (Str::contains($column, '.')) {
Expand All @@ -195,7 +195,7 @@ protected function compileTableExpression($sql, $constraint, $query)

// If no ORDER BY is specified, use ROWID for ordering
if (empty($orderBy)) {
$orderBy = "order by ROWID";
$orderBy = 'order by ROWID';
}

return "select * from (select t1.*, row_number() over ({$orderBy}) as rn from ({$sql}) t1) where rn {$constraint}";
Expand Down

0 comments on commit a2d31c6

Please sign in to comment.