[sqlite] file structure issue

2007-05-23 Thread weiyang wang
hi, i can see the source file structure has been changed from 65 (sqliteint.h, os_common.h,. )files before to only 2 files (sqlite3.h)now. and this change bring me a problem when i try to integrate sqlite with other platforms. in my sqlite integration, i have to put my porting layer os_xxx

Re: [sqlite] file structure issue

2007-05-23 Thread Vivien Malerba
On 5/23/07, weiyang wang <[EMAIL PROTECTED]> wrote: hi, i can see the source file structure has been changed from 65 (sqliteint.h, os_common.h,. )files before to only 2 files (sqlite3.h)now. and this change bring me a problem when i try to integrate sqlite with other platforms. in my

[sqlite] left outer join optimization

2007-05-23 Thread MShiyanovsky
Hi there! I've got some troubles trying to optimize simple left outer join with sqlite. As far as I understand it reading articles on this matter there is no simple way to solve my problem but may be someone has silver bullet? I have two tables as follows: CREATE TABLE services( id INTEGER ,

[sqlite] building/upgrading on Mac OS X

2007-05-23 Thread Alessandro de Manzano
Hello, I'm using Sqlite since 2005 for a bunch of projects and I must say it really rocks :) My default workstation is a Mac OS X 10.4.9 (old PMac G4) where I develop an application of mine using Python 2.4 + Sqlite 3.1.3 + Pysqlite 2.x (sorry don't remember exactly and I'm not on that machine

Re: [sqlite] building/upgrading on Mac OS X

2007-05-23 Thread P Kishor
don't mess with system libs. Install in /usr/local/*. Set your path in your shell to look in /usr/local* first. Everything of Apple will work; everything of yours will work. On 5/23/07, Alessandro de Manzano <[EMAIL PROTECTED]> wrote: Hello, I'm using Sqlite since 2005 for a bunch of projects

[sqlite] Re: left outer join optimization

2007-05-23 Thread Igor Tandetnik
MShiyanovsky <[EMAIL PROTECTED]> wrote: I have two tables as follows: CREATE TABLE services( id INTEGER , description BLOB); CREATE TABLE customers( id INTEGER , service INTEGER); Some customers doesn't use service. So I need something like this: select c.id, s.id from customers c left outer

Re: [sqlite] file structure issue

