Re: [sqlite] import a CSV-File

2009-03-06 Thread Marek Paul
I use an excellent piece of software called AutoIT (http://www.autoitscript.com). AutoIt is a very flexible easy to use programming language which supports SQLite. I used it to write a csv import program for SQLite. Took me 10 minutes. If you would like to see the source as an example just say.

Re: [sqlite] import a CSV-File

2009-03-06 Thread Sylvain Pointeau
from my experience, sed will read line by line, which is not good for the CSV file.(one field can be on multiple lines). why sqlite is not enhanced to handle fully the csv file format? Cheers, Sylvain On Fri, Mar 6, 2009 at 11:33 PM, John Machin wrote: > On 7/03/2009

[sqlite] Import table in SQLite

2009-03-06 Thread kin foo
Hi I'm wondering if it is possible to import a table from an SQLite database to another SQLite database. Thanks! ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] Thread-safety and sqlite3_stmt objects

2009-03-06 Thread Shawn Wilsher
On Fri, Mar 6, 2009 at 9:26 PM, Dan wrote: > Why do you want to use a single sqlite3_stmt* from multiple threads > at the same time? Really the only thing I need to access is sqlite3_sql to copy the statement to another thread. We have an asynchronous API that we expose

Re: [sqlite] Thread-safety and sqlite3_stmt objects

2009-03-06 Thread Dan
On Mar 7, 2009, at 1:31 AM, Shawn Wilsher wrote: > Hey all, > > I've been looking online for a bit trying to establish what > protections, if > any, are associated with sqlite3_stmt objects. It's clearly > documented that > sqlite3 objects' access is serialized across threads, but I cannot

Re: [sqlite] SQLite Transaction Rate and speed...

2009-03-06 Thread Nuzzi
Griggs, Donald-3 wrote: > > Regarding: > sorry.. no luck either... or I have a personal problem with your ftp > server -- he doesn't like my anonymous login... ;) > > == > > I get an error of "421 Too many users logged in for this account." > > I

Re: [sqlite] SQLite Transaction Rate and speed...

2009-03-06 Thread Jim Dodgen
if you need to always replace or create an new row you might just do a "INSERT OR REPLACE" which will replace the record if it exists or insert a new one if it does not. On Fri, Mar 6, 2009 at 3:10 PM, Griggs, Donald wrote: > Regarding: >    sorry.. no luck

Re: [sqlite] SQLite Transaction Rate and speed...

2009-03-06 Thread Marcus Grimm
sorry.. no luck either... or I have a personal problem with your ftp server -- he doesn't like my anonymous login... ;) > > > Marcus Grimm wrote: >> >> I'm afraid you can't post an attachment here... >> try it differently. >> >> > > Hmm... Bummer. Here are some links (hopefully): > >

Re: [sqlite] SQLite Transaction Rate and speed...

2009-03-06 Thread Nuzzi
Marcus Grimm wrote: > > I'm afraid you can't post an attachment here... > try it differently. > > Hmm... Bummer. Here are some links (hopefully): ftp://ftp.smokemytool.com/pub/matrix_file_db.cpp matrix_file_db.cpp ftp://ftp.smokemytool.com/pub/matrix_file_db.h matrix_file_db.h John --

Re: [sqlite] import a CSV-File

2009-03-06 Thread John Machin
On 7/03/2009 6:16 AM, Rich Shepard wrote: > On Fri, 6 Mar 2009, Hans-Martin wrote: > >> It seems that there is no way to get rid of the embedded CR/LF without parse >> the complete output. > >Use sed. That's what it's for. Has anyone considered that getting rid of the embedded CR/LF is

[sqlite] problem with sqlite storing TCL scripts

2009-03-06 Thread anjela patnaik
Hello all,   I've used sqlite3 .read command to read in an SQL file from (exported via TOAD) Oracle that contains TCL scripts.   The .read worked fine, but now I'm noticing that my multi-line scripts are not running properly on the shell when I retrieve them from the sqlite table.   I notice

Re: [sqlite] SQLite Transaction Rate and speed...

2009-03-06 Thread Marcus Grimm
I'm afraid you can't post an attachment here... try it differently. > > > > Marcus Grimm wrote: >> >> you should in any case try to encapsulate your >> inserting loop with a transaction. you should still >> be able to do select statements inside, in particular >> if all is done within one DB

Re: [sqlite] SQLite Transaction Rate and speed...

2009-03-06 Thread Nuzzi
Marcus Grimm wrote: > > you should in any case try to encapsulate your > inserting loop with a transaction. you should still > be able to do select statements inside, in particular > if all is done within one DB connection. > transactions do not speed up considerably, they do it

Re: [sqlite] shared cache and SQLITE_MISUSE on sqlite3_step()

2009-03-06 Thread Marcus Grimm
strange... I can hardly believe that... did your test app probably reading only ? Marcus > Without wishing to complicate the subject, I have found that retrying a > sqlite3_step() after receiving SQLITE_LOCKED works fine for me without > needing sqlite3_reset(). I do this in a multi-threaded

Re: [sqlite] SQLite Transaction Rate and speed...

2009-03-06 Thread Nuzzi
ken-33 wrote: > > > > look at the sql syntax for insert or replace for sqlite. > > Also you goal to handle 1 million per minute is probably going to be > dependant upon your hardware. > > For instance throughput greatly increases with disk striping. > > Also the faster the RPM of the

Re: [sqlite] SQLite Transaction Rate and speed...

2009-03-06 Thread Ken
look at the sql syntax for insert or replace for sqlite. Also you goal to handle 1 million per minute is probably going to be dependant upon your hardware. For instance throughput greatly increases with disk striping. Also the faster the RPM of the drive the more transactions can be

Re: [sqlite] Looking for results from one table based partially onresults from another

2009-03-06 Thread Mike Yenco
Thanks Igor. It works great. -Mike On Mar 5, 2009, at 3:19 PM, Igor Tandetnik wrote: > and ItemizeID in ( >select ItemizeID from Items where Description LIKE > %[[searchstring]]% > ) > > Igor Tandetnik ___ sqlite-users mailing list

[sqlite] SQLite Transaction Rate and speed...

2009-03-06 Thread Nuzzi
I have a project where I have to be determining if a row exists, if so get the data, change it, and then write it back, if not, then just writing the data. I have to be able to do millions of these per minute. Is that pretty much impossible with SQLite or any other DB? Thanks, John -- View

Re: [sqlite] import a CSV-File

2009-03-06 Thread Rich Shepard
On Fri, 6 Mar 2009, Hans-Martin wrote: > It seems that there is no way to get rid of the embedded CR/LF without parse > the complete output. Use sed. That's what it's for. Rich -- Richard B. Shepard, Ph.D. | IntegrityCredibility Applied Ecosystem Services, Inc.

Re: [sqlite] import a CSV-File

2009-03-06 Thread Hans-Martin
Am Freitag, 6. März 2009 18:29:58 schrieb Griggs, Donald: ... > Hi Hans, Hi Donald! > > The sqlite command-line utility program does not have code in it to > handle quoted strings containing the field separator (comma, in your > case), nor does it expect the multi-line data. > > If you can

[sqlite] Thread-safety and sqlite3_stmt objects

2009-03-06 Thread Shawn Wilsher
Hey all, I've been looking online for a bit trying to establish what protections, if any, are associated with sqlite3_stmt objects. It's clearly documented that sqlite3 objects' access is serialized across threads, but I cannot find anything about sqlite3_stmt. I don't actually care either way,

Re: [sqlite] shared cache and SQLITE_MISUSE on sqlite3_step()

2009-03-06 Thread Dave Toll
Without wishing to complicate the subject, I have found that retrying a sqlite3_step() after receiving SQLITE_LOCKED works fine for me without needing sqlite3_reset(). I do this in a multi-threaded test app (based on some old SQLite test code) that I have left running with 10 threads for a long

Re: [sqlite] SQLLite support for Silverlight

2009-03-06 Thread Michael Sync
thanks, Kosenko. I don;t think that everyone will have Google Gear installed on their browsers. Actually, if they are using IE then i can probably create an ActiveX object of ADODB in JS. But I'm looking for platform-independent way as Silverlight works on non-Windows platform as well. On Fri,

Re: [sqlite] sqlite3 datbase disk image malformed

2009-03-06 Thread Peter van Dijk
On Thu, Mar 05, 2009 at 04:30:50AM -0800, donnied wrote: > > rsync was corrupting the database. I'll have to exclude the database from > rsync backup. I feel a need to point out that it is not, technically, rsync that was corrupting the database. The issue is that rsync does not take

Re: [sqlite] [sqlite-dev] SQLLite support for Silverlight

2009-03-06 Thread Jeffrey . a . Becker
1) Please ask this type of question on the sqlite-users mailing list. 2) No there isn't. If you'd like a more in-depth explanation of why start a thread on http://sqlite.phxsoftware.com/forums/ and I will answer there. On Mar 5, 2009 1:09pm, Chris Morgan wrote: > On Thu,

