1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-07-29 08:01:23 +03:00

Fix a problem with applying integer affinity to a MEM_IntReal value. Forum post [forum:/forumpost/d270125fae|forum post d270125fae].

FossilOrigin-Name: e58bba93717cd6ff950c6f9e077b4327b59b1956dd5f6668be3de9509584b8fe
This commit is contained in:
dan
2023-01-05 13:35:23 +00:00
parent b8a655beeb
commit e3b1c3868b
5 changed files with 50 additions and 29 deletions

View File

@ -95,4 +95,22 @@ do_execsql_test 3.0 {
PRAGMA integrity_check;
} {a {} ok}
reset_db
do_execsql_test 4.0 {
CREATE TABLE t1(a REAL, b AS ('expr') );
}
do_execsql_test 4.1 {
INSERT INTO t1 VALUES( REPLACE(0, '', 'expr') );
}
do_execsql_test 4.2 {
INSERT INTO t1 SELECT REPLACE(4, '', 'expr');
}
do_execsql_test 4.3 {
SELECT typeof(a), a FROM t1;
} {
real 0.0
real 4.0
}
finish_test