2007-05-23 Thread Nuno Lucas
On 5/23/07, weiyang wang <[EMAIL PROTECTED]> wrote: does anyone know how can i get the source codes with the early file structure? (65 seperate files)? thanks in advance. Download the complete source code [1] and run "./configure" on it (you need a POSIX build system, like linux, cygwin or

[sqlite] About a Vista problem

2007-05-23 Thread A.J.Millan
May be of interest: Currently I'm using SQLite in a medium/big C++ application for Windows-32 using GNU gcc compiler (MinGW versiĆ³n). Usually I develop in a Windows98 SE box, although for testing purposes regularly run a copy under Windows XP (professional version) and under Vista (regular

[sqlite] Is .dump the definitive backup method for sqlite?

2007-05-23 Thread Nigel Metheringham
I recently experimented with putting binary data into SQLite table rows - I declared the column holding the binary data as a BLOB (not that it makes a ton of difference for SQLite). This worked very well (using perl DBIx::Class/DBI/DBD::SQLite as the interface into SQLite). However a

Re: [sqlite] About a Vista problem

2007-05-23 Thread Tian-Jian \"Barabbas\" [EMAIL PROTECTED]
Hi Millan, I encountered the same problem, the record is on http://b6s.blogspot.com/2007/04/previous-version-ghost-on-vista-can-be.html and the issue was sent to http://www.sqlite.org/cvstrac/tktview?tn=2178 To my best knowledge, there's something funny in the dynamic library of file I/O,

Re: [sqlite] About a Vista problem

2007-05-23 Thread Joe Wilson
--- "Tian-Jian \"Barabbas\" [EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > Hi Millan, > > I encountered the same problem, the record is on > > http://b6s.blogspot.com/2007/04/previous-version-ghost-on-vista-can-be.html > > and the issue was sent to > >

Re: [sqlite] Is .dump the definitive backup method for sqlite?

2007-05-23 Thread Joe Wilson
--- Nigel Metheringham <[EMAIL PROTECTED]> wrote: > I recently experimented with putting binary data into SQLite table > rows - I declared the column holding the binary data as a BLOB (not > that it makes a ton of difference for SQLite). > > This worked very well (using perl

Re: [sqlite] left outer join optimization

2007-05-23 Thread Dennis Cote
MShiyanovsky wrote: I've got some troubles trying to optimize simple left outer join with sqlite. As far as I understand it reading articles on this matter there is no simple way to solve my problem but may be someone has silver bullet? I have two tables as follows: CREATE TABLE services( id

Re: [sqlite] Monitor Queries

2007-05-23 Thread Thomas Fjellstrom
On May 23, 2007, Andreas Weller wrote: > Hi! > I've a "black-box" (Linux) program - so no source available - using a > sqlite database. Is there any way I can monitor/log the queries made to > the database? Create a library with the functions you want to hook, and dlopen/LoadLibrary the sqlite

Re: [sqlite] Monitor Queries

2007-05-23 Thread Joe Wilson
> I've a "black-box" (Linux) program - so no source available - using a > sqlite database. Is there any way I can monitor/log the queries made to > the database? If it's dynamically linked, just replace libsqlite3.so with your own. If it is statically linked and has -g symbols, use gdb. If it's

Re: [sqlite] Is .dump the definitive backup method for sqlite?

2007-05-23 Thread Nigel Metheringham
On 23 May 2007, at 14:23, Joe Wilson wrote: What version of sqlite are you using (2.x, 3.x)? One 3.x version in particular had a bug related to not dumping indexes and triggers. I've never used sqlite 2.x, so I can't comment on that. All with sqlite 3 - both 3.1.3 (as installed on Mac OS X),

Re: [sqlite] Monitor Queries

2007-05-23 Thread Lloyd
On Wed, 2007-05-23 at 07:21 -0700, Joe Wilson wrote: > > I've a "black-box" (Linux) program - so no source available - using > a > > sqlite database. Is there any way I can monitor/log the queries made > to > > the database? > > If it's dynamically linked, just replace libsqlite3.so with your

Re: [sqlite] Monitor Queries

2007-05-23 Thread Joe Wilson
--- Lloyd <[EMAIL PROTECTED]> wrote: > On Wed, 2007-05-23 at 07:21 -0700, Joe Wilson wrote: > > > I've a "black-box" (Linux) program - so no source available - using > > a > > > sqlite database. Is there any way I can monitor/log the queries made > > to > > > the database? > > > > If it's

[sqlite] Database disk image is malformed (11)

2007-05-23 Thread Jiri Hajek
Hello, bug reports from our users indicate that SQLite ocassionaly (or rather rarely) returns 'database disk image is malformed (11)' error. However, there doesn't seem to be any good reason for this behaviour, everything else seems to be fine. I have searched some older posts here and one user

Re: [sqlite] Is .dump the definitive backup method for sqlite?

2007-05-23 Thread Joe Wilson
--- Nigel Metheringham <[EMAIL PROTECTED]> wrote: > I'll see if I can reproduce the result with standard INSERT statements Try this: sqlite3 orig.db vacuum -- might be necessary to preserve row order sqlite3 orig.db ".dump BrokenTable" | tee orig.sql | sqlite3 new.db sqlite3 new.db ".dump

Re: [sqlite] building/upgrading on Mac OS X

2007-05-23 Thread Alessandro de Manzano
On Wed, May 23, 2007 at 06:35:01AM -0500, P Kishor wrote: > don't mess with system libs. Install in /usr/local/*. Set your path in > your shell to look in /usr/local* first. Everything of Apple will > work; everything of yours will work. I tried, but following the building instruction on Wiki

Re: [sqlite] SQL error: disk I/O error

2007-05-23 Thread Shilpa Sheoran
Linux 2.6.9 and the media is Nand Flash memory. /dir1/dir2/dir3 /dir1/dir2 is readonly (cramfs) dir3 is read write (Flash mem). and I'm creating the database in dir3. Somehow I don't have a problem in a tmpfs. The strace showed no diff between tmpfs and this directory where it is giving I/O

Re: [sqlite] SQL error: disk I/O error

2007-05-23 Thread Nuno Lucas
On 5/23/07, Shilpa Sheoran <[EMAIL PROTECTED]> wrote: Linux 2.6.9 and the media is Nand Flash memory. /dir1/dir2/dir3 /dir1/dir2 is readonly (cramfs) dir3 is read write (Flash mem). and I'm creating the database in dir3. There is your problem. The file system on that directory (I would guess

RE: [sqlite] bizarre query problem

2007-05-23 Thread Brett Keating
It said that the hex function was not found so I skipped that. Msica independiente|text|19|0056_People Get Ready1_test1.wma POP|text|3|0057_The Mighty Ship1_test1.wma POP|text|3|0058_The Mighty Quinn1_test1.wma Anyway, it turns out the problem was caused by creating an index on the genre field.

Re: [sqlite] building/upgrading on Mac OS X

2007-05-23 Thread Will Leshner
On 5/23/07, Alessandro de Manzano <[EMAIL PROTECTED]> wrote: May I ask exactly why the wiki instruct to NOT build shared lib ? The reference of a bad libtool still applies to recent OS X releases ? Why don't you just do configure and make? That's what I always do and it works fine for me. You

RE: [sqlite] bizarre query problem

2007-05-23 Thread Joe Wilson
--- Brett Keating <[EMAIL PROTECTED]> wrote: > Msica independiente|text|19|0056_People Get Ready1_test1.wma > POP|text|3|0057_The Mighty Ship1_test1.wma > POP|text|3|0058_The Mighty Quinn1_test1.wma > > Anyway, it turns out the problem was caused by creating an index on the > genre field. If I

RE: [sqlite] bizarre query problem

2007-05-23 Thread Brett Keating
Actually this wasn't the issue after all... Indices have nothing to do with it. The genre was being inserted from two different sources. It is a UTF-16 string, and in one case it was being inserted with a null terminator, and in another case it was not. Since I used "sqlite3_bind_text16" and

RE: [sqlite] bizarre query problem

2007-05-23 Thread Joe Wilson
--- Brett Keating <[EMAIL PROTECTED]> wrote: > Actually this wasn't the issue after all... Indices have nothing to do > with it. > > The genre was being inserted from two different sources. It is a UTF-16 > string, and in one case it was being inserted with a null terminator, > and in another