-
Notifications
You must be signed in to change notification settings - Fork 82
Open
Description
Column default values like '' or false aren't used when a value is omitted for that column.
For example, if I have a table foo with a column bar that has a default value of '', and I don't provide a value for bar in my call to bulk_insert, the newly-inserted row will have a bar value of NULL, and not '' like I expect.
The issue seems to be the use of #present? to determine a column has a default value:
bulk_insert/lib/bulk_insert/worker.rb
Line 50 in 3ded6b0
| if column.default.present? |
Jamie5
Metadata
Metadata
Assignees
Labels
No labels