Re: [sqlite] [sqlite-dev] SQLLite support for Silverlight

2009-03-06 Thread Chris Morgan
On Thu, Mar 5, 2009 at 12:57 PM, Michael Sync wrote: > Hello, > > Is there any way to support SQLLite in Silverlight? Let's say I have a > SQLLite database in Isolated Storage and want to connect that database from > Silverlight without using any service. > > Do we need to

Re: [sqlite] Are there distillate posts in the sqlite3 board?

2009-03-06 Thread Ribeiro, Glauber
Are you looking perhaps for digest mode? Yes, there is a digest mode for the SQLite email lists, it's one of the options you can set up. Or are you thinking of posts that were made under the influence of distillates? :) g -Original Message- From: liubin liu [mailto:7101...@sina.com]

Re: [sqlite] shared cache and SQLITE_MISUSE on sqlite3_step()

2009-03-06 Thread Hynes, Tom
Thanks Dan! -Original Message- From: sqlite-users-boun...@sqlite.org [mailto:sqlite-users-boun...@sqlite.org] On Behalf Of Dan Sent: Thursday, March 05, 2009 10:08 PM To: General Discussion of SQLite Database Subject: Re: [sqlite] shared cache and SQLITE_MISUSE on sqlite3_step() On Mar

Re: [sqlite] shared cache and SQLITE_MISUSE on sqlite3_step()

