Fix bit type#723
Conversation
PR Summary
|
Codecov ReportPatch coverage:
Additional details and impacted files@@ Coverage Diff @@
## master #723 +/- ##
=========================================
Coverage 99.77% 99.77%
Complexity 1281 1281
=========================================
Files 63 63
Lines 3045 3046 +1
=========================================
+ Hits 3038 3039 +1
Misses 7 7
☔ View full report in Codecov by Sentry. |
| SchemaInterface::TYPE_SMALLINT => SchemaInterface::PHP_TYPE_INTEGER, | ||
| SchemaInterface::TYPE_INTEGER => SchemaInterface::PHP_TYPE_INTEGER, | ||
| SchemaInterface::TYPE_BIGINT => SchemaInterface::PHP_TYPE_INTEGER, | ||
| SchemaInterface::TYPE_BIT => SchemaInterface::PHP_TYPE_INTEGER, |
There was a problem hiding this comment.
In MSSQL BIT is 1, 0, or NULL only. Can it be problem?
There was a problem hiding this comment.
The changes are only for yiisoft/db-pgsql
For yiisoft/db-mssql it is as before:
https://github.com/yiisoft/db-mssql/blob/master/src/Schema.php#L74C9-L74C38
'bit' => self::TYPE_SMALLINT,I do not know any issues with type bit in MSSQL but if it is required it is possible to change it to 'bit' => self::TYPE_BIT, and cast bit value in ColumnSchema::dbTypecast() or ColumnSchema::phpTypecast().
|
Code moved to |
|
Thank you. 👍 |
For
yiisoft/db-pgsql