Joe,

Tried using the suggested " int sqlite3_win32_set_directory(DWORD type,
LPCWSTR zValue);" before opening any database connection.  sqlite still
reports " sqlite3_temp_directory variable should be set for WinRT".

We are trying to set the Windows RT's sandbox local directory of the
application.

"C:\\Users\\tester\\AppData\\Local\\Packages\\6c6495b1-9a34-45b5-8a37-ef048f
f7a7fb_agzj39a4a6zwt\\LocalState"

One interesting observation we made is that when the temp store directory is
set to "c:\\temp" just to see what happens (which should not be accessible
from the RT sand box), then sqlite reports the following errors :

---> delayed 1375ms for lock/sharing conflict,10
--> os_win.c:36224: (5) winAccess(c:\temp) - Access is denied.,3338
--> not a writable directory,1

Thanks for all the help
MB

-----Original Message-----
From: sqlite-users-boun...@sqlite.org
[mailto:sqlite-users-boun...@sqlite.org] On Behalf Of Joe Mistachkin
Sent: Friday, 28 March 2014 7:08 AM
To: 'General Discussion of SQLite Database'
Subject: Re: [sqlite] SQLITE_ERROR (SQL logic error or missingdatabase) on
WinRT/ WP8 when querying large (!) result setsusing 3.8.4.1


Muharrem Bilgin wrote:
>
> The following are the log entries, which confirm your suspicion (the 
> log entry format : time, error description, error code).
> 

Agreed.

> 
> As suggested, we are already setting the temp store directory  as soon 
> as
a
> database connection is opened (after sqlite3_open16). Now, the 
> question is when to use the "PRAGMA temp_store_directory='...';". Do 
> we have to call
it
> as a specific time ? (i.e. every time before executing a SELECT
statement?)
> 

Since you are not using the wrapper, you should probably just call the
necessary SQLite C API directly:

        int sqlite3_win32_set_directory(DWORD type, LPCWSTR zValue);

The first argument should be 2 in order to set the temporary directory.
The second argument should be the UTF-16 string containing the fully
qualified path to use.

Ideally, the temporary directory should be set prior to the first database
connection being opened.

--
Joe Mistachkin
 


_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to