I couldn't find a way to use FTS3 with ormlite because, I have problems creating a virtual table. I need to run something like this in native sqlite:
CREATE VIRTUAL TABLE enrondata1 USING fts3(content TEXT);
But ORMLite calls the below method for creating a simple table
TableUtils.createTable(ConnectionSource connectionSource, Class<T> dataClass);
In this answer for the question: FTS3 searches in ORMLite?, written about using ORMLite's raw query interface, unfortunately, I could not find a way to create a table with it.
How can I use FTS3 with ormlite?
The queryRaw
function is only for SELECT
queries. To execute other commands, use raw execute statements.
For example:
dao.executeRaw("CREATE VIRTUAL TABLE enrondata1 USING fts3(content TEXT);");