varchar to boolean mapping.
abhitiwari1322 opened this issue · 1 comments
abhitiwari1322 commented
I have an existing application with Postgres, where boolean values are considered as TRUE/FALSE. I want to migrate it to Oracle.
Queries like Model.where(attribute: TRUE) are failing because oracle supports either 0/1 OR Y/N.
I consider changing in driver so that queries with true/false behave the same as 0/1 or Y/N.
Expected behavior
Model.where(attribute: TRUE)
It should return data.
Actual behavior
Model.where(attribute: TRUE)
ActiveRecord::StatementInvalid:
OCIError: ORA-00904: "TRUE": invalid identifier:
Rails version: 5.2
akostadinov commented
Why not use a different column type on Oracle?