Re: [sqlite] Sqlite & COM/EXE server

2004-01-06 Thread Eugene Lin
Thank you all for your replies. I do understand the points you're making, i.e. it 
could be a security context problem in relation to what user account my COM/EXE is 
attached to, hence to what directories the EXE has the read/write privilege. If it is 
the case then my question is why Sqlite has no problem accessing the database file 
itself?

Eugene

*** REPLY SEPARATOR  ***

On 01/06/2004 at 2:37 PM Lindsay Mathieson wrote:

>Eugene Lin wrote:
>
>>Bert,
>>
>>
>>
>>>It is a COM-related problem, not a SQLITE problem
>>>
>>>
>>
>>I can now tell you that it IS a sqlite problem NOT a COM problem. Sqlite
>is trying to create its temporary database at some location (which I'm not
>sure where) and it failed. I have found that you can force sqlite to store
>its temporary database in memory. Once I have done that, the problem has
>gone!
>>
>>
>Well my guess (from reading the previous emails) is that is neither a
>COM or a SQLite problem - basically a lack of understanding re users,
>services and nt securiity
>
>If your com server is running as a normal service (not interactive or
>logged on) then it has no user profile. Which means it cannot access any
>network directores etc, also it will have no user enviroment settings
>such as temporary directories it can access. This why setting the temp
>dir to memory works.
>
>The easy solutuin is to have the service logon as a user, either an
>existing one or create a user account for it.
>
>Alternatively you could create a temp directory thats globaly
>read/writable and have the service use that as its temp dir.




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: [sqlite] Sqlite & COM/EXE server

2004-01-06 Thread Eric JESOVER
This is not a sqllite problem, if I understand well your problem.
When your service is running, the security account is SYSTEM.
SYSTEM on XP has not the right to write everywhere.
I'm thinking this is your problem

Look where sqlLite write his temp file and look at the security in this
place.

Regards 



Eric JESOVER
http://eric.jesover.net


