Comments (5)
first: Does your updates for 12c support will also work on lower versions of oracle?
second: Please submit a PR if you can. Don't have time yet to update the package unless we a have a big issue. thanks!
from laravel-oci8.
in file yajra/Oci8/Query/Grammars/OracleGrammar.php :
protected function compileTableExpression($sql, $constraint, $query)
{
// mohammadi Edited
//if oracle 12c
return $sql;
//if old versions
if ($query->limit > 0) {
return "select t2.* from ( select rownum AS \"rn\", t1.* from ({$sql}) t1 ) t2 where t2.\"rn\" {$constraint}";
} else {
return "select * from ({$sql}) where rownum {$constraint}";
}
}
//and the following func was left empty :)
protected function compileLimit(Builder $query, $limit)
{
return "FETCH NEXT $limit ROWS ONLY";
}
/**
* Compile the "offset" portions of the query.
*
* @param \Illuminate\Database\Query\Builder $query
* @param int $offset
* @return string
*/
protected function compileOffset(Builder $query, $offset)
{
return "OFFSET $offset ROWS";
}
////////////////////////////////////////////////////////////////////////////////
// in file :vendor\laravel\framework\src\Illuminate\Database\Query\Grammars
protected $selectComponents = array(
'aggregate',
'columns',
'from',
'joins',
'wheres',
'groups',
'havings',
'orders',
'offset',
'limit',
'unions',
'lock',
);
i've changed the order of offset and limit
:) ok?
from laravel-oci8.
Can you please create a pull request (PR) so i can test and review it on my side? Having a hard time reading the comments :) ... thanks!
from laravel-oci8.
okay but not now i will do that for tomorrow arjay i'm a bit busy :)
On Tue, Jul 15, 2014 at 10:33 AM, Arjay Angeles [email protected]
wrote:
Can you please create a pull request (PR) so i can test and review it on
my side? Having a hard time reading the comments :) ... thanks!—
Reply to this email directly or view it on GitHub
#21 (comment).
from laravel-oci8.
I think this is not highly needed and I may not be able to work on this because I don't use 12c atm. But open to PR's in case someone wants to implement this. Thanks!
from laravel-oci8.
Related Issues (20)
- Materialized view HOT 2
- Case Sensitivity Issue with Alias Names HOT 2
- Improve pagination for newer oracle
- "sessionVars" config are ignored HOT 1
- Binding driver options are ignored when calling addBindingsToStatement method HOT 4
- OCI_DEFAULT Undefined HOT 2
- lock/lockForUpdate locks up all rows even combined with limit (Job Queue becomes unusable on large table) HOT 3
- Updating model with multiple blob columns fails
- DRCP Connection Pooling HOT 4
- Undefined type 'Yajra\Oci8\Oci8ServiceProvider'. HOT 5
- Method Yajra\Oci8\Schema\Grammars\OracleGrammar::compileColumns does not exist. HOT 2
- v10.4.3 introduced SQL error in SELECT FOR UPDATE HOT 4
- OracleProcessor.php function processColumns donot return key "auto_increment" HOT 2
- OCI_SUCCESS_WITH_INFO: ORA-28002: the password will expire within 13 days HOT 2
- Laravel 11 support is on the road? HOT 5
- [11.x] This database engine does not support inserting while ignoring errors.
- [11.x] Error Code : 942 Error Message : ORA-00942, Sessions table HOT 1
- Support PHP 8.3 With Laravel 10.x HOT 1
- Error LogicException This database driver does not support modifying columns HOT 1
- `Schema::dropIfExists()` not working in 11.2.2+ HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from laravel-oci8.