Re: [sqlite] sqlite as server queries

2007-08-07 Thread Edwin Eyan Moragas
On 8/7/07, Gilles Ganault <[EMAIL PROTECTED]> wrote: > At 14:08 06/08/2007 +0100, "Edwin Eyan Moragas" wrote: > >2) anybody ever implemented something like a single process of sqlite > >doing queries for a lot of networked clients? > > Am working on this, in Classic VB5: Winsock control on the serv

RE: [sqlite] Help Creating database????

2007-08-07 Thread Griggs, Donald
Hi Kishore, Regarding: " Can you give me the commands to createt 'test.db' database and to create a sample table in this database? " Try Sqlite3 test.db > CREATE TABLE MyTable (a, b, c); > .quit - To unsubscribe, send

Re: [sqlite] Help Creating database????

2007-08-07 Thread Michael Hooker
Sqlite3 test.db<< And if this doesn't seem to work try using the full filepath, eg: Sqlite3 c:\Mydata\test.db. Otherwise the database will be created in whatever folder your PC currently thinks is its "home" folder. Most of us newbies end up with databases in mysterious places we only fin

Re: [sqlite] Extremely new to SQLite

2007-08-07 Thread Dennis Cote
Rahul Banerjee wrote: I'm trying to integrate SQLite into a library management system coded in C++. I'm extremely new to SQLite and the documentation at http://www.sqlite.org didn't do it for me. Can anyone give me some help/tips. All I need to do is: 1. Access db 2. Retrieve data from a partic

Re: [sqlite] sqlite as server queries

2007-08-07 Thread John Stanton
Edwin Eyan Moragas wrote: On 8/6/07, John Stanton <[EMAIL PROTECTED]> wrote: We use a single process server as an Sqlite server. It works well because it obeys certain constraints: o Transactions are always short o It has many users and many Sqlite databases, but each database does not h

Re: [sqlite] last_row_id() after insert via trigger

2007-08-07 Thread Dennis Cote
T&B wrote: Short question: When I explicitly insert a row into a table, I am able to use the last_insert_rowid() function to get the rowid of that inserted row. But how do I get the rowid of a row inserted by a trigger? It seems that last_insert_rowid() doesn't change. Tom, The short

Re: [sqlite] how to create C functions and refer to them in sql

2007-08-07 Thread John Stanton
Chase wrote: okay, wait sorry wrong question. here's the deal. i want this trigger to fire -- and insert valid guids into a table -- even outside the context of my app. using sqlite3_create_function(), i can create a sort of temporary function that only works from with my app (or o

Re: [sqlite] Security Problem C/C++

2007-08-07 Thread John Stanton
Your Sqlite code looks OK. Your problem must be in your library or linking. Severin Müller wrote: Hey I don't even get to call the sqlite3_errmsg() function. My Program crashes with the call sqlite3_open(filename,&db); I'm been spending hours now, to figure out, what may cause that crap :) I

RE: [sqlite] a c++ newbie question - prepared statements.

2007-08-07 Thread James Dennett
Stephen Sutherland [mailto:[EMAIL PROTECTED] wrote: > > Thanks this is great information on sqlite's prepared statements. > > I think I have just one more question on this subject. > > I need to execute a SQL statement like this: > "SELECT * FROM tbl WHERE BookID IN ( :arrayNumbers) ;" If

Re: [sqlite] sqlite as server queries

2007-08-07 Thread Christian Smith
Edwin Eyan Moragas uttered: On 8/6/07, Christian Smith <[EMAIL PROTECTED]> wrote: 2) anybody ever implemented something like a single process of sqlite doing queries for a lot of networked clients? A few people have implemented such a solution. It loses one of the benefits of SQLite, howeve

Re: [sqlite] Extremely new to SQLite

2007-08-07 Thread Stephen Sutherland
use the quick start code http://www.sqlite.org/quickstart.html That's what I used to build all my code from Stephen Dennis Cote <[EMAIL PROTECTED]> wrote: Rahul Banerjee wrote: > I'm trying to integrate SQLite into a library management system coded > in C++. I'm extremely n

Re: [sqlite] Extremely new to SQLite

2007-08-07 Thread Dennis Cote
Stephen Sutherland wrote: use the quick start code http://www.sqlite.org/quickstart.html That's what I used to build all my code from Stephen, The quickstart code is very old. It uses the callback function interface which is a depreciated API function that is maintained primar

RE: [sqlite] Extremely new to SQLite