-Original Message-
From: Eugene Lin [mailto:[EMAIL PROTECTED] 
Sent: Tuesday 06 January 2004 03:21
To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
Subject: Re: [sqlite] Sqlite & COM/EXE server

Bert,

>It is a COM-related problem, not a SQLITE problem

I can now tell you that it IS a sqlite problem NOT a COM problem. Sqlite is
trying to create its temporary database at some location (which I'm not sure
where) and it failed. I have found that you can force sqlite to store its
temporary database in memory. Once I have done that, the problem has gone!

Eugene

*** REPLY SEPARATOR  ***

On 12/27/2003 at 5:00 PM [EMAIL PROTECTED] wrote:

>> Hi,
>> 
>> Does anyone use Sqlite in a COM/EXE server? 
>> 
>> I always get the error "no such table: sqlite_temp_master" from 
>> Sqlite
>when I call any of its API
>> function from within a COM EXE. Out of many attempts I discovered 
>> that
>if I set my COM EXE to run as
>> an Interactive User (by using DCOMCNFG) then everything works as
>expected. The problem is that a COM
>> EXE is not supposed to run as an Interactive User. Why would Sqlite 
>> need
>to be run in an Interactive
>> User account?
>
>If it is not an Interactive user, then it is a service, a few years ago 
>I had some problems with services and not Interactive user-accounts, I 
>found a solution at following website.
>
>http://www.aldyn-software.com/svcom.html
>
>I did not check it out today, but I guess you find the answer there.
>
>It is a COM-related problem, not a SQLITE problem
>
>kind regards
>Bert Verhees
>
>> 
>> Thanks for any help in advance.
>> 
>> Eugenel
>> 
>> 
>
>
>
>-
>To unsubscribe, e-mail: [EMAIL PROTECTED]
>For additional commands, e-mail: [EMAIL PROTECTED]




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [sqlite] Sqlite & COM/EXE server

2004-01-05 Thread Lindsay Mathieson
Eugene Lin wrote:

Bert,

 

It is a COM-related problem, not a SQLITE problem
   

I can now tell you that it IS a sqlite problem NOT a COM problem. Sqlite is trying to create its temporary database at some location (which I'm not sure where) and it failed. I have found that you can force sqlite to store its temporary database in memory. Once I have done that, the problem has gone!
 

Well my guess (from reading the previous emails) is that is neither a 
COM or a SQLite problem - basically a lack of understanding re users, 
services and nt securiity

If your com server is running as a normal service (not interactive or 
logged on) then it has no user profile. Which means it cannot access any 
network directores etc, also it will have no user enviroment settings 
such as temporary directories it can access. This why setting the temp 
dir to memory works.

The easy solutuin is to have the service logon as a user, either an 
existing one or create a user account for it.

Alternatively you could create a temp directory thats globaly 
read/writable and have the service use that as its temp dir.


RE: [sqlite] Sqlite & COM/EXE server

2003-12-27 Thread Steve O'Hara


-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: 27 December 2003 16:19
To: [EMAIL PROTECTED]
Subject: RE: [sqlite] Sqlite & COM/EXE server



> Hi,
>
> I've used SQLite in a variety of COM situations without problems.
>
> What is your application environment (asp/client-server/desktop)?
> Is your COM EXE written in VB?
> Are you using a custom DLL to interface to the SQLite DLL?
> How is your COM EXE threaded (free/apartment/single)?
>
> I've used the SQLite VB DLL from Pivotal (download from the Yahoo files
> section) without encountering any of these problems.
> The only reason why you would need to delve into DCOMCNFG is because you
are
> either running the EXE from ASP or from a Service.  In which case, you
would
> need to make sure that the launching user of your EXE has correct
> permissions to launch/access your objects.  Equally, the EXE will need
> permissions to the directories where SQLite writes its temp files.
>

The EXE must have a desktop when it wants to create Windows, in MS WIndows
a lot of code is creating invisible Windows, only Interactive Users are
allowed to do
so, there about is the problem with out of process COM-objects and services,
I
forget the exact how and why, but maybe this helps to find the answer

Bert Verhees

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


It is very rare that you would ever want to create windows from within a COM
EXE - the whole point of such a beast is to provide object services to your
front/back end, not normally to provide user interfaces (that's where OCX's
come in).
Also, your assertion that you cannot do this is incorrect - if you create a
window within a COM EXE that isn't set to interact with the Desktop, then no
user can see it, that's all.

The permissions issue is a commen problem for ASP applications that
instantiate COM EXE - these EXEs run with the default DCOMCNFG rights unless
otherwise configured, which are pretty onerous.

Steve





-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: [sqlite] Sqlite & COM/EXE server

2003-12-27 Thread [EMAIL PROTECTED]

> Hi,
> 
> I've used SQLite in a variety of COM situations without problems.
> 
> What is your application environment (asp/client-server/desktop)?
> Is your COM EXE written in VB?
> Are you using a custom DLL to interface to the SQLite DLL?
> How is your COM EXE threaded (free/apartment/single)?
> 
> I've used the SQLite VB DLL from Pivotal (download from the Yahoo files
> section) without encountering any of these problems.
> The only reason why you would need to delve into DCOMCNFG is because you are
> either running the EXE from ASP or from a Service.  In which case, you would
> need to make sure that the launching user of your EXE has correct
> permissions to launch/access your objects.  Equally, the EXE will need
> permissions to the directories where SQLite writes its temp files.
> 

The EXE must have a desktop when it wants to create Windows, in MS WIndows 
a lot of code is creating invisible Windows, only Interactive Users are allowed to do 
so, there about is the problem with out of process COM-objects and services, I 
forget the exact how and why, but maybe this helps to find the answer

Bert Verhees

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [sqlite] Sqlite & COM/EXE server

2003-12-27 Thread [EMAIL PROTECTED]
> Hi,
> 
> Does anyone use Sqlite in a COM/EXE server? 
> 
> I always get the error "no such table: sqlite_temp_master" from Sqlite when I call 
> any of its API
> function from within a COM EXE. Out of many attempts I discovered that if I set my 
> COM EXE to run as
> an Interactive User (by using DCOMCNFG) then everything works as expected. The 
> problem is that a COM
> EXE is not supposed to run as an Interactive User. Why would Sqlite need to be run 
> in an Interactive
> User account?

If it is not an Interactive user, then it is a service, a few years ago I had some 
problems with services and not Interactive user-accounts, I found a solution at 
following website.

http://www.aldyn-software.com/svcom.html

I did not check it out today, but I guess you find the answer there.

It is a COM-related problem, not a SQLITE problem

kind regards
Bert Verhees 

> 
> Thanks for any help in advance.
> 
> Eugenel
> 
> 



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[sqlite] Sqlite & COM/EXE server

2003-12-27 Thread Eugene Lin
Hi,

Does anyone use Sqlite in a COM/EXE server?

I always get the error "no such table: sqlite_temp_master" from Sqlite when I call any 
of its API function from within a COM EXE. Out of many attempts I discovered that if I 
set my COM EXE to run as an Interactive User (by using DCOMCNFG) then everything works 
as expected. The problem is that a COM EXE is not supposed to run as an Interactive 
User. Why would Sqlite need to be run in an Interactive User account?

Thanks for any help in advance.

Eugenel