You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm working with a SQLite database that contains some data that needs decimal precision (basically money amounts). In order to keep precision, this data is saved on a TEXT column on SQLite and actually mapped to a decimal when working with EF Core on C# (EF Core does this mapping automatically when using Code First approach).
I'm playing with F# now, and I've found that SQLProvider maps those columns to string (as expected). Is there any way to tell SQLProvider to map selected columns to decimal instead of string?
The text was updated successfully, but these errors were encountered:
I don't think so, but I think you can use cast in your SQL-query like for i in myTable do where ((decimal i.x) > 3m) select i and if SQLite can handle the conversion, then it could work. However, I expect your problem in SQL side is then that you do text comparisons like "11" < "2" ?
I'm working with a SQLite database that contains some data that needs decimal precision (basically money amounts). In order to keep precision, this data is saved on a TEXT column on SQLite and actually mapped to a
decimal
when working with EF Core on C# (EF Core does this mapping automatically when using Code First approach).I'm playing with F# now, and I've found that SQLProvider maps those columns to
string
(as expected). Is there any way to tell SQLProvider to map selected columns todecimal
instead ofstring
?The text was updated successfully, but these errors were encountered: