tursopg: lacks support of the numeric type, causing decimal precision issues
tursopg has issues arising from representing real numbers in floating point. For instance
select 0.1+0.2=0.3;
returns 0 (meaning false) under tursopg [which agrees with sqlite behavior), but under posgresql this returns
?column?
t (1 row)
("t" meaning true) becasuse posgtgresql represent it as "numeric"
select pg_typeof(0.1);
pg_typeof
numeric (1 row)
which according to the documentation supports "user-specified precision, exact; up to 131072 digits before the decimal point; up to 16383 digits after the decimal point"
see https://www.postgresql.org/docs/current/datatype-numeric.html
[tursopg does not implemement the function pg_typof]
tursopg> select pg_typeof(0.1); Error: Parse error: no such function: pg_typeof
tested with: tursopg v0.8.0-pre.11
Source: tursodatabase/turso