2007-08-07 Thread Lee Crain
Dennis, Are you certain that the callback function interface has been deprecated? >From the link you posted: --- "2.2 Executing SQL statements typedef int (*sqlite_callback)(void*,int,char**, char**); int sqlite3_exec(sqlite3*, const char *sql, sqlite_callback, void*, char**)

RE: [sqlite] Security Problem C/C++

2007-08-07 Thread Dwight Ingersoll
> Is there any way to request the digest form of the > mailing list? Subscribe to the digest using: [EMAIL PROTECTED] Luggage? GPS? Comic books? Check out fitting gifts for grads at Yahoo! Search http:/

[sqlite] Is SQLite Case Sensitive?

2007-08-07 Thread Lee Crain
I am working on an application where I am importing data for which great care has NOT been taken to ensure uppercase and lowercase letters have been entered appropriately. Would a search for an 'a' return a different result than a search for an 'A'? SELECT * FROM table WHERE field1 = 'a';

Re: [sqlite] Is SQLite Case Sensitive?

2007-08-07 Thread P Kishor
SQL is not case-sensitive, but SQL comparisons are. Use the following SELECT * FROM table WHERE field1 = 'a' OR field1 = 'A' you can also use WHERE Lower(field1) = 'a' or WHERE Upper(field1) = 'A' On 8/7/07, Lee Crain <[EMAIL PROTECTED]> wrote: > I am working on an application where I am i

Re: [sqlite] Is SQLite Case Sensitive?

2007-08-07 Thread Cory Nelson
On 8/7/07, Lee Crain <[EMAIL PROTECTED]> wrote: > I am working on an application where I am importing data for which great > care has NOT been taken to ensure uppercase and lowercase letters have > been entered appropriately. > > > Would a search for an 'a' return a different result than a search f

Re: [sqlite] Extremely new to SQLite

2007-08-07 Thread Dennis Cote
Lee Crain wrote: Dennis, Are you certain that the callback function interface has been deprecated? >From the link you posted: --- "2.2 Executing SQL statements typedef int (*sqlite_callback)(void*,int,char**, char**); int sqlite3_exec(sqlite3*, const char *sql, sqlite_call

Re: [sqlite] Extremely new to SQLite

2007-08-07 Thread P Kishor
On 8/7/07, Dennis Cote <[EMAIL PROTECTED]> wrote: > Lee Crain wrote: > > Dennis, > > > > Are you certain that the callback function interface has been deprecated? > > > > >From the link you posted: > > > > --- > > > > "2.2 Executing SQL statements > >typedef int (*sqlite_callback)(v

[sqlite] SQL question regarding triggers updating values

2007-08-07 Thread Dennis Volodomanov
Hello all, Let's say I have this schema: CREATE TABLE Table1 (FileID INTEGER NOT NULL, FileOrder INTEGER); And I need to go through it at change FileOrder so that it becomes FileOrder of the next (or previous) FileID and that's FileID FileOrder becomes current (to put it in words - swap

Re: [sqlite] Extremely new to SQLite

2007-08-07 Thread Dennis Cote
P Kishor wrote: In which case, "deprecated" is definitely too strong, but "depreciated" might well be apt. ;-) Good catch. I missed that all together. Lee may have been using the word in the sense that the American Heritage Dictionary says is now common enough to list the milder term as

RE: [sqlite] Extremely new to SQLite

2007-08-07 Thread Lee Crain
Thanks for a detailed response, Dennis. Under some time constraints, I just finished an important implementation and used the callback function as the means of acquiring returned data. I don't want that interface to become obsolete any time soon. Maybe I need to consider migrating to the newer,

Re: [sqlite] Extremely new to SQLite

2007-08-07 Thread drh
"Lee Crain" <[EMAIL PROTECTED]> wrote: > Thanks for a detailed response, Dennis. > > Under some time constraints, I just finished an important implementation > and used the callback function as the means of acquiring returned data. > > I don't want that interface to become obsolete any time soo

RE: [sqlite] Is SQLite Case Sensitive?

2007-08-07 Thread Samuel R. Neff
Use of either "OR" or "Lower/Upper" will bypass any index and force a full table scan. Much better to use COLLATE NOCASE instead or a custom collation if you need internationalized comparisons. Sam --- We're Hiring! Seeking a passionate developer to join

RE: [sqlite] Security Problem C/C++

2007-08-07 Thread Lajos Baranyi
Thank you guys! layosh -Original Message- From: Dwight Ingersoll [mailto:[EMAIL PROTECTED] Sent: Tuesday, August 07, 2007 4:43 PM To: sqlite-users@sqlite.org; [EMAIL PROTECTED] Subject: RE: [sqlite] Security Problem C/C++ > Is there any way to request the digest form of the > mailing li