Hello markus, Every Windows programmer needs to have "Procmon" installed on their system so, they can watch their program's disk IO. I'd suggest installing it, then using a filter to watch just your service. Then, you can simply watch what disk IO is failing. I use it on a daily basis. Almost as much as my debugger.
It'll probably show you a permission problem. C ... Test.exe 6312 ReadFile E:\Test\Db.db3 SUCCESS Offset: 0, Length: 100, Priority: Normal Test.exe 6312 ReadFile E:\Test\Db.db3 SUCCESS Offset: 0, Length: 4,096, I/O Flags: Non-cached, Paging I/O, Priority: Normal Test.exe 6312 QueryOpen E:\Test\Db.db3 SUCCESS CreationTime: 6/19/2012 9:06:58 PM, LastAccessTime: Test.exe 6312 LockFile E:\Test\Db.db3 SUCCESS Exclusive: True, Offset: 1,073,741,824, Length: 1, Fail Immediately: True Test.exe 6312 LockFile E:\Test\Db.db3 SUCCESS Exclusive: False, Offset: 1,073,741,826, Length: 510, Fail Immediately: True Test.exe 6312 UnlockFileSingle E:\Test\Db.db3 SUCCESS Offset: 1,073,741,824, Length: 1 Test.exe 6312 QueryOpen E:\Test\Db.db3-journal SUCCESS CreationTime: 6/19/2012 9:06:58 PM, Test.exe 6312 QueryStandardInformationFile E:\Test\Db.db3 SUCCESS AllocationSize: 106,496, EndOfFile: 106,496, NumberOfLinks: 1, Test.exe 6312 QueryOpen E:\Test\Db.db3-wal NAME NOT FOUND Test.exe 6312 QueryStandardInformationFile E:\Test\Db.db3 SUCCESS AllocationSize: 106,496, EndOfFile: 106,496, Test.exe 6312 ReadFile E:\Test\Db.db3 SUCCESS Offset: 0, Length: 8,192 ... and so on. Wednesday, August 15, 2012, 11:19:52 AM, you wrote: mr> Hi, mr> We are facing problems when the sqlite database () is used within an mr> application that runs as a Win7 service under the local system account. mr> The application is written in Java and we use the sqlite-jdbc-3.7.2 JDBC mr> driver. mr> How ever we can create a new database, reading and writing to it withount mr> any problem. The only thing that is not working is the ATTACH DATABASE SQL mr> command. We constantly receive a CAN_NOT_OPEN error code. mr> When we start the same application under a local user everything works mr> fine. I have to add the both databases that are to be attached are in the mr> same folder and have been created by the Application itself. There are no mr> access restrictions on the database folders or files. mr> Does anyone know about this and / or has a solution? mr> Kind regards mr> Markus mr> _______________________________________________ mr> sqlite-users mailing list mr> sqlite-users@sqlite.org mr> http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users -- Best regards, Teg mailto:t...@djii.com _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users