On 07/01/2012 05:17 PM, Navaneeth.K.N wrote:
Hello,
On Sun, Jul 1, 2012 at 2:27 PM, Petite Abeille<[email protected]>wrote:
On Jul 1, 2012, at 9:11 AM, Navaneeth.K.N wrote:
Now, repeating a "pattern" and "id" combination is an error to me. There
should be always one "pattern" to "id" combination. If this was not a
virtual table, I'd have solved the problem by creating a primary key on
both "pattern" and "id". But this trick is not working on FTS tables.
Perhaps you could try the following setup:
(1) Create a regular table to hold your unique patterns, using an unique
constraint
create table foo
(
id integer not null constraint foo_pk primary key,
bar text,
constraint foo_uk unique( bar )
)
(2) Create a FTS table with external content [1] to search the above
create virtual table foo_bar using fts4
(
content = "foo",
bar text
)
I knew this. I was more worried about the performance. Will there be a
performance difference comparing to data stored directly on the FTS table?
No. Internally FTS just uses your table instead of one that it
creates itself.
_______________________________________________
sqlite-users mailing list
[email protected]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users