[sqlite] Newbie question about using SQLite with Window s Forms application (VS 2005 C++)

2009-04-25 Thread wiktor
Hi, I'm trying to build a win form application that uses sqlite. I have problems with making it work. I would like to have the sqlite source included in my project (as .h file or dll) - sth similar to (but done by a function) http://www.sqlite.org/quickstart.html. As I have read on internet

Re: [sqlite] Newbie question about using SQLite with Windows Forms application (VS 2005 C++)

2009-04-25 Thread Vinnie
From: wiktor siri...@o2.pl Subject: [sqlite] Newbie question about using SQLite with Windows Forms application (VS 2005 C++) I'm trying to build a win form application that uses sqlite. I have problems with making it work. I would like to have the sqlite source included in my project (as

[sqlite] Indexing for sums?

2009-04-25 Thread Nikolas Stevenson-Molnar
Hi all, If I have the following table: CREATE TABLE stem(sid integer primary key, x double, y double, dbh double); ... is there any way I can create an index for the following query? SELECT * FROM stem WHERE x + dbh 20 Thanks! _Nik ___

Re: [sqlite] Indexing for sums?

2009-04-25 Thread Igor Tandetnik
Nikolas Stevenson-Molnar steve...@evergreen.edu wrote in message news:f45a26bc-1ee8-4a72-a90a-77f40eef6...@evergreen.edu If I have the following table: CREATE TABLE stem(sid integer primary key, x double, y double, dbh double); ... is there any way I can create an index for the following

[sqlite] corrupt database recovery

2009-04-25 Thread Gene
Every now and again, we have a database that gets corrupt in the field (bad coding on our end, not sqlite). When we get one of these corrupt databases, we recover what we can by get one row at a time by rowid, like 'select * from mytable where rowid = 1' and we inc the row number every time.

[sqlite] PHP Sqlite2 - random update returns.. caching problem?

2009-04-25 Thread vacuumir
Hi all, I really don't know where else to post with this problem. I am using a PHP5 application, which uses the Sqlite2 built-in (2.8.16), and am using queries via Class: PDO for PHP 4 http://www.phpclasses.org/browse/package/2572.html which simply call sqlite_fetch_array or sqlite_query..

Re: [sqlite] PHP Sqlite2 - random update returns.. caching problem?

2009-04-25 Thread vacuumir
Hi all, Seems that this: vacuumir wrote: $result = Db_query('PRAGMA synchronous = FULL'); print_r($result); in fact did work - except I wasn't using a statement that actually returns the changed state.. To confirm, I use this: $ress = Db_query('PRAGMA synchronous = FULL;');

[sqlite] Sort order with umlauts

2009-04-25 Thread Lukas Haase
Hello, For a database I also need a fulltext index. This is my table containing all the words: CREATE TABLE db_fulltext.fulltext( fulltextID INTEGER PRIMARY KEY, word VARCHAR(100) COLLATE NOCASE ); Now I have the problem that I have also words with umlauts. Now they are sorted

Re: [sqlite] corrupt database recovery

2009-04-25 Thread John Machin
On 26/04/2009 5:47 AM, Gene wrote: Every now and again, we have a database that gets corrupt in the field (bad coding on our end, not sqlite). Hi Gene, The obvious question: why not fix the bad code? What does 'PRAGMA integrity_check;' say about these corrupt databases? When we get one

Re: [sqlite] corrupt database recovery

2009-04-25 Thread Gene
You are exactly right John...that is indeed what the code looks like...except we have over 25 columns (it's a flat table). We've already fixed the bad code, but there are some customers who have old versions...it didn't break very often with the old code, but it does still did. I haven't tried a

Re: [sqlite] corrupt database recovery

2009-04-25 Thread John Machin
On 26/04/2009 11:28 AM, Gene wrote: You are exactly right John...that is indeed what the code looks like...except we have over 25 columns (it's a flat table). I presume that you are referring to this: Write a script that loops around doing 'select * from mytable where rowid = ?' on a

Re: [sqlite] corrupt database recovery

2009-04-25 Thread Gene Allen
It's not hard to update it...I'm just whining about that it's out of date and I hate having to deal with matching everything up so I was hoping that I could get past the Attach. I think your python script below might ease my maintenance whoas a bit. I'll port it to C# and just build my insert on