I'm completely stuck with loading extensions in Qt's SQLite driver. I've done all steps from this 'how to'. Just changed SQLITE_ENABLE_LOAD_EXTENSION to DSQLITE_ENABLE_LOAD_EXTENSION.
After that I'm trying to run following code in my app:
QSqlQuery tSqlQuery;
QString sql_command_text;
sql_command_text = QString("SELECT load_extension(\"libspatialite-4.dll\")");
if(!tSqlQuery.exec(sql_command_text))
qDebug() << tSqlQuery.lastError().text();
And qDebug gives me this: "not authorized Unable to fetch row".
I'm using Qt 4.6.3
What am I doing wrong? I've read tons of articles but couldn't find any solution.
You can be sure in following things:
- I've done all steps from how-to
- I've rebuild DLLs and replaced them