RE: [sqlite] Delete crashes with Version 3.2.4 in Windows XP

2005-08-24 Thread Brown, Dave
Has anyone created (or is logging) a testbed so that new versions of SQLite can be run through some regression tests? Might want to add this one to the mix if so. -Dave -Original Message- From: Downey, Shawn [mailto:[EMAIL PROTECTED] Sent: Wednesday, August 24, 2005 11:56 AM To:

RE: [sqlite] Binding a column name?

2005-07-11 Thread Brown, Dave
To: sqlite-users@sqlite.org Subject: RE: [sqlite] Binding a column name? On Sun, 2005-07-10 at 00:23 -0700, Brown, Dave wrote: > That is what I do. But that also means I have to call sqlite_prepare() > each time, instead of just once. I was originally hoping I could > prepare() once and

RE: [sqlite] Binding a column name?

2005-07-10 Thread Brown, Dave
Yes, actually I'm doing that already. Thanks! -Dave -Original Message- From: D. Richard Hipp [mailto:[EMAIL PROTECTED] Sent: Sunday, July 10, 2005 4:12 AM To: sqlite-users@sqlite.org Subject: RE: [sqlite] Binding a column name? On Sun, 2005-07-10 at 00:23 -0700, Brown, Dave wrote

RE: [sqlite] Binding a column name?

2005-07-10 Thread Brown, Dave
-users@sqlite.org Subject: Re: [sqlite] Binding a column name? Hi, Why not construct the SQL statement dynamically in the C/C++ code? That way your statement(s) would have variable column names before compilation. Eugene Wee Brown, Dave wrote: > Actually I doubt it can - since without the column n

RE: [sqlite] Binding a column name?

2005-07-09 Thread Brown, Dave
Actually I doubt it can - since without the column name it can't create the prepared statement byte code, right? -Dave -Original Message- From: Brown, Dave [mailto:[EMAIL PROTECTED] Sent: Saturday, July 09, 2005 8:46 PM To: sqlite-users@sqlite.org Subject: [sqlite] Binding a column

[sqlite] Binding a column name?

2005-07-09 Thread Brown, Dave
Is it possible for a bind variable to be a column name? I'd like to make a query which is: select from MyTable; and I'd like the column_name to be a bind variable. This doesn't work using the straight sqlite3_bind_text() call on the statement "select ? from MyTable;", which treats the column

[sqlite] SQLite encryption key length?

2005-07-07 Thread Brown, Dave
For those using the encrypted SQLite extension: The instructions say the max key length can be 256 *bytes*, and looking at the code does seem to confirm this. But there is also a comment at the top of the encryption code which says "change the maximum key size to 56 *bits* in order to comply

RE: [sqlite] Bug in SQLite C++ Wrapper?

2005-06-25 Thread Brown, Dave
, Brown, Dave <[EMAIL PROTECTED]> wrote: > > In looking at the SQLite C++ Wrapper > (http://dev.int64.org/sqlite.html) I noticed the example insert code has a loop like: > > for(int i=0; i<1; i++) { > cmd.bind(1, i); > cmd.executenonquery(); > } > >

[sqlite] Bug in SQLite C++ Wrapper?

2005-06-25 Thread Brown, Dave
In looking at the SQLite C++ Wrapper (http://dev.int64.org/sqlite.html) I noticed the example insert code has a loop like: for(int i=0; i<1; i++) { cmd.bind(1, i); cmd.executenonquery(); } but sqlite3_reset() isn't being called each time after the statement is executed

RE: [sqlite] How to Lock other threads out of DB until specifical ly UNlocking the DB?

2005-06-17 Thread Brown, Dave
Why not use a mutex around your database code in your program? -Original Message- From: de f [mailto:[EMAIL PROTECTED] Sent: Friday, June 17, 2005 9:58 AM To: sqlite-users@sqlite.org Subject: [sqlite] How to Lock other threads out of DB until specifically UNlocking the DB? I need to

[sqlite] Multithreading with same sqlite struct

2005-06-10 Thread Brown, Dave
I read the docs on thread safety, where it says: "Threadsafe" in the previous paragraph means that two or more threads can run SQLite at the same time on different "sqlite" structures returned from separate calls to sqlite_open(). It is never safe to use the same sqlite structure pointer

RE: [sqlite] #line macros in parse.c

2005-06-09 Thread Brown, Dave
in parse.c On June 9, 2005 03:49 pm, Brown, Dave wrote: > Are the #line macros really needed? Because on Windows if you try to > compile SQLite with Assembly, Machine Code, Source Code output files > generated at the same time ( Properties->C/C++ -> Output Files: > Assembler

[sqlite] #line macros in parse.c

2005-06-09 Thread Brown, Dave
Are the #line macros really needed? Because on Windows if you try to compile SQLite with Assembly, Machine Code, Source Code output files generated at the same time ( Properties->C/C++ -> Output Files: Assembler Output = Assembly, Machine Code and Source ) which is the /FAcs flag, the

[sqlite] Transaction for single SQL query?

2005-05-22 Thread Brown, Dave
Is there any benefit in a C program to wrapping a single insert via sqlite3_exec() in a transaction? In other words, is INSERT INTO table1 VALUES(1,2); any worse (or better) than doing: BEGIN; INSERT INTO table1 VALUES(1,2); COMMIT; Thanks, Dave

[sqlite] sqlite3_prepare() and multithreading

2005-05-21 Thread Brown, Dave
Is it ok to call sqlite3_prepare() for a statement using the sqlite3 struct owned by thread A, and then run the actual query with sqlite3_step() and sqlite3_finalize() using the [different] sqlite3 struct owned by thread B? (Assume however that both sqlite3 structs were opened to the same

[sqlite] SQLite HTML Docs for downloading?

2005-05-19 Thread Brown, Dave
Is the SQLite HTML documentation (all the pages found under www.sqlite.org/docs.html) available for download?? The site was down a bit today and that can be frustrating! -Dave

RE: [sqlite] How to get row numbers in a query?

2005-05-19 Thread Brown, Dave
So I guess I have to write my own function, "current_row()", using the sqlite3_create_function() APIs? -Dave -Original Message- From: Jay Sprenkle [mailto:[EMAIL PROTECTED] Sent: Thursday, May 19, 2005 8:40 AM To: sqlite-users@sqlite.org Subject: Re: [sqlite] How to get row numbers in

[sqlite] How to get row numbers in a query?

2005-05-18 Thread Brown, Dave
Is there any way to SELECT out the row number of returned results in a query? For example: SELECT row_number(), value from some_table; 1 ValueA 2 ValueB 3 ValueC ... etc ... ?? What I really want this for is a query where I am inserting from table A into table B, and table B has a column

RE: [sqlite] SQL to renumber values in a column?

2005-05-08 Thread Brown, Dave
all. Like: select * from table order by order_number Row 1: a, 1 Row 2: c, 3 Row 3: d, 4 The result-set row number is the order you are looking for. Regards. Xuezhang. -Original Message----- From: Brown, Dave [mailto:[EMAIL PROTECTED] Sent: Sunday, May 08, 2005 8:11 PM To: sqlite-users@

[sqlite] sqlite3.exe timed queries

2005-04-26 Thread Brown, Dave
Hi - I think it would be extremely handy to have an option in the sqlite3.exe program for printing the execution time of a query. Would that be hard to add? I'm thinking something like: sqlite3> .timed sqlite3> select * from mytable; value1 value2 value3 ... Total Time: 1.253 milliseconds

RE: [sqlite] Making a SEQUENCE?

2005-02-21 Thread Brown, Dave
from selects within the transaction. Steve -Original Message- From: Ulrik Petersen [mailto:[EMAIL PROTECTED] Sent: 21 February 2005 10:21 To: sqlite-users@sqlite.org Subject: Re: [sqlite] Making a SEQUENCE? Hi Dave, Brown, Dave wrote: >I read that faq, but I dont see how that sol

RE: [sqlite] Making a SEQUENCE?

2005-02-21 Thread Brown, Dave
lse hasn't also incremented it further before I got to it. Do you see what I mean? -Dave -Original Message- From: Ulrik Petersen [mailto:[EMAIL PROTECTED] Sent: Monday, February 21, 2005 12:49 AM To: sqlite-users@sqlite.org Subject: Re: [sqlite] Making a SEQUENCE? Hi again, Brown,

[sqlite] Making a SEQUENCE?

2005-02-21 Thread Brown, Dave
Is it possible to create the behaviour of a sequence with SQLite? I need to do something like this: [pseudocode] var id = SELECT next_val FROM my_sequence; INSERT INTO table1 VALUES(id, ...); INSERT INTO table2 VALUES(id, ...); This should return the next value, AND also increment it so that