glebarez/sqlite

[FEAT] Support CREATE VIRTUAL TABLE / FTS5

tony95271 opened this issue · 2 comments

This package seems not support CREATE VIRTUAL TABLE / FTS5, test code
https://go.dev/play/p/PxjDDoIn1N2

It would be nice to have support for the CREATE VIRTUAL TABLE feature,
Thanks.

ref

Hello, FTS5 is enabled by default.
The problem in your code is that Raw doesn't execute the query, you need Exec:

sql := `CREATE VIRTUAL TABLE IF NOT EXISTS ft using fts5(id,name);`
err = db.Exec(sql).Error

Hello, FTS5 is enabled by default. The problem in your code is that Raw doesn't execute the query, you need Exec:

sql := `CREATE VIRTUAL TABLE IF NOT EXISTS ft using fts5(id,name);`
err = db.Exec(sql).Error

Thanks!