[sqlite] : it seems to be only orber by and group

2015-08-22 Thread afriendandmore
but I fail to get it done.


Hello,

I got the following problem, that I cannot get worked out.

I have a table that has 3 columns A, B and C.
C is a boolean Column, that indicates if the record has been logically 
deleted, It shall not be removed from the database.
The table shall be ordered according to A. (Order by A)
But if C ist true and to the value B1 in this Record, there exists 
another Record with B2 and B2 = B1, then B1 should be ordered in the row 
above B2.

B



A



C 1=true, 0 = false

307



{null}



1

307



{null}



1

307



{null}



1

307



1.7



0

301



1,5



1

301



2



0

304



3



0

305



3



1

305



3



0


Thank you very much for any help.



[sqlite] : Vacuum and WiCe (Windows Embbeded Compact 7)

2015-08-05 Thread afriendandmore
Hello,

I am developing an application for Windows Compact Embedded 7 using .net 
3.5 and sqlite.

Is there a possibility to run vacuum, mean to compact the database und 
WinCe from a C# Program?

Thank you very much.




[sqlite] Copy data between to databases unsing windows embedded compact 7, .net 3.5

2015-05-21 Thread afriendandmore
Hi,

I am developing an application for Windows Compact Embedded 7 using .net 
3.5 and sqlite.

We have two databases,

db1, db2.

A table shall b e copied from db1 to db2 using .net and c#.

INSERT INTO db1.table
SELECT *
   FROM db2.table

How can I execute this command using ado.net 3.5 (Ce.net 3.5), how to  
connections to two databases.

Is there an enviroment/console where I can run this (and other) command 
directly, to test them?

Thank you very much.


[sqlite] Database corrupted after OS Out of memory exception

2015-03-31 Thread afriendandmore
Hello,

we are developing an application Using SQLite3 on Windows embedded 
compact 7 using C# 3.5.
We have had no problems with corrupted databases so far, even though I 
always kill the running process in the debugger.  The development 
process is now 2 Years. Also, some months ago we had a lot of out of 
memory exceptions and no problem with SqLite
Now, in Kioskmode where there is no explorer running, when we change the 
system time, there comes a several MBytes big memory leak, which causes 
an Out of Memory Exception of the OS, and after a restart we have a 
corrupted Database.  We had other Out of Memory Exceptions with no 
corrupted Database.
Additionally, the journal File seems not to be handled before the first 
data request is handled after the restart, because at subsequent starts, 
the database allows access to data, that were not available upon first 
start.
there is only one client, and only one thread trying to access the database.
We are using:
c# 3.5
.net 3.5

SQLite.Interop.085.dll
File Version 1.0.85.0
Product Version 1.0.85.0


System.Data.SQLite.dll
File Version 1.0.85.0
Product Version 1.0.85.0

Do you see any chance, to prevent this damage?
If I close the database before this critical action, is this a 
synchronous process, means is the database really closed and everything 
written, when the close() Method comes back and the main program 
continous? If not, how can I make sure everything is written, before I 
continue with the critical action?

Thank you for every help.