2009-03-06 Thread Kees Nuyt
On Fri, 06 Mar 2009 10:26:38 +0100, Marcus Grimm wrote: >The website is allready excellent, I'm not at all complaining... > >Anyway, I've placed an updated version of the thread test program on the >web: > >http://www.exomio.de/sqlitethreadtest.c > >If somebody found it

[sqlite] import a CSV-File

2009-03-06 Thread Hans-Martin Bundeshund
Hello to the List! I started using SQLite (3.6.11) under WindowsXP and get confused using the import-function. The import runs well with most lines, but i get an error when it comes to following cases: Case 1, the ',' between a string: "Text of field1","Text of field2, not for field1"

Re: [sqlite] which func could get the number of rows

2009-03-06 Thread Kees Nuyt
On Fri, 6 Mar 2009 02:15:10 -0800 (PST), liubin liu <7101...@sina.com> wrote: >which func could get the number of rows? There is no function to retrieve the number of rows in a result set. SQLite doesn't know the number in advance, but returns row by row while iterating through the tables. The

Re: [sqlite] Performance impact for heavy accessing the database file

2009-03-06 Thread Kosenko Max
Ribeiro, Glauber wrote: > If it's all reads, you're fine, but if anyone is writing, all others are > blocked until that transaction is finished. And actually SQLite can't read at the exactly same time in several threads in case it's compiled as a thread safe. -- View this message in context:

Re: [sqlite] SQLLite support for Silverlight

2009-03-06 Thread Kosenko Max
Michael Sync wrote: > > Is there any way to support SQLLite in Silverlight? Let's say I have a > SQLLite database in Isolated Storage and want to connect that database > from > Silverlight without using any service. > > Do we need to create our own database driver? I'm also a developer but I'm

Re: [sqlite] which func could get the number of rows

2009-03-06 Thread John Machin
On 6/03/2009 9:15 PM, liubin liu wrote: > which func could get the number of rows? select count(*) from your_table_name; ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

[sqlite] which func could get the number of row

2009-03-06 Thread liubin liu
which func could get the number of row? -- View this message in context: http://www.nabble.com/which-func-could-get-the-number-of-row-tp22369246p22369246.html Sent from the SQLite mailing list archive at Nabble.com. ___ sqlite-users mailing list

Re: [sqlite] shared cache and SQLITE_MISUSE on sqlite3_step()

2009-03-06 Thread Marcus Grimm
Dan wrote: > On Mar 6, 2009, at 1:48 PM, Marcus Grimm wrote: > >> I just want to add another hint that I learned yesterday: >> >> when sqlite3_step() returns SQLITE_LOCKED be aware >> that sqlite3_reset() will most likely also return >> SQLITE_LOCKED and thus it is necessary to repeat calling >>

[sqlite] Are there distillate posts in the sqlite3 board?

2009-03-06 Thread liubin liu
are there any distillate posts in the sqlite3 board ? -- View this message in context: http://www.nabble.com/Are-there-distillate-posts-in-the-sqlite3-board--tp22368215p22368215.html Sent from the SQLite mailing list archive at Nabble.com. ___