On Friday, June 12, 2020 at 7:44:11 AM UTC-7, Remtech Industries wrote:
>
> I created a column in my table in sqlite3 years ago.
> Migration:
>     Integer :priority, null: false, default: 2000
>
> And I was able to use decimal in that column for years without issue.
>
> Recently, sequel will read 1.5 as 1. 
>
> Was there an upgrade that changed this behaviour? Also, what is a 
> recommendation to resolve this?
>

Sequel assumes that if your column type is "integer", that the values 
should be integers, and converts the value to integer.  The fact that 
SQLite does not enforce column types is probably it's biggest flaw 
(followed by lack of common types such as date and inability to make most 
table modifications).

I think Sequel's behavior in this case hasn't changed significantly 
recently.  What version of Sequel were you using that wasn't doing the 
conversion?  I checked and even Sequel 4 has this behavior.

Thanks,
Jeremy

-- 
You received this message because you are subscribed to the Google Groups 
"sequel-talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sequel-talk/30c40924-869d-4ff7-b34f-f35df3350476o%40googlegroups.com.

Reply via email to