FW: [sqlite] Reading Blob data using Perl

2007-10-16 Thread Brian Rowlands (Greymouth High School)
Magic Kishor I'm learning a lot as I study Perl and now SQLite and your invaluable assistance did the trick. The key lines now read: my $newdata = $ref->{icon}; binmode OUTPUT; print OUTPUT $newdata; Many thanks. -Original Message- From: P Kishor [mailto:[EMAIL PROTECTED] Sent:

Re: [sqlite] Compact statement for table to table copy

2007-10-16 Thread Vitali Lovich
Well, you don't have to list the columns if you're not changing the ordering. INSERT INTO table1 SELECT * FROM table2; Rich Rattanni wrote: I have two tables in a database with exactly the same schema (idNum PRIMARY KEY, data1, data2) I want to copy all the records in table 2 to table 1,

Re: [sqlite] In-memory database: manually modifying ROWID value increases memory.

2007-10-16 Thread Vitali Lovich
My question is how you're measuring the memory useage? Are you accounting for the space overhead of the various bookkeeping sqlite needs (i.e. master table)? The way you're creating you're table implies you're not using autoincrement for the integer field - are you accounting for the extra

Re: [sqlite] Reading Blob data using Perl

2007-10-16 Thread P Kishor
can't help you all the way, but below are a few comments -- On 10/16/07, Brian Rowlands (Greymouth High School) <[EMAIL PROTECTED]> wrote: > Hi > I'm hoping someone can help me explain how to fix a problem I have with > reading a Blob field from a SQLite DB using Perl. My long term aim is to >

[sqlite] Reading Blob data using Perl

2007-10-16 Thread Brian Rowlands (Greymouth High School)
Hi I'm hoping someone can help me explain how to fix a problem I have with reading a Blob field from a SQLite DB using Perl. My long term aim is to not save it to a file but use it within my application and store it as a label bitmap. However, first things first. This code reads the Blob but when

Re: [sqlite] sqlite 3.x lock states

2007-10-16 Thread Richard Klein
Here is my current understanding (by "process" I mean a process *or* thread that has opened the database): >> *snip* >> Correct. On the other hand, our hope as always been that you do not need to understand any of this in order to use SQLite. It should all just work. The only time you might

Re: [sqlite] sqlite 3.x lock states

2007-10-16 Thread drh
Richard Klein <[EMAIL PROTECTED]> wrote: > Hello all, > > I'm upgrading from sqlite 2 to 3, and am trying to get a handle > on the new lock states. > > Here is my current understanding (by "process" I mean a process > *or* thread that has opened the database): Or two separate database

[sqlite] sqlite 3.x lock states

2007-10-16 Thread Richard Klein
Hello all, I'm upgrading from sqlite 2 to 3, and am trying to get a handle on the new lock states. Here is my current understanding (by "process" I mean a process *or* thread that has opened the database): A database is in the

[sqlite] Compact statement for table to table copy

2007-10-16 Thread Rich Rattanni
I have two tables in a database with exactly the same schema (idNum PRIMARY KEY, data1, data2) I want to copy all the records in table 2 to table 1, currently I am using the following statement: INSERT INTO table1 (data1, data2) SELECT data1, data2 FROM table2. Now this is just a simplified

RE: [sqlite] INTEGER PRIMARY KEY Auto Increment Rollover Question

2007-10-16 Thread Odekirk, Shawn
>> Brickl Roland [mailto:[EMAIL PROTECTED] wrote: >> Integer PrimaryKeys are always autoincrementing. When you don't >> specify it it uses after (2^63)-1 a random free positiv value. >> "Odekirk, Shawn" <[EMAIL PROTECTED]> wrote: >> I will compile this for Windows and see what my results are

Re: [sqlite] HELP WITH SQLITE INTERNALS - VDBE and Virtual tables

2007-10-16 Thread John Stanton
Moreover, is it typical to have an implementation like VDBE in other databases as well? This is a common approach and has been used for a very long time. For example we used it in products produced during the 1980s because producing a virtual machine and a compiler for its

Re: [sqlite] HELP WITH SQLITE INTERNALS - VDBE and Virtual tables

2007-10-16 Thread Joe Wilson
--- Uma Krishnan <[EMAIL PROTECTED]> wrote: > I'm a student trying to understand SQLite for my DB project. There are a > couple of aspects that > I don't quite understand: > 1) VDBE. I see how the vdbe stack is created using VDBEAddOp etc. But once > the code is > generated, I don't see when

[sqlite] HELP WITH SQLITE INTERNALS - VDBE and Virtual tables

2007-10-16 Thread Uma Krishnan
Hello, I'm a student trying to understand SQLite for my DB project. There are a couple of aspects that I don't quite understand: 1) VDBE. I see how the vdbe stack is created using VDBEAddOp etc. But once the code is generated, I don't see when it's executed. Moreover, is it typical to have an

[sqlite] Full column names in join command: table name is used in a result set instead of alias (libversion 3.4.2)

2007-10-16 Thread Petr Fejfar
Hi all, I am upgrading an application from version 2.8.x to 3.4.2 and I have troubles with full column names. I've preset pragmas short_column_names=OFF full_column_names=ON Then various forms of the same SQL command: 1. SELECT frg.*, ses.saCOMIName,ses.saXXX,... FROM TxOTG_Fragments