-
Notifications
You must be signed in to change notification settings - Fork 47
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add binary/blob column support for MSSQL and Oracle #917
Conversation
mvorisek
commented
Nov 12, 2021
•
edited
Loading
edited
- fixes various inconsistencies so all DB vendors behave the same from the DSQL API
- adds full UTF-8 support for all DB vendors
- adds auto drop tables after each test
8da54de
to
a8b8146
Compare
034629c
to
640c85d
Compare
640c85d
to
7eaf533
Compare
44c74a5
to
e4813ea
Compare
3ae9cab
to
b6bca87
Compare
b6bca87
to
e68ec3e
Compare
442ab7d
to
53cccfb
Compare
41f7bed
to
a1aef5d
Compare
fed02e8
to
06a17df
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. Pls check comments.
case 'mysql': | ||
case 'oci': | ||
case 'oci12': |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For some reason which I don't remember now we had separated Oracle 12 support.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a different compatibility layer previously for Oracle 12, but I purged some time ago it in favor of generic layer for Oracle 11 and all tests are run againt this version in CI.
][$dsn['driverSchema']] ?? null; | ||
|
||
if ($enforceCharset !== null) { | ||
$dsn['dsn'] = preg_replace('~; *charset=[^;]+~i', '', $dsn['dsn']) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So we always enforce utf8? What if user database is not utf8? Previously utf8 was used by default, but user could use different charset too.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Because of many hidden issues. UTF-8 is defacto standard. This is about the connection charset, you can store any data you want in binary fields, actually, this is one of the feature thi PR adds and fixes.
|
||
public function groupConcat($field, string $delimiter = ',') | ||
{ | ||
return $this->expr('listagg({field}, []) within group (order by {field})', ['field' => $field, $delimiter]); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Which is lowest Oracle version which supports LISTAGG?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
11g2 https://www.toolbox.com/tech/oracle/blogs/oracle-sql-listagg-in-oracle-9i-022118/
I belive we do not use it Model/Ref thus this version is not strictly required.
} | ||
|
||
$this->assertSame( | ||
['❤' => 'žlutý_😀'], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
wow 🚀 :D