Commit Graph

175 Commits

Author SHA1 Message Date
dan
43eafb7b76 Fix a problem with UPDATE statements that modify the rowid of contentless_delete=1 tables.
FossilOrigin-Name: d69abca82145465c85241a12322986f22bf12ffe42f86c2c8e8e2f2a77d53bf8
2024-09-27 19:10:54 +00:00
dan
08f1ba0767 Fix a problem with UPDATEs that do not modify all UNINDEXED columns of a contentless_delete=1, contentless_unindexed=1 table.
FossilOrigin-Name: b6b1db8d343d3e55c3a5589af3ec629762e06c6b689b77defd445347198cb2e7
2024-09-27 18:32:52 +00:00
dan
bcd6d5d393 Allow UPDATEs of unindexed columns in fts5 contentless_unindexed=1 tables. Testing to come.
FossilOrigin-Name: cd36d66c88d7282eb0a3ccde5713253f72f5843e451b2693b71adfdae28b41fb
2024-09-27 10:57:41 +00:00
dan
777c35dbe8 Prevent regular DELETE and UPDATE statements from running against contentless_unindexed=1 tables that are not also contentless_delete=1.
FossilOrigin-Name: 21539e9d0d57fdc762affbce9220d1bb1ca009d9dc751b4ccfe63eecbbe2f575
2024-09-25 12:03:08 +00:00
dan
6e8b3d3caa Merge latest trunk changes, including the changes to the fts5 locale=1 feature, into this branch.
FossilOrigin-Name: d2f0d19936222911bc317efecc831007d3aba81f9b32877030ffb29d1728bbdc
2024-09-13 15:37:31 +00:00
dan
0c8144ab4f Alternative implementation of fts5 locale=1 feature that allows blobs to be stored in indexed columns of fts5 locale=1 tables.
FossilOrigin-Name: 198305de92ebba7045d8ec7d2de98511f3b00924f808a3811f061dca47b01ec7
2024-09-10 20:32:36 +00:00
dan
27119c56bd Remove a stray "breakpoint" from a test script.
FossilOrigin-Name: 7d87a27a01311153ddee122cedecedc3bcc331618dc2ab1da397a3b257dc21cf
2024-09-10 18:38:47 +00:00
dan
7a41b48cf9 Alternative implementation of fts5 locale=1 feature that allows blobs to be stored in indexed columns of fts5 locale=1 tables.
FossilOrigin-Name: 55c5c119a0a77fac2c9f46d718ef78c0f33ed3520e10c240cf5bf1801e0586ee
2024-09-10 16:19:31 +00:00
dan
cd889c7a88 Fix an OOM-handling problem affecting locale=1 fts5 tables.
FossilOrigin-Name: d8103684f660ff9b3186d0f89afb113ca580bd16f0bf413ed8a9434236b54426
2024-09-09 19:12:57 +00:00
drh
a8cf79e322 Fix harmless compiler warnings in FTS5.
FossilOrigin-Name: aa75e701de61fe63ec15c35d70e53e950ff73b0dcb0d871dd8721412f3af297a
2024-09-09 15:12:21 +00:00
dan
cf25c16a54 Fix a problem with fts5 locale=1 tables and UPDATE statements that may affect more than one row.
FossilOrigin-Name: 70e42f941c0778a04b82655409c7caf4c1039589f7e43a8ec1e736ea8f931b26
2024-09-07 16:22:22 +00:00
dan
de30fb5fc2 Store the values of any UNINDEXED columns of a contentless fts5 table persistently in the database. Warning: This currently creates a (technically) incompatible file-format for contentless fts5 tables that have UNINDEXED columns.
FossilOrigin-Name: dcacb1a8ef359b4507b4733356d3150ba5dc105cc9867c103d16a0908a1a9f64
2024-09-03 18:55:38 +00:00
dan
50ca8af6f2 Fix a dropped error code in fts5.
FossilOrigin-Name: df55502e4f412e5b1daccf82f11fa4eb932047d9972dcd16e36be00cf09f78e1
2024-08-28 15:54:46 +00:00
dan
f5a9b58c8b Avoid reading the structure record from within the fts5 xConnect method.
FossilOrigin-Name: 6a6ce343b249e269229867b2c2f107a49ac8a8f24ad66801718ef01159655319
2024-08-27 20:37:30 +00:00
dan
c8edf07ca7 Modify the implementation of "wrapper" tokenizers to make them more robust in the case where the database connection is closed before the tokenizers are deleted.
FossilOrigin-Name: 7c0001d6eb43f89144eb84d9e30f575a3feed401d685a0d1f260692e419b2df2
2024-08-27 19:27:40 +00:00
drh
cc902fd25e Fix harmless compiler warnings in fts5V2toV1Tokenize().
FossilOrigin-Name: df65d00f104f31741056686f2ba41ecb192c552012bffb17c2a8b5d4db058328
2024-08-24 20:05:59 +00:00
dan
dd9a7e4540 Fix a problem with detail=none, content='' tables.
FossilOrigin-Name: 4b8070816ada3f269d53c9cee20669f59e19a23c31c8509fc397c21dd097ec9f
2024-08-18 14:46:13 +00:00
dan
41ebf965cd Extra tests.
FossilOrigin-Name: fb257540d32ced4a5fe0759d3ad9c1b36fd2b7d64d93cb0a0ecdb48355a68b7a
2024-08-15 20:33:05 +00:00
dan
189c41221d Further tests and fixes for this branch.
FossilOrigin-Name: d27985245a0e8c0d6b04323c98b26b6a8fb4e489fa8f5f3234252c7c198f23c8
2024-08-15 18:50:13 +00:00
dan
a7384e0de2 More tests for the new code on this branch.
FossilOrigin-Name: 00792e807f1dde750e6ac9f9b0095cf60b9fa6ff7cf4b14440600a21de2ee61a
2024-08-13 21:15:43 +00:00
dan
7dad9b4297 Add tests and fix minor issues with the code on this branch.
FossilOrigin-Name: def5243a7b4f1d50427ba607d31332db2d6ac34b181b0cbd2ed4911064f5637a
2024-08-13 15:04:00 +00:00
dan
3e38aa0821 Add extra documentation comments to fts5_main.c.
FossilOrigin-Name: 1a7a9bd3f6a2b9347720f7f0386399e7f14b428500acf07d7c55b9dde1ec233a
2024-08-12 18:39:13 +00:00
dan
a4a8e91022 Fix problem with some fts5 aux function APIs with (locale=, detail=none/column) tables.
FossilOrigin-Name: bf116dec6fb20cce69099cb8c031b0de511195482919a99ccfb3c498e9bf8125
2024-08-12 17:28:13 +00:00
dan
10e54e365a Fix further issues to do with fts5 locale support.
FossilOrigin-Name: e626123580065986f7df50b6140f00048944becce179b9391fbf09f97ac55485
2024-08-12 17:03:37 +00:00
dan
1286677773 Update the auxiliary function API to include xTokenize_x2() instead of xSetLocale().
FossilOrigin-Name: f7d56a1f2149f0da117167db62e2c28ec337e8da3403873b64cdfc6a951e2e8e
2024-08-12 11:13:56 +00:00
dan
9b118de9d5 Merge trunk changes into this branch.
FossilOrigin-Name: b243007525a825b3daf8aa9bb2d3088efb853bd8b7c9ea3c0924fde193eb5c44
2024-08-10 20:03:01 +00:00
dan
195ef6baca Prevent the fts5 xPhraseNext() or xPhraseFirst() APIs from returning an out-of-range column number, even if the database is corrupt.
FossilOrigin-Name: d4014c87ba9b011a6a04c2bf85879b668dc762ebcbbfb50a2f8a417ce594ef88
2024-08-10 19:57:28 +00:00
dan
ff6ab9dd2b Update the fts5_tokenizer_v2 API so that the locale is passed as parameter to xTokenize(), instead of via a separate call to xSetLocale().
FossilOrigin-Name: 03e63ed24e7a08817341e59b075ae2d4e3f7a5e5b37e0e6138359d5fd29a5e9e
2024-08-10 18:59:36 +00:00
dan
e317e7f4b4 Change things so that locale=1 is required to write fts5_locale() values to an fts5 table, and so that blobs may not be stored in indexed (i.e. not UNINDEXED) columns of these tables.
FossilOrigin-Name: c98ccc12169419b8b27ead89ef0665de40320277c5daa748b80869337419e43e
2024-08-02 21:06:13 +00:00
dan
5bd8cc7dd5 Fix various problems with the code on this branch.
FossilOrigin-Name: 8bd4ae7e95c7b6ce34db5ea705dc136e742a22f333d0e7370b485ebd736b5ec2
2024-07-31 20:49:00 +00:00
dan
9015b8822d Fix cases surrounding blob values being stored in locale=1 fts5 tables.
FossilOrigin-Name: ae435aff1785d5832821c19dc88ccf6c496a7ff55be80276b31e5c9abee723db
2024-07-30 20:39:58 +00:00
dan
8f14c45197 Fix xColumnText() and xColumnSize() APIs. Add xColumnLocale() and xTokenizeSetLocale().
FossilOrigin-Name: 14006711d83d098e665c540b978b0e29aa8f458da1c2c8e9c2baf2ad5ebd502c
2024-07-29 20:31:17 +00:00
dan
b4afecc626 Fix a couple of asan problems on this branch.
FossilOrigin-Name: 4e3e529313c86b42d5f1ba113d0714d1545bc6641e09e4537d622057f0352989
2024-07-29 15:00:11 +00:00
dan
53bef48fbe Ensure that an fts5 UPDATE does not strip the locale from columns that it does not write to.
FossilOrigin-Name: 69205264debd829573b1c777a5a493cfeb6083c4cdec106b1f819989f859ac75
2024-07-27 19:46:10 +00:00
dan
2ec78c0e4b Add the fts5_locale() function, and begin adding the related functionality to fts5.
FossilOrigin-Name: 8839ef7cfb49239e7f1c4812a53a93a672827c88d6921408b1d5062b352c87cc
2024-07-26 20:50:33 +00:00
dan
bee10b987c Improve the error message returned when fts5 finds a row is missing from its content table.
FossilOrigin-Name: 9b1afd4acb8cf9738154e921dcb074d895bbcc4742bf1016ef9f045a0da78bc8
2024-07-08 16:01:49 +00:00
dan
fdda1cbe0c Fix some problems with calling fts5 api functions from within non-full-text queries.
FossilOrigin-Name: 56d265f956fe6433b625c6d732e55f387af3f643e705316f5a6f709d63731669
2024-06-24 16:08:01 +00:00
dan
6d98c55b56 Fix an fts5 problem with secure-delete mode causing integrity-check to erroneously report a corrupt index.
FossilOrigin-Name: 80bef4d60ba9e3679ea66655ca36fcfaa888775a3d1598d50e9649ad84a95b63
2024-06-05 14:47:54 +00:00
dan
9c3eef8c0d Have fts5.xBestIndex return SQLITE_CONSTRAINT, instead of a large cost, when no usable plan can be found.
FossilOrigin-Name: 7c470945372dc98610f7c9840ce8cab18c19b655352f0187e4f31040cea77363
2024-06-01 17:56:58 +00:00
dan
2386943f19 Fix a problem with the error message reported by fts5 in some OOM cases.
FossilOrigin-Name: c7aaa28f786567e29ebee3848283b5c740dd3b8144dc14372e56260ae1b76922
2024-05-28 10:57:24 +00:00
dan
c598fdd10c Fix another fts5 problem related to unknown tokenizer modules.
FossilOrigin-Name: e78b7783040ef1ad34d4287af8a7a5998d360d50076e0de42a116d9a96fe74b4
2024-05-24 21:38:37 +00:00
dan
0e7a7e57cc Fix a crash in fts5 that could occur within "PRAGMA integrity_check" if the specified tokenizer was unknown.
FossilOrigin-Name: 061d7b69e6a43474cd7123a69f4ee65b5649a0b5e51474343defef5ae5262657
2024-05-24 21:23:36 +00:00
dan
32ca0dbcdf Have fts5 tables delay initializing the tokenizer until it is first used in all cases where the tokenizer is not "trigram".
FossilOrigin-Name: ca4fdcb8ae95d2a61236b949f852d2bf25ea2dbbff7eedafbd8eb84e8fd96687
2024-05-14 17:16:09 +00:00
dan
12b205c637 Allow existing fts5 tables to be dropped even if the associated tokenizer is not available.
FossilOrigin-Name: 69ef47eeee8b53684c321393be34f03600694fbc86377f8720ff80307846aff6
2024-05-13 20:06:08 +00:00
dan
09768559b6 Ensure the fts5 xIntegrity method correctly returns error codes unrelated to corruption or missing SQL elements.
FossilOrigin-Name: d18d9a05c2d6f290d7b16eafced0cde4eb8dd3f869778a49103812d35a0cee65
2024-02-01 15:42:22 +00:00
dan
75f9ba32bd Ensure that the xIntegrity methods of fts3 and fts5 work on read-only databases.
FossilOrigin-Name: b855886c4ccce0745af6957943e77be18949722f09821688725d546d3d79b4fb
2024-01-16 16:05:21 +00:00
dan
c08a8a33d3 In fts5, flush the contents of the in-memory hash table whenever the secure-delete option is toggled. This prevents spurious corruption reports under some circumstances.
FossilOrigin-Name: ccf552319a62bfb329820a3bc1f490bacbaa6e90694a257fc65a568a605542c3
2024-01-11 14:03:08 +00:00
dan
4eb626350a Fix a problem in fts5 caused by a COMMIT involving fts5 data that immediately follows a ROLLBACK TO that does not.
FossilOrigin-Name: 55c61f6a8d6a1bc79497b05669beac5c5397b06382bf24b6bec54845962d219b
2024-01-02 21:08:25 +00:00
dan
d82320ac9a Ensure that the xColumnText(), xQueryPhrase() and xPhraseFirstColumn() APIs all return SQLITE_RANGE if they are passed a bad column or phrase number.
FossilOrigin-Name: 1a8a9b1c89519d265869251e8b6d3c5db733f0d3a7dea6c7962811a8f1157dff
2023-12-26 15:52:40 +00:00
dan
2f3ccb8886 Different fix for the fts5 COMMIT-following-OOM problem first fixed by [fba3129d]. This one does not cause problems if an fts5 table is renamed and then dropped within the same transaction.
FossilOrigin-Name: d8c6b246944934a7a6e027b3f5b986fd64a19dd5c5c5175f4ea8586da59a6764
2023-12-07 14:41:58 +00:00