dan
fd80fa9b6d
Fix a test case in fts3corrupt6.test. Was failing due to [f1dfbc4f].
...
FossilOrigin-Name: 04b2e47784238008ce9057e2761ded91d895dc16d3bc8a3a3508df98a4769602
2022-06-06 06:17:54 +00:00
stephan
626aa48c26
shell: in WASM mode, permit ATTACH because the filesystem is a virtual sandbox and ATTACH can be used to provide more import/export options. Minor doc updates in sqlite3-api.js.
...
FossilOrigin-Name: f28de5b726999b913b442fa51355d020ba1f1662d2f7978380623c16438eb238
2022-06-06 04:09:44 +00:00
larrybr
f3d6e8fd6e
In CLI, drop .dbinfo command when build options prevent it from working.
...
FossilOrigin-Name: 2512d2f68dfff4d74c881a4102b63ca528e690ad93ab2b4eb1f03ce1d9ac155c
2022-06-05 22:58:40 +00:00
larrybr
b61c2424d7
Create new branch named "dbinfo-guard"
...
FossilOrigin-Name: 8d942ba72ea995d0e8d1f8694bb428e5f919fc75afd3e059a69547e27991d580
2022-06-05 22:40:49 +00:00
dan
93a4b411ef
Fix to test case in fts3corrupt.test. No changes to source code.
...
FossilOrigin-Name: d18818afc6021a32989499c26ab38fa442e5a55e662e39bb06e5c0daa9c65e25
2022-06-03 14:08:40 +00:00
dan
181d75ef9e
Fix a 1-byte overread in fts3 that could occur when processing corrupt records.
...
FossilOrigin-Name: f1dfbc4f7452154ca5190ac22e17fdabebb92833967b11f7dae21b8d3a5857bd
2022-06-03 13:52:53 +00:00
dan
410fac35d7
Fix a problem with flattening and window functions causing an "IS <column>" to be transformed to "IS TRUE" or "IS FALSE" when <column> is a view or sub-select expression that is the literal value "TRUE" or "FALSE".
...
FossilOrigin-Name: 2a952c7738d94e70024e06600fee8c3a49f317f2d02774468019bd7cf9488c8b
2022-06-02 16:26:21 +00:00
mistachkin
bf154369e7
Avoid a direct use of abort() in debug builds to prevent a compilation issue for Windows CE.
...
FossilOrigin-Name: 8eb9a7dd07afc0aef0b7c67054d73e7e821138867d115407b71c985e90d44d59
2022-06-02 02:45:59 +00:00
drh
486191603f
New test cases for row values and RIGHT JOIN.
...
FossilOrigin-Name: 5f0582b90fab9111e4a645c692549c35480e62635c596f8c7fa3466bd22f7235
2022-06-01 20:08:22 +00:00
drh
f89f4efb28
Ensure that subqueries associated with row-values are invoked before being
...
used when processing a RIGHT JOIN. Fix for the problem described by
[forum:/forumpost/087de2d9ec87305b|forum post 087de2d9ec87305b].
FossilOrigin-Name: 5a9465dcc0c23fc2c66cd4898bcdfd5086fe4c71ec19a95db7221fdf7c0bbbbd
2022-06-01 16:05:25 +00:00
stephan
4e5aeb54f2
fiddle: added another UI element to the list of those which are disabled during long-running activities. Added DB.close() binding to the Worker-based wasm binding.
...
FossilOrigin-Name: 5933163ed1a8f996e81023c7c5822655dc6411d30016f37fe8863f760530dc5b
2022-06-01 16:04:29 +00:00
drh
a5d06a3d54
Ensure that all necessary row-value subqueries are invoked while running
...
the right-join post processing.
FossilOrigin-Name: e4e71b4cd4c026fc36f0da1703e6237e6ddd8ff2e08dc3c0011632b9e63098cd
2022-06-01 15:53:11 +00:00
stephan
23aa8ff4de
Minor tweaks to, and consolidation of, the wasm-related build flags.
...
FossilOrigin-Name: f0ad6b1b324f9c0f4340f6cf9584884d1206b56fe1010db43bcbef324e713ea3
2022-06-01 14:52:23 +00:00
dan
f74f4ed5b5
Fix a minor problem in the Tcl "incrblob" command. This does not affect the SQLite core.
...
FossilOrigin-Name: e96feccc21d9b858f076960e029b615809243d0cc3f95db75180feb01887451f
2022-06-01 14:32:05 +00:00
drh
0f4b534b60
Candidate fix for the problem with row-value WHERE clause constraints on
...
a RIGHT JOIN.
FossilOrigin-Name: fdd782a7bb217e2aceda97a588c0d7874ee19885abfcf0658472d6c3387da6ee
2022-06-01 13:32:47 +00:00
drh
6d013d890e
Only include the code for sqlite_offset() if compiled with
...
-DSQLITE_ENABLE_OFFSET_SQL_FUNC.
FossilOrigin-Name: 382cd7e10b2df4216da8f25b55546bc74a963d9834af240f75ec8b8321ba106e
2022-06-01 13:32:05 +00:00
drh
1324b2830e
Fix a typo in a comment in a test case. No changes to code.
...
FossilOrigin-Name: 570efa45dd4c6848dcbd550f78fcaa00b6d84dcffe0a2d12e65ea8ee4468c0e8
2022-06-01 13:01:57 +00:00
drh
0286cdbca6
Additional enhancements to the test cases.
...
FossilOrigin-Name: 55cfad74cace74e541b354228e3ad46e17028213a9f639edf2007c6a8f3ba8fc
2022-06-01 11:58:11 +00:00
drh
47b4969e2d
Fix test cases in the previous check-in to make them postgres-compatible.
...
FossilOrigin-Name: f223ba72b6e02a7ccfd894b4b135f4609b1eb79f547ec279b1c52a6996cd5a73
2022-06-01 11:46:39 +00:00
drh
36c19f7799
Test case for [forum:/forumpost/087de2d9ec|forum post 087de2d9ec] showing
...
a problem when a row-value constraint is used with RIGHT JOIN.
FossilOrigin-Name: d1e3e0d26e302587a6cfcb7aa4fcdefe2b3891037732a0df0d0fe10a14454e00
2022-06-01 11:43:57 +00:00
stephan
ea7a4e4fb3
The Worker-specific variants of the most significant DB-class JS bindings are implemented, most notably various uses of DB.exec().
...
FossilOrigin-Name: 371d6f7497016ca9bf82c8524b4d701ddf1e614b3fb4e69ff63935da0d51ed05
2022-06-01 11:20:07 +00:00
drh
645682a7c7
Move the sqlite_offset() function implementation to be an in-line function,
...
thereby avoiding special case code and freeing up a bit in the
FuncDef.flags field.
FossilOrigin-Name: 1c9812c458bd229c862efe5df1b64fae333da9871c8756b5ae4605a81bcda4b5
2022-06-01 11:05:59 +00:00
stephan
6ffa895884
Initial proof of concept code for a JavaScript binding which runs in the main window thread but acts on a db handle running in a Worker thread. Expanded the DB.exec() and DB() constructor to simplify certain use cases.
...
FossilOrigin-Name: d9efe3e92d1c95aee6f5ae37a8ba28d8cf4891d746744ce4aa2464f766821a0b
2022-06-01 08:09:06 +00:00
stephan
bff17db433
Initial bits for a JS API variant in which the client operates in the main thread and sqlite3 in a Worker. This is far from complete.
...
FossilOrigin-Name: f6d6f969791f0d2367ae5418623b4794f6df657d9d7d9002fb5aec4206dcfd4c
2022-06-01 00:00:59 +00:00
drh
c7fc08f69a
New FULL JOIN test cases. No changes to code.
...
FossilOrigin-Name: 13e89ef6649475815d3f4e4aef73a4be1157dd388e55c7f856faeb4b7387774b
2022-05-31 18:18:09 +00:00
drh
aa03c69591
More JOIN test cases inspired by the problem fixed in [3869fd9a2b9483cb].
...
FossilOrigin-Name: f2d224c5fa06de70f6f22e159a3b7065d4c6b004f9accc13004b9ac1f2fd5549
2022-05-31 17:24:56 +00:00
drh
f51672a945
Fix an assert that is incorrect for a corrupt database.
...
FossilOrigin-Name: fe0a840805b435efd38a953a8aae60e29a35289f9d9955472a8bab2bce7051c8
2022-05-31 15:18:55 +00:00
drh
d69820c42b
Many new PG-confirmed test cases in joinD.test.
...
FossilOrigin-Name: 481e89c764ad8906cd21c8fbe58df57ae40bb3f261fa4892ea7ce7762786ad26
2022-05-31 14:19:04 +00:00
drh
9f67cc26c1
Restore an ON-clause test case (removed by [3869fd9a2b9483cb]) that turns out
...
to be necessary for correct operation. Fix for
[forum:/forumpost/c2554d560bac97c5|forum post c2554d560bac97c5].
FossilOrigin-Name: f407ec678f5bf5bfd20b7ba596472c9a85e6f21383a4cde49af1dae542fff582
2022-05-31 11:22:30 +00:00
drh
c9dfe2b808
Add back in a test case for ON-clauses that was removed yesterday by
...
[3869fd9a2b9483cbf] but which turned out to be necessary after all.
FossilOrigin-Name: aba52a90eef2a5d06e7c499fe84b2efcde7f01e67129058f8223a6a0272aacb9
2022-05-31 11:13:55 +00:00
drh
b1f08bc690
Add test cases for
...
[forum:/forumpost/c2554d560bac97c5|forum post c2554d560bac97c5].
FossilOrigin-Name: e66d5ae86c09cbe581b8f4f1bff33376cc680bba3da24f85384dd6c3eb85ddcf
2022-05-31 10:48:02 +00:00
stephan
5fd9f03291
Updated the wasm builds to generate gzip'ed copies of relevant files to take advantage of althttpd's new capability of substituting gzip files in place of requested files. This cuts over-the-wire size of the fiddle app by more than half.
...
FossilOrigin-Name: 40925585f1dab25babac46a0f4b9d633315110b8d4ccb04cc6df115d167e5ab4
2022-05-31 02:03:29 +00:00
drh
404bf6bac6
For an outer join, then ON-clause constraints need to be evaluated at just
...
the right moment - not too early and not too late. Fix for the problem
reported by [forum:/forumpost/3902c7b833|forum post 3902c7b833].
FossilOrigin-Name: 3869fd9a2b9483cbbf83d8f369c1744abc42f12e63abba402be35dd7e136161c
2022-05-30 17:33:22 +00:00
drh
1943005f62
Apply the UPDATE-FROM file from check-in [98b3816bbaf539ea] to
...
update-delete-limit builds.
FossilOrigin-Name: 7e87892c249f023ee9ed1d5f75a9ad8db10fb38f14dd9e6954b12b9b28400b07
2022-05-28 14:03:23 +00:00
stephan
1a66ff359f
fiddle: changed the internal key of the session/local storage to avoid conflicts with the pikchr fiddle app (which is derived from this one) when running from the same HTTP origin as an instance of that app in a dev environment.
...
FossilOrigin-Name: fd668da5ccf037c2ad8e61e381dd1eb398a8deab42a00593e551c30bd176890d
2022-05-28 11:59:46 +00:00
stephan
e9ab04a446
fiddle: corrected a piece of far-corner-case error handling and made the various checkbox config options persistent.
...
FossilOrigin-Name: 2ba429a4f8300b981b23d54c2bdb54bd4863522c1c18bf9a67a82e3dce845b10
2022-05-28 11:29:00 +00:00
drh
5af8a86d62
Mark an always-true conditional as ALWAYS().
...
FossilOrigin-Name: 3492fe8a212cbe02b9016866e2499b99c3b566a4b0bc91fba267e6e1fe1b8943
2022-05-27 18:06:49 +00:00
drh
abe1ff38dd
Minor simplification to ALTER TABLE logic.
...
FossilOrigin-Name: 01beb0365c529481605f1864b1b6760e2484fad08d56a72e00e34acff37e23f8
2022-05-27 17:36:21 +00:00
stephan
23b34bbc25
Corrected a broken HTML comment (was using a C-style comment closer).
...
FossilOrigin-Name: db742e3e7d1caeff8d9df1d86abf54fcb2f2263db7a433ffacf3cd3777e533c5
2022-05-27 17:13:56 +00:00
dan
ca29bbce2f
Fix another problem with ALTER TABLE and UPDATE...FROM in triggers.
...
FossilOrigin-Name: 33cf12235e6469ba17cfb72cef0e480dfd0dea81ed412fb1fb24b05dbeb8dc02
2022-05-27 15:33:51 +00:00
dan
4209d553e7
Fix further issues with ALTER TABLE and triggers that contain UPDATE..FROM statements.
...
FossilOrigin-Name: 53fbc269ddbabc4a97d297e881e5f9cd2bfbcd24af4af1b7cf9db412a3a51813
2022-05-27 15:04:43 +00:00
drh
8d2f661ab8
Omit an unnecessary branch.
...
FossilOrigin-Name: f56473f9cc1b476b3219fe5b70ba2e4b269b20c880b99ba34c744ed893042081
2022-05-27 14:41:48 +00:00
stephan
cd69784646
fiddle: added an option to completely wipe/reset the db. The Options area can now be toggled on/off via tapping the label at its top. Running the input SQL is now limited to the selected area if any text is currently selected, per suggestion in the forum.
...
FossilOrigin-Name: d100283e378f2d8e353399848184a4ab8ccf6316218fffc28b90a656cf81c279
2022-05-27 03:27:10 +00:00
dan
b8bbe3e2db
Fix issues with ALTER TABLE and triggers containing "UPDATE...FROM" statements.
...
FossilOrigin-Name: 2fba0d41b781d226915fa2bf888a7bc640c046ce22670ceb53f62a09f3975259
2022-05-26 19:10:11 +00:00
drh
26c4df0fb0
Correct handling of outer joins in the FROM clause of an UPDATE statement
...
that occurs inside of a trigger. Follow-on to [98b3816bbaf539ea].
FossilOrigin-Name: 664a49fa813144b6fa5a7ae3f65af5412f150dd5def261c4d581d706b39f7846
2022-05-26 17:33:42 +00:00
drh
e91bde4655
Clarification of the meaning of the N parameter in sqlite3_db_name().
...
Documentation only. No changes to code.
FossilOrigin-Name: f22f41d2c8a676b9a339e7f00c29c163bbb7079b1a4a76ee1a6a96aaf7de5f9e
2022-05-26 14:46:09 +00:00
stephan
78907bba3e
Fixed a minor cut/paste mistake in the previous checkin. Affects only internal docs.
...
FossilOrigin-Name: 37e3764839b968456f576fad67d3d99007773f5c0689165ecbdc610fcabef1ca
2022-05-26 05:18:33 +00:00
stephan
c121e087f3
Makefile.in: added explanations, intended for maintainers and hackers, of the various emcc flags used for building the wasm files. No code or build rule changes.
...
FossilOrigin-Name: 1a159159094d6357b3cadbb8e5499cec4de35ef382c03fcc45c11daee906c3d6
2022-05-26 05:08:25 +00:00
drh
724e298e9c
Slight increase in the accuracy of log10().
...
FossilOrigin-Name: c48a735bd4a1dbd541aed5937c25fc0c606c4263d8ee94cae30a06b1a7b26d9a
2022-05-25 13:10:29 +00:00
drh
7bfbd2508c
Do not allow the right operand of a RIGHT JOIN to be reordered with other
...
FROM clause terms that are even further to the right. Fix for the issue
identified by [forum:/forumpost/5cfe08eed6|forum post 5cfe08eed6].
FossilOrigin-Name: 4be0c60e38edc5d5bfd72bb35a3c91c55240b4e6313a40614beb60f1ab9d9f4c
2022-05-25 12:49:59 +00:00
drh
361e0ede47
Add in a VdbeCoverage() macro accidentally omitted from [d64ae49a1f251317].
...
FossilOrigin-Name: 18b5cea0392a28f694b8931a80e93518f8d3d297d787fa44d1544e373f76838e
2022-05-25 11:17:13 +00:00
drh
ddcdf0b0dd
Fix the UPDATE-FROM logic so that it works the same as PostgreSQL when the
...
FROM clause contains an outer join.
FossilOrigin-Name: 98b3816bbaf539ea745456e1c0064e47d2903d33ee0ceb029bdb97d56fcde937
2022-05-25 11:09:07 +00:00
stephan
26542e722b
Got the sqlite3-api JS bits wrapped up in deferred-load module. Whether that's going to be easier to use, in practice, remains to be seen. Consolidated two of the test-related JS files.
...
FossilOrigin-Name: dd83cc05f2522d221641807dd66b33df48ac9264f27e5b6f63f312084f109801
2022-05-25 08:51:07 +00:00
stephan
e599cc427f
Renamed EXPORTED_FUNCTIONS.sqlite3 to EXPORTED_FUNCTIONS.sqlite3-api to avoid any potential confusion about that file (not) being an sqlite3 database.
...
FossilOrigin-Name: 3d6245c6f9f2ef4ca6746639d300cc5795598b119034439dfed671de3da638fb
2022-05-25 04:38:35 +00:00
stephan
085c5c6b43
Add the ability to import/export db files into/from fiddle.
...
FossilOrigin-Name: e0c30438a4f1372afb93a0488bae17b3f85d535717b215f494a83ae909871d2c
2022-05-25 04:35:22 +00:00
stephan
d0b22b81c8
Further minor cleanups and docs in the fiddle app and worker.
...
FossilOrigin-Name: 199e01799dfa48e3fddafb7f2ae5360604150a44186d5c5a977e158ad8e7e657
2022-05-25 04:20:08 +00:00
stephan
79669c25c4
fiddle: refactored so that it no longer exposes any global symbols. Doing so with the main sqlite3.api module will be much tricker.
...
FossilOrigin-Name: cd227be805d0cd4b6e3c72ed0992ad3aec3db9c366909d9d82c6d3a29009c6eb
2022-05-25 03:08:22 +00:00
drh
fb98dac04f
An attempt to get UPDATE FROM working when the FROM clause contains a
...
RIGHT or FULL JOIN.
FossilOrigin-Name: a124e4f96f883d8682ba7a253d33a9565ed0fc3580525225b95733bd3782a806
2022-05-25 02:32:11 +00:00
stephan
80bf86967f
fiddle: added support for exporting (downloading) the current db file. To do this we had to fall back to named dbs, instead of defaulting to an in-memory one, but the virtual filesystem is an in-memory FS, so the end effect is the same.
...
FossilOrigin-Name: 7c7fd34c8a05832a3973aaffe696250cb4d2a0b1646c9bfbe83970daf33cd817
2022-05-24 22:16:12 +00:00
stephan
de1e02ee52
fiddle: initial work on loading a client-side db file. Works but requires some cleanup. Export is not yet implemented.
...
FossilOrigin-Name: 0fa8378c006fcf2311772d36cf2e3c2cd8e8648f671de89ee9832e2e1a06ef49
2022-05-24 19:01:21 +00:00
drh
6af03b469e
When an ON clause on an INNER JOIN references a table to the right of
...
of the join, just convert the ON clause to an ordinary WHERE clause term,
in order to be compatible with older versions of SQLite. See
[forum:/forumpost/687b0bf563a1d4f1|forum thread 687b0bf563a1d4f1] for details.
FossilOrigin-Name: 2b6ebba26d936ae7b9acf7d4bd15e82cbfabda22e1044b3dd838c7b07095100e
2022-05-24 16:05:41 +00:00
stephan
73c6ad1920
MoUse re descriptive var names in ext/fiddle/Makefile.
...
FossilOrigin-Name: 2f9a42fb141d386f6edd03a37da3b0cef63dcc9fbfd076076b5330a8aa7d45a8
2022-05-24 14:45:16 +00:00
stephan
400ee2ecef
fiddle: lots of generic refactoring, restructuring, and cleanup in the higher-level code. Added push-fiddle ext/fiddle/Makefile target to push the fiddle app to a remote server via rsync.
...
FossilOrigin-Name: ed19fef3459499abb0a4a010f368b4576d6e068d930c8480446ea677ac87c1c1
2022-05-24 14:36:45 +00:00
stephan
2f6a729d55
wasm/JS: minor doc updates, corrected bind()ing of the undefined value to behave as documented, removed some superfluous code.
...
FossilOrigin-Name: 526c8c728019b317624a93f6f07840ca524bca84e7c03ce5e86e38953146236f
2022-05-24 01:15:21 +00:00
stephan
64f0e9376b
wasm/JS: documented DB.selectValue() and corrected the fetching of NULL columns via Stmt.get().
...
FossilOrigin-Name: 70f91fab825d365f505750acdb8d3ae532880c4cdb64d1e61bb21b24a115958b
2022-05-24 00:35:18 +00:00
stephan
a240a24ad0
wasm/JS: added support for scalar UDFs. Fixed a deallocation problem with bind()ed strings/blobs.
...
FossilOrigin-Name: 325a9ee31ad7abae563c4da5cd8228e151b00aa9afcac7e9bca5efaa9d48e107
2022-05-24 00:22:10 +00:00
stephan
e145136a4e
wasm: minor refactoring and doc updates.
...
FossilOrigin-Name: 6044605b2a712da73600cabb967797a03ed1915dc0ab0b10edbd52525e548196
2022-05-23 19:38:57 +00:00
stephan
325b56b504
fiddle: cleaned up and documented the status-loading progress mechanism in prep for reusing it in the sqlite3-api worker.
...
FossilOrigin-Name: 107e3497869d757265f2a4235082bf324ba1220075d1096c2a82021a5d348a6c
2022-05-23 16:54:18 +00:00
stephan
dc5888e04a
wasm: added missing 'use strict' and fixed an undeclared var use caught by that.
...
FossilOrigin-Name: c16a7f4950d47c2f5177db7dc5d83f0f11eb0cafdce1ec688d6f1bd740d92733
2022-05-23 13:55:39 +00:00
stephan
192201d2ed
wasm: corrected isSupportedBindType() to behave as documented.
...
FossilOrigin-Name: 7e2d2e807272e98e9a3c9c9ba492b796a603f36b7cc12b16923cd8a9e6579851
2022-05-23 13:52:36 +00:00
drh
ea488b1258
New test cases to further demonstrate the difference in name matching rules
...
for LEFT JOIN versus RIGHT JOIN that protect legacy behavior.
[forum:/forumpost/e90a8e6e6fa652ac|Forum thread e90a8e6e6fa652ac].
FossilOrigin-Name: 2c586060a016f5481bad29bfb8f4ac4e1204075afdd0fa1851fbbcf2abda4893
2022-05-23 12:37:54 +00:00
drh
51e5d447ba
Add an assert() to clear a harmless static-analyzer warning.
...
FossilOrigin-Name: 919ba2f0472e12c2d1e82364c1481e778b24ea406615b08992964a4eb80abee7
2022-05-23 11:51:10 +00:00
drh
43baa1de76
Do not run the subroutine that materializes a view or subquery until just
...
before the materialization is actually needed, so that if the materialization
turns out to never been needed, unnecessary work can be avoided.
FossilOrigin-Name: d64ae49a1f2513171d678259928c67741d79b2ae595078299525641a676cc46b
2022-05-23 10:57:20 +00:00
stephan
71eacead76
WASM: removed the in64-related bindings, as MDN says that calling a wasm function which has an int64 type in its signature will currently throw because JS has no 64-bit integer support. Those bindings now use doubles and simply hope that the user doesn't exceed their integer precision (2^53-1, approx 9 quadrillion).
...
FossilOrigin-Name: 392e84828275ec203bc713d3a5d4790852add57539add6b29b5f6de1da2dc97a
2022-05-23 01:11:49 +00:00
stephan
c21c0e2af9
WASM: an arg handling fix for DB.exec({multi:true...}).
...
FossilOrigin-Name: 0d6332f706ec5c34cc6a9ff79878f4e10a9ad81b24cc7d743b52168586285811
2022-05-22 22:10:38 +00:00
stephan
744a65cf7d
WASM: added exec(), execMulti(), and several getters. Various touchups and fixes.
...
FossilOrigin-Name: b790c91b85e9cf8eecce86ac1717e8ccd2c3b6b98a1ad6a5d64eefc94ee86f9d
2022-05-22 22:00:39 +00:00
stephan
f6868562ce
Implemented Stmt.get() and friends for WASM OO #1 wrapper. Added basic tests for prepare/step/get. Restructured module init output to introduce only 1 global-scope symbol instead of 2.
...
FossilOrigin-Name: 601dc3fa29c2ce2ede5a8320c79050305f3774b6d7bc759247c5021f3b74aaec
2022-05-22 19:09:59 +00:00
stephan
40b5b19a0f
WASM: added bindings for sqlite3_compileoption_get/used(), moved OO #1 into sqlite3-api.js since it can only be used from the same thread as that API and separating them complicates client-side use. Started adding test utilities and tests for the OO1 API.
...
FossilOrigin-Name: f3bc0328c87cac7d50513b0f13576d8fe7b411396f19c08fbe7e7c657b33cfbf
2022-05-22 16:25:43 +00:00
stephan
d60b7275c3
WASM OO wrapper #1 : prepare() and bind() APIs are in place but are untested, pending fetch/get APIs.
...
FossilOrigin-Name: 84c8f63a1c446331a3afe52b0c8bdfa6980f24aa4cf600f576877fef5e650c39
2022-05-22 14:07:44 +00:00
stephan
166542cc98
Build refactoring for the fiddle/wasm bits. Set up wasm binding of a chunk of the core C API and added some infastructure for creating test pages for it.
...
FossilOrigin-Name: dea098b64eb95c395b346ebcae687afe42b7d21df48833527808c02226300a66
2022-05-22 00:27:19 +00:00
stephan
4ec29fc115
Minor fiddle-related build restructuring to support upcoming development of the C-style wasm sqlite3 interface, plus some commentary about the plans and goals for that.
...
FossilOrigin-Name: c7cfdd4c3682659352642461d3307bf8180703b121ec1802ba5881f8e1ef9809
2022-05-21 21:13:44 +00:00
drh
40822eb262
Defer materializing a view or subquery until the materialization is actually
...
needed, so that if it is not needed, not useless work is performed.
FossilOrigin-Name: 16bf350683fd6ac906dbd02b21fb8bf1b1014ed05594cacf108645acd383ae65
2022-05-21 18:03:33 +00:00
drh
660dfbdcfb
Fix a typo in a comment.
...
FossilOrigin-Name: 34d7045b2cc8ef16fd4115499888703a376d2c3a289e7fdd117f8341ffa586c3
2022-05-21 15:54:45 +00:00
drh
b800bd63aa
Use the newer OP_BeginSubrtn opcode instead of OP_Integer to start the
...
subroutine used to matrialize a view. This does not change execution but
does make the byte code a little easier to read.
FossilOrigin-Name: cebd4fd606f967de527cff79df8e80e16d06eec257939322f16d21303868fb4d
2022-05-21 15:12:41 +00:00
stephan
4257373f6d
fiddle: refactor into main thread (UI) and worker thread (wasm module). Added bits needed to support triggering sqlite3_interrupt() but do not yet have a second SharedWorker to test it with.
...
FossilOrigin-Name: 5ff3326856bc190cee15a5fca5ded89aacc4bf931a8df98726a872b310e2a4fc
2022-05-21 14:19:05 +00:00
stephan
0592b20faf
fiddle: add a selection list of example queries.
...
FossilOrigin-Name: 74abf03977e1ff8c6043defa38211cdfcfbba1979771b90ed9d3dbc99750fe9f
2022-05-21 00:45:46 +00:00
stephan
2eb454147a
In the shell WASM build, call open_db() early so that we can get access to the global db handle from certain experimentation-only function without having to first run some SQL code.
...
FossilOrigin-Name: 31706ef851f7d55e2fe865933ec03f42dfa8b49e6d1f12b6c016b5c1d3460504
2022-05-21 00:01:45 +00:00
stephan
056b72a988
Added the standard sqlite license header to the the fiddle JS files. Minor internal renamings in those same files.
...
FossilOrigin-Name: 67e40d99ff84a6cb23c68bf0722a4f9dee29b8ad18d9e7aac7d1665e99901ba1
2022-05-20 13:50:04 +00:00
stephan
e26d162402
#if'd out the '.nonce' and '.check' commends in WASM builds.
...
FossilOrigin-Name: 326f79ea54566a9302be99d920856f13b48f2c2ed265fa87d78ced367d4b1946
2022-05-19 22:04:23 +00:00
stephan
1c0dcec4c5
#if'd out the the '.cd' and '.clone' commands for WASM builds.
...
FossilOrigin-Name: fa391868dd626ffdb220bed6834d0a10c7336f0fc4ca56055147784de1a4f99d
2022-05-19 21:56:50 +00:00
stephan
2f72d711ac
fiddle: consolidated two duplicate CSS rules. Internal doc typo fix.
...
FossilOrigin-Name: d3175a793fb2d1ac9ecfd7a7c3b1627fe583effcd37740206a11b115f099d521
2022-05-19 18:14:34 +00:00
stephan
091fb16e09
Added a disclaimer about fiddle's experimental and subject-to-change/removal nature.
...
FossilOrigin-Name: 75b4f574089c4969d2f2c3615a52029e98515e36390c530cdf63f15f4f687a1d
2022-05-19 17:47:17 +00:00
drh
9d023c227f
Merge the changes to support the "fiddle" extension.
...
FossilOrigin-Name: 58585f01aa4747d3a09771fb462066bd037914f435ff04fa16ed9b0571e7912a
2022-05-19 16:59:46 +00:00
stephan
d59ac28d4f
When building fiddle from its own directory (e.g. from emacs instead of the normal build process), force -O0 the sake of compilation speed. The top-level build now defaults to -Oz, which is more appropriate for that case.
...
FossilOrigin-Name: 56b82ae806c61b95e62042ca70ed952ce01832b02da55c2b315f9201989514ab
2022-05-19 16:49:15 +00:00
drh
7db1289b0f
Tweaks to the fiddle make target so that it builds with all of the same
...
extensions as the standard CLI.
FossilOrigin-Name: d46a6cb97406d90b9ad1da66369454e9b8f387ffbebcdf1c386c3c21f790c16f
2022-05-19 16:42:41 +00:00
stephan
2d0a85c5de
Added a toggle to swap input/output field positions and simplified setup of checkboxes which toggle a CSS class on a given element.
...
FossilOrigin-Name: eae3ab10c813d6f051d497271be2df05f54005ec54b19a2a27d04d632bccbeac
2022-05-19 16:30:03 +00:00
stephan
e9e0208561
Default to top/bottom layout with input on the bottom. Offer a toggle to swap input/output positions.
...
FossilOrigin-Name: 362d236aca31ca2004d1e81d8e306f7a12a6cb4eeb2bab432a9c2aae5206ddd7
2022-05-19 16:11:35 +00:00
stephan
38240592ad
Numerous layout tweaks, the most significant being that the layout now adapts to the window size. Swapped positions of the input/output areas. This version supports, by uncommenting a few bits, a jquery.terminal-based view but alternatives to that 300kb dependency are still under investigation.
...
FossilOrigin-Name: 1aad3642c9fc14c25223628a309d84decc8d73a123e42d6efdc36d855b5b0666
2022-05-19 15:58:13 +00:00
stephan
6da6f31cca
fiddle make target now accepts fiddle_cflags=... from the CLI to overrid -Ox and such for one-off builds.
...
FossilOrigin-Name: 4609a4f8626ae3d8179cae27e391bd06ffda18e9ef9e1b78745b36c7e8dd25db
2022-05-19 10:58:59 +00:00
stephan
403445be23
Ensure that the output area is cleared of any init-time messages which the emscripten bootstrapping process emits when downloading of the wasm module is slow.
...
FossilOrigin-Name: 1d8d0593573f9fc8e0990a292a4b3317d8a4c323d60514d0768543dd65c24d1e
2022-05-19 10:38:54 +00:00
stephan
618a375e9f
#if'd out the '.log' command in WASM builds. Cleaned up the user-visible parts of the WASM module initialization.
...
FossilOrigin-Name: b5fa12f824690c1022e4d69b0f5c3949324b311557a7412810741731db7e2cce
2022-05-19 10:24:50 +00:00
stephan
0fb074ab61
Split the fiddle JS code into separate pre-/post-init files to simplify editing. emcc will combine these into the final fiddle.js, so the number of output deliverables does not change.
...
FossilOrigin-Name: d3d8ea011868bcfa11bb3fe2db78eea6e77ac1005534d9c091f9a81e03f0a7e6
2022-05-19 09:55:14 +00:00
stephan
b8a2b20509
Added an option to auto-clear the output area before submitting the input. Experimentally inverted the colors in the input/output areas.
...
FossilOrigin-Name: 1a1e4e7fdbd0ec61218c3a311164086316d825181f3fc1c1ec235b63488746ef
2022-05-19 09:22:16 +00:00
stephan
9af6beb977
Replaced the toggle for the notes/caveats section of the fiddle UI with a button to remove that section.
...
FossilOrigin-Name: 6661d60527820417bbfd01c782d242c5190252ea703fc6f56376537d5c8f6a1e
2022-05-19 01:12:23 +00:00
stephan
29f2458aae
#if'd out the '.import' command in WASM builds. Several minor cosmetic UI tweaks.
...
FossilOrigin-Name: e4f87eb7c3ed16b7e431f86b7d337bb4097246d20780207b43e28fffda3d8a61
2022-05-19 00:38:34 +00:00
stephan
348f7420b3
#if out the '.load' command in WASM builds. Several UI layout tweaks.
...
FossilOrigin-Name: 67d98297f01d4274c510f5c5cb2a219aeb36fcbb7ce78b8b9ed65639a4561c73
2022-05-18 23:40:27 +00:00
stephan
02520cc8f6
In wasm builds, ifdef out shell commands which require file I/O, pipes, or which trigger an exit() (.quit and .exit). Documented some of the quirks and limitations of the C/WASM crossover. Keep the JS code from calling into the C code after an exit() has been triggered.
...
FossilOrigin-Name: bee436e62a956e49b0df4a92abff2c89f2b44e21d8f593716df0331f8fc49814
2022-05-18 22:58:34 +00:00
stephan
b0dae2b3c3
Improved handling/reporting of conditions which trigger an exit() from native code, e.g. calling the '.read' command. Added a Help button which simply submits the '.help' command. Added commented-out variants of various -Ox flags to simplify experimenting with them.
...
FossilOrigin-Name: bf06ddf4125d2726019fa16d312726c8551094be991509499b5688f6a68a7747
2022-05-18 21:18:21 +00:00
stephan
0076e49700
Code style fixes: s/char const/const char/.
...
FossilOrigin-Name: 9bf042b2eb2137239a59e421e89eb463e719b264eac3db2adae44e321b9a4ad3
2022-05-18 18:10:17 +00:00
stephan
8ae45e4c6b
The fiddle input/output areas now stretch and shrink as needed to account for their available space.
...
FossilOrigin-Name: 4eec05457fabe8248b8fd48d6187e772b69429ed64e99f02d0ad6b1230b5835e
2022-05-18 17:40:19 +00:00
stephan
9f69b9411e
Increased default size of the fiddle output area, changed the .nullvalue default in the input area, and minor CSS tweaks.
...
FossilOrigin-Name: 281aaae73167828bdf0bb2c07f83622475ab29b5755ac7fb8584c8e919c0a09b
2022-05-18 17:22:02 +00:00
stephan
f8cd3d2b5c
Initial version of an sqlfiddle-style application using a WASM build of the sqlite3 shell.
...
FossilOrigin-Name: af9c21c9e0caf05adac7a9fcde39a9164c89f1c78b767b6fdd74a1405a3d373f
2022-05-18 17:14:24 +00:00
drh
b8b2d9c5e1
Fix harmless compiler warnings in the new unixFullPathname implementation.
...
FossilOrigin-Name: f7e1ceb5b59a876cfd04a8aac0ee2b322c970555b9c361b4953d711ef6596e37
2022-05-17 15:11:57 +00:00
dan
5348fbe332
Avoid treating constant expressions like "? IN ()" or "? NOT IN ()" as integers if they appear in a GROUP BY or ORDER BY clause.
...
FossilOrigin-Name: d8b249e8cdf0babe1427d0587dbdc27a52ec06a5ef3a20dfb05a0ea4adb85858
2022-05-17 15:01:01 +00:00
drh
ff16267d7d
Add the sqlite3_db_name() interface.
...
FossilOrigin-Name: 2ad152236c408cbb1f942b221de4bf3cbaa9c35313d7eb07a63f46b6040fc981
2022-05-17 14:59:05 +00:00
dan
c7d7ebd755
Add memory barriers to multi-threaded code in test4.c.
...
FossilOrigin-Name: 9260f4e0fdc8066b4772999bacb5f4130ef714d4ac1967029ceacff618bc48ff
2022-05-16 16:55:22 +00:00
dan
07576c3fe8
Fix a problem in test file swarmvtab3.test causing occasional failures.
...
FossilOrigin-Name: f935c155ef205802c16b4ebea4a3fb01bf5689662b7b4f2af56f0f9021d6d4b1
2022-05-16 16:10:04 +00:00
drh
96d5549778
Do not allow an index scan on an index-on-expression for a RIGHT JOIN because
...
the index might not be positioned on the correct row when running the
the right-join no-match loop.
dbsqlfuzz 39ee60004ff027a9e2846cf76e02cd5ac0953739
FossilOrigin-Name: 2277f9ba7087dd993ac0f4007c523aa9cf74dba187f53af03d8c164886726fee
2022-05-14 19:05:13 +00:00
drh
d83997ba7f
Improved debugging comment generation for the OP_Column opcode.
...
FossilOrigin-Name: 3e073bfddfcd652dfae8656d8978a4de427d21847fdaccfce53b6b895ad33f01
2022-05-14 17:40:47 +00:00
drh
c93bf1d462
Improvements to the decision of when to check ON constraints for an inner
...
join that is an operand to a RIGHT JOIN. Fix for issue identify by
[forum:/forumpost/c06b10ad7e|forum post c06b10ad7e].
FossilOrigin-Name: 9d17233c7d98bf25c1a518d067e778708b3db6d6302edd8d7e376ba0ba4f1c30
2022-05-14 15:59:42 +00:00
drh
086b800fcd
Change an unreachable branch into an assert().
...
FossilOrigin-Name: 778e57a558dc3f819ca57623bcb85f58c8fbeb28bc12a1e2edbdd1244e9107c5
2022-05-13 23:01:28 +00:00
drh
556527a154
Transitive equality constriants do not work on a RIGHT JOIN, since the
...
right-hand side might be a non-matched row.
FossilOrigin-Name: 0f96810b840dd6f209562635b21f55a7ed6210c01336fcfeb3b79e08a615a28d
2022-05-13 20:11:32 +00:00
drh
f69dad8c53
Walk back the optimization from check-in [cc458317bd77046c] that tries to
...
reuse the same ephemeral cursor of a list subquery when that subquery is
reused, as it does not work in cases where the list subquery is used both
for lookups and for scans.
FossilOrigin-Name: 12ee29d632ae4b585ef6bc07d3289d00c121268945dffd5673b251d95874e3f8
2022-05-13 19:50:29 +00:00
drh
767bc8de8e
Defer generating WHERE clause constraints for a RIGHT JOIN until after the
...
ON-clause processing for the RIGHT JOIN has done its own row elimination.
This fixes and incorrect output from some RIGHT JOINs that was identified
by [forum:/forumpost/41cc3851d864c5e6|forum post 41cc3851d864c5e6].
FossilOrigin-Name: 238d9c247cf69cc77fdb1af9d42ebe258610a533ac4204e2ddf8af17f24d18c4
2022-05-13 17:45:52 +00:00
drh
a6e8ee12e2
Redefine the acccess rules for the Expr.w union so that the Expr.w.iJoin
...
member is accessible on either EP_OuterON or EP_InnerON.
FossilOrigin-Name: 6f741d6cfb8831a3ac966257ac4519bcc8156293447bf50323c2d9b170125974
2022-05-13 16:38:40 +00:00
drh
f8d2745f99
Corrections to the header comment to the new joinE.test script. Add the
...
generator TCL as a comment at the bottom of the script.
FossilOrigin-Name: 2f4456f67f64f131fc852ad9a7420eb43b57b879a9bec7e4b295f1dc0d7bfa56
2022-05-13 15:36:47 +00:00
drh
d383557960
New test cases for outer joins. Case joinE-32 currently gets an incorrect
...
answer. See [forum:/forumpost/41cc3851d8|forum post 41cc3851d8] for the bug
report.
FossilOrigin-Name: 02b24863e6dc617c9260f79292a96b7c861d088268e77fd17204570515eb792c
2022-05-13 15:31:30 +00:00
drh
67a99dbee8
Improved names for flags on the Expr object: EP_FromJoin becames
...
EP_OuterON and EP_InnerJoin becomes EP_InnerON.
FossilOrigin-Name: 1ffea07ff98b894729c698b681cc7433df3bbfccd8a0529a706908602a636937
2022-05-13 14:52:04 +00:00
drh
8b0e5c3c7e
Fix a harmless compiler warning in the CLI.
...
FossilOrigin-Name: 7a2ac303d1436a423a635db63d195097c88160ff46855194f6e630f9d3b3fa82
2022-05-12 17:09:33 +00:00
drh
d631c6af80
Ensure that ON clauses are applied to the correct outer join.
...
FossilOrigin-Name: c7e3a13a3288c577209be99c630fbe924e19880e8af1aa8a83b517acaa8b43d7
2022-05-12 11:56:44 +00:00
drh
902e2602c2
Add IS NOT DISTINCT FROM and IS DISTINCT FROM binary operators which are
...
equivalent to IS and IS NOT, respectively, for compatability with PostgreSQL
and hence standard SQL.
FossilOrigin-Name: db27611e172102483eaede3981d473e3d5bf93d98bc68f480398b1573876349d
2022-05-12 11:45:20 +00:00
drh
d59a388b61
Fix the ".echo" command of the CLI so that it shows the results of input
...
lines immediately, before invoking sqlite3_prepare().
FossilOrigin-Name: cf7fdabdba3a7600ea730263ca80ba80154645dfa15c31c037b780d6cb70e530
2022-05-12 11:01:41 +00:00
larrybr
175fdcb912
Zap stray --help output from intermediate version.
...
FossilOrigin-Name: deb7372b18cc8fb9d305085498fd24b3c2c17bd920ae2d03fa885af02ad47008
2022-05-11 20:29:32 +00:00
larrybr
f4874818a4
Change .echo on effect so that SQL is echoed before prepare. This slightly alters echoed output when multiple SQL statements are submitted at once. Also sync with trunk.
...
FossilOrigin-Name: c1eff632c41809214edea2850a93852fff66da3ca0dc393e8fe55e0976d422fd
2022-05-11 19:59:31 +00:00
drh
6868bca6c5
The unix interface now resolves all symbolic links in filenames before
...
actually using those filenames.
FossilOrigin-Name: d55273e36e312336b8fc77dc771657d3b2c3437fbbd79f3be37701982560d634
2022-05-11 17:57:43 +00:00
drh
b302c065d8
Use osReadlink() in os_unix.c, not readlink() directly.
...
FossilOrigin-Name: c3da4c1611cebd9f9d695892a3ffddc47d5f0db1a1ea8bd2b4f83ef7673b68de
2022-05-11 17:45:50 +00:00
drh
e8346d0a88
For the unix VFS, rewrite the xFullPathname method so that it automatically
...
resolves all symbolic links, rendering a canonical pathname that contains
no symlinks.
FossilOrigin-Name: 40c9273d0e0e74e1df22e996a5d486e838f4320defd2121e2d95eeed8aea6235
2022-05-11 16:46:27 +00:00
larrybr
d647819034
Fix .import leak in CLI and add shell leak testing to debug builds and the Tcl test suite.
...
FossilOrigin-Name: df842ebc796a2b0c913d19d873e88d048808dc5283465271369e302a680317e4
2022-05-11 03:42:38 +00:00
larrybr
51b011d8d5
Sync w/ trunk
...
FossilOrigin-Name: 1284225b0a8c7b630416be5348e99f7280f6443548ec97ffb1c85be23352b2bc
2022-05-11 03:29:52 +00:00
drh
cc212e4450
Fix a bug in the sqlite3WhereMalloc() routines that were added by
...
chekc-in [f237e1d8cc41b937]. The bug was detected by dbsqlfuzz
test case 4c5e3e89bc251d28378be88233f531b84ec66901.
FossilOrigin-Name: 764b71267e0b31ff7eaf2a0def7526a1a02dce4d5b456dea060d97ed342efdd1
2022-05-10 23:28:12 +00:00
larrybr
73b7af0437
Make tester.tcl work on more Windows Tcl installations. And sync w/ trunk.
...
FossilOrigin-Name: d25fbdf8772f1c8283828424b208fc1758c82e9e28e0e52122c87db4af1c672d
2022-05-10 22:32:27 +00:00
drh
825ecf9c05
New requirement marks.
...
FossilOrigin-Name: e8479e56c615a6eb38b58e6d360bea8528ec14a9d7b0798b95d3eb513bd08f0f
2022-05-10 18:43:54 +00:00
drh
0338f53b05
Fix a stale requirement mark.
...
FossilOrigin-Name: fcda7fb1f184a31a67572aae15f3cdcd60f8aac199106a7b0f90aca251ca7017
2022-05-10 18:18:45 +00:00
drh
d2b960cf41
Fix a stale requirement mark.
...
FossilOrigin-Name: 3eda4030f73384abf18b97cd8a4606e10b23e382d1b72dff7526aebfde23e0af
2022-05-10 17:42:55 +00:00
drh
de695eab88
Fix a harmless UBSAN warning.
...
FossilOrigin-Name: 8f9355028bc7baeeb10ee9a5e29f093adac6c2f149596dec0be827be4ce491cb
2022-05-10 15:55:10 +00:00
larrybr
1607ac3357
Sync w/ trunk
...
FossilOrigin-Name: b7285f92bb9bfd8471e51ee5b6dbd7030b1f731683876e8ecca4a8c033688736
2022-05-10 14:57:38 +00:00
larrybr
527c39de80
For CLI, add ".echo sql" dot-command.
...
FossilOrigin-Name: 35cef458ca114649ee16e00714d817d57673b96c007454946cc411ae90fd06ce
2022-05-10 14:55:45 +00:00
larrybr
be7777f4a5
Sync w/trunk
...
FossilOrigin-Name: 536691ed0f76ac37f3d86e4f5b1cff15ce4c011f84cd3452b5b45bafb6bf2522
2022-05-10 06:04:48 +00:00
larrybr
f015a3d19f
Cause most shell tests to be run under Tcl suite valgrind config.
...
FossilOrigin-Name: cd085b36ff777396ac2705c030c1518f8094a70a0b0ba4a628776429524d20f0
2022-05-10 01:11:51 +00:00
drh
adef15986a
Simplified "hidden" and "no-expand" handling in the *-expander.
...
FossilOrigin-Name: c6c3115f3a008cf9b0d7c5c812f17e38c8a75a904032c5f05f0bea03a7340527
2022-05-10 00:24:01 +00:00