RE: [sqlite] SQL query, finding out which row a result is in

2007-04-23 Thread Griggs, Donald
Hi Roy, If your statement "X" is represented below by "select ... Order by ..." Then would the following give you what you're looking for?? create temp table Xtab as (select Order by ); select ROWID from xTab where MemberID=4567373; (Without some "order by" clause, by the

RE: [sqlite] Odd performance issue under Windows

2007-04-25 Thread Griggs, Donald
John Elrick wrote: > "what the heck is happening that is creating a better than order of > magnitude difference in execution time on five out of seven Windows > machines?". John, If the database is opened and closed just once for your testing, I think you can find out if buffer flushing is

RE: [sqlite] Odd performance issue under Windows

2007-04-26 Thread Griggs, Donald
I may be confused a bit. Regarding: 1) "the described slowdown occurs consistently on Windows XP Home and Pro and on Windows Vista." On its face, I would think this means that Xp Home and Vista do *NOT* have a problem, and that "fast" behaviour represents an integrity-risk problem. Regarding:

RE: [sqlite] Best way to optimize this query?

2007-05-02 Thread Griggs, Donald
Hi Tito, People ROWID, idx GUID, idx First, idx Last, idx Email ... The ROWID is indexed implicitly I believe, so it may be slowing things slightly if you index it explicitly. Regarding: "What if I have, say, 500 to retrieve?" You can create a

RE: [sqlite] FW: Performance problem with complex where clause

2007-05-02 Thread Griggs, Donald
regarding: "So it seems that indexes are not used at all, and that is pretty strange" There's a great feature in sqlite that lets you know for sure. Prefix your query with: EXPLAIN QUERY PLAN SELECT . And you can see just which, if any indices are used. For a more detailed

RE: [sqlite] Powered by SQLite image?

2007-05-04 Thread Griggs, Donald
Regarding: Is there any image/logo with "powered by SQLite"? You know, people with web services (not webservices) that rely on SQLite might like to say that to others :) Well, Alberto, there *was* one, but it was so very tiny, lightweight, and efficient that few could actually see it. ;-)

RE: [sqlite] Re: How to obtain the integer part of a result

2007-05-07 Thread Griggs, Donald
Hello, A.J. Regarding: I couldn't find that sentence (CAST) in the SQLite doc, neither in the Owens's book. Is it a SQL standard?, or a built-in SQL function? or a SQLite built-in aggregate function? You'll want to see the *syntax* section of the website, under the very useful page on

RE: [sqlite] baffled by dates

2007-06-04 Thread Griggs, Donald
Hi Chris, I think you've seen Rich Shepard's reply, and emails crossed. But just in case you didn't: The sqlite date/time functions require input dates to contain a preceeding zero for month and day-of-month where needed to make them two digits. E.g., '2007-6-4' bad '2007-06-04'

RE: [sqlite] performances tool

2007-06-11 Thread Griggs, Donald
Hello, Ghislain, Regarding: any tool or instrument which could help me to analyze the performances of SQLite You may want to write again and be a bit more specific. What operating system are you using? What wrapper, if any? Do you need to analyze your SQL and try to make it run more

RE: [sqlite] How can I convert from Julian time to a tm structure?

2007-06-13 Thread Griggs, Donald
Hi Rob, Regarding: One thing I want to do is to move the conversion of the timestamp from a Julian time to a human-readable time from the query to my application. I may not understand your request fully, but are you asking for more information than is provided in the source files for the

RE: [sqlite] auto_increment and not null

2007-06-28 Thread Griggs, Donald
Regarding: "I'm aware of the create table syntax. And according to it I can declare a column as INTEGER AUTO_INCREMENT NOT NULL. So I wonder why this doesn't work (in MySQL it does!)." To underscore -- the difficulty: Maybe it was just a typing mistake in your message, but according to

RE: [sqlite] Database Level Unique Sequence

2007-07-02 Thread Griggs, Donald
Re: "I would like to know how to create an Autoincrement field and insure that it is unique across the database [not just within one table]...] Hi Andre, Do you mind saying why it is you need the field to be unique across all tables? Wouldn't the fact that a key is unique within its own table

RE: [sqlite] Replicating table data from sqlite to ms sql server

2007-07-10 Thread Griggs, Donald
Regarding: I'm new to sqlite and I was wondering if there is a way to programmatically replicate table data from a database in sqlite server to another database in ms sql server? I'm hoping to do this without any user intervention(the application will do it automatically). Is this possible?

RE: [sqlite] Importing a big text file (CSV?)

2007-07-19 Thread Griggs, Donald
Regarding: "Meanwhile I found an '.import' command on SQLite, but I can't find a suitable documentation on how it works." It can be easy to miss page: http://www.sqlite.org/sqlite.html where this is documented. Basically, it sounds like you might want to invoke the command line utility,

RE: [sqlite] Is SQLite Scalable to handle large data?

2007-07-27 Thread Griggs, Donald
-Original Message- From: Bharath Booshan L [mailto:[EMAIL PROTECTED] Sent: Friday, July 27, 2007 4:31 AM To: sqlite-users@sqlite.org Subject: [sqlite] Is SQLite Scalable to handle large data? Hello, I have been using SQLIte database for one of my application (stand -alone). It

RE: [sqlite] A Data Importation Question

2007-07-31 Thread Griggs, Donald
Hi Lee, If I answer wrongly here, I trust (and hope) someone will correct me: Regarding: "I need a way to programmatically import data from flat files..." Sqlite itself is designed to be small and simple -- for some embedded uses even the sql parser is removed. I don't think there's an api

RE: [sqlite] UI question

2007-08-02 Thread Griggs, Donald
-Original Message- From: Scott Derrick [mailto:[EMAIL PROTECTED] Sent: Thursday, August 02, 2007 10:22 AM To: sqlite-users@sqlite.org Subject: [sqlite] UI question This is probably a stupid question but has frustrated me a couple of times. When using the command line interface

RE: [sqlite] How to Speed of Inserts

2007-08-03 Thread Griggs, Donald
Regarding: "Is there away to maximize this speed dramatically ...?" Yes, be sure to surround your inserts with a single transaction (i.e., "BEGIN", "END"). If you were doing millions of inserts, you might want to use a new transaction after each, say, 5 thousand inserts. If you don't

RE: [sqlite] Strange behaviour on Update

2007-08-03 Thread Griggs, Donald
-Original Message- From: Luís Santos [mailto:[EMAIL PROTECTED] Sent: Friday, August 03, 2007 2:41 PM To: sqlite-users@sqlite.org Subject: [sqlite] Strange behaviour on Update Hi, Ppl We have found a strange behaviour on SQLite 3.4.1 (We have also tested against versions 3.0.8, 3.2.5

RE: [sqlite] UI question

2007-08-05 Thread Griggs, Donald
Regarding: " Where I get tripped up is making a typo in a multiline query that may have destructive effects if I terminate with a ';' and allow the CLI to execute the query. To date I have aborted the CLI with a ^C (MS Windows). I would love have a means of escaping/cancelling back to the prompt

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,

RE: [sqlite] Re: auto_increment - why does it do the opposite?

2007-08-09 Thread Griggs, Donald
Regarding: " This works, probably because sqlite doesn't enforce column types..." Yes, you can create table ABC ( myCol WARM_AND_FUZZY); And this will be parsed without error. - To unsubscribe, send email to

RE: [sqlite] Creating index takes over an hour

2007-08-09 Thread Griggs, Donald
Regarding: > > cat your.db > /dev/null > > Using Windows XP. :-0 --- >Anyone know a simple Windows command line equivalent of the cat to dev null command above to put a file into OS cache? >You could write a small C program to do this, I suppose.

RE: [sqlite] Need To Export A Table From a SQLite Database as a TAB Character Delimited Text File

2007-08-13 Thread Griggs, Donald
Hi Lee, Regarding: ...I need to export a table from a SQLite database as a TAB character delimited text file. Try the following .separator "\t" .output ExportFile.txt select * from MyTable; .output stdout - To

RE: [sqlite] Need To Export A Table From a SQLite Database as a TAB Character Delimited Text File

2007-08-13 Thread Griggs, Donald
Regarding .separator "\t" Vs .separator '\t' Cool. BTW, It seems to require double quotes for me, running Windoze XP, sqlite3.exe version 3.4.0, else the separator becomes literally a backslash followed by the letter t. I'm guessing you're using *NIX and guessing it requires single

RE: [sqlite] Columns from nested joins aren't properly propagated

2007-08-17 Thread Griggs, Donald
Regarding: "The issue is: the above and similar queries are generated automatically, the same code (query) is used in MySQL, Postgrees and Oracle AND, as it is not my code that generates these expressions, I cannot modify the generating code of these queries." I don't mean to be

RE: [sqlite] Order by

2007-09-04 Thread Griggs, Donald
Regarding: "Is there any other method where i can store the sorted results and use that whenever needed instead f doing order by each time." You're using an index on the "Albums" column, right? If not, that will make a tremendous difference. This message has been scanned for viruses by

RE: [sqlite] Re: Problem flushing double

2007-09-12 Thread Griggs, Donald
Regarding: "Yes, but shouldn't I avoid the representation problem..." I can envision a sign over the entrance to floating point computer numbers saying, "ABANDON ALL HOPE OF EQUALITY TESTS, ALL YE WHO ENTER HERE." I think that even casting a value as floating point means that you're willing

RE: [sqlite] Re: Re: Index usage with LIKE queries

2007-09-12 Thread Griggs, Donald
Regarding: "I thought I can create two separate indexes" I believe sqlite can use at most *one* index per table in a select. However, you can create *compound* indicies (though all the restrictions pointed to by Dr. H still apply) http://www.sqlite.org/optoverview.html#like_opt This

RE: [sqlite] SQL command support question

2007-10-01 Thread Griggs, Donald
Regarding: "I was wondering if SQLite supports the command SELECT ... INTO OUTFILE ..." No, but the sqlite3 command-line utility supports an equivalent: .output outfile.csv .select . .output stdout You may also want to look at the commands .separator .mode .header

RE: [sqlite] SQL command support question

2007-10-02 Thread Griggs, Donald
Regarding: I'm accessing SQLite through a JDBC driver in a java program, but I get an error everytime I use SQLite line command (like ".output"). Is it because the driver doesn't understand those commands?" Commands such as ".output" are not part of sqlite proper. They are part of the

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

2007-10-17 Thread Griggs, Donald
Regarding: "... when a query is issued, does SQLite cache the results, so that future queries can be processed off the cache (I think not) " Hi Uma, In effect, powerful caching effects *do* occur because of the disk cache provided by modern operating systems. Since the hard disk operations

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

2007-10-17 Thread Griggs, Donald
Regarding: "... when a query is issued, does SQLite cache the results, so that future queries can be processed off the cache (I think not) " ... = P.S. And I should certainly have mentioned the sqlite items below: http://sqlite.org/pragma.html PRAGMA cache_size=

RE: [sqlite] DB managers that do searches?

2007-10-30 Thread Griggs, Donald
Hi Bernie, regarding: "...and not having a search is a real hassle" I'm not at all sure I understand. SQLITE (and all the DB managers I know of that incorporate it) supports most of the SQL 92 language, which allows rather sophisticated searching via the SELECT statement. It's not normally the

RE: [sqlite] Suggests for improving the SQLite website

2007-11-09 Thread Griggs, Donald
I'd echo the suggestion for making the directions for import/export more prominent (which may mean simply linked from multiple places). Perhaps I'd also suggest linked to the command-line tool information from several places, maybe including the SYNTAX area. Newcomers seem to be able to miss

RE: [sqlite] BLOB data performance?

2007-11-13 Thread Griggs, Donald
Regarding: The problem with many files in a directory: Another possible algorithm: Simply name the blob using the ROWID, e.g. Image0783.png In ancient days, a DOS directory of several hundred files might bog things down, but you can put thousands into a modern O.S.'s directory if

RE: [sqlite] suggestion on improving performance on UPDATE

2007-11-13 Thread Griggs, Donald
Regarding:building a 100 row x 2000 column matrix If by chance these are sparse matrices (i.e., the majority of the values are empty) then conceivably you could store only the available values. The schema might then be something like: CREATE TABLE myTable ( matrixRow INTEGER,

RE: [sqlite] Resetting a Primary Key

2007-11-20 Thread Griggs, Donald
Hi Mitchell, I don't know that resetting the primary key would be productive, since rollover of INTEGER PRIMARY KEY would not occur anywhere even remotely close to 15000. Are you sure you aren't somehow attempting an insert of a key that has already been used -- perhaps because of some race

RE: [sqlite] Checking out the performance of sqlite3

2007-11-21 Thread Griggs, Donald
From: kirrthana M [mailto:[EMAIL PROTECTED] Sent: Wednesday, November 21, 2007 4:25 AM "Just want to know the time it takes to read and write data,.." - Hello, Kirrthana, Much depends upon your data, your schema, your settings within SQLITE (e.g. do you require ACID transactions?)

[sqlite] version 3.3.12 -- malformed schema after using "limit 0" ??

2007-11-29 Thread Griggs, Donald
I don't know if the following might be a problem with the new release, or just something odd on my system. In sqlite 3.3.12, I try to create an empty table copying the schema of an existing table by using a command such as the following: CREATE TABLE newtable AS SELECT * FROM oldtable LIMIT

RE: [sqlite] version 3.3.12 -- malformed schema after using "limit 0" ??

2007-11-30 Thread Griggs, Donald
regarding: "Problem fixed by check-in [3993] on 2007-05-14 14:05 GMT." Argh! I stupidly had downloaded the current version but somehow was using the old 3.3.12 version when encountering the error. My apologies to the list.

RE: [sqlite] Querying DATE column with date/time string.

2007-12-06 Thread Griggs, Donald
Hi Doug, You're not storing the dates as anything other than plain text, so the short value: '2008-01-01' is lexigraphically "less than" your lower bound string of: '2008-01-01 00:00:00' and so falls outside the range of your "BETWEEN" select. If you want to keep treating the strings as

RE: [sqlite] Indexes not being used after INNER JOINS?

2007-12-31 Thread Griggs, Donald
Hello Hugo, If you preceed a SELECT with the string EXPLAIN QUERY PLAN sqlite will make it clear which, if any, indices it would use when running the select. Sqlite, unlike some of the "non-light" databases, uses a maxium of one index per table per select, I believe. You may want to look at

RE: [sqlite] SQLITE_CORRUPT error

2008-01-03 Thread Griggs, Donald
Regarding: >>I suspect the answer is no, but is there any way to salvage any of the data? >You could try the .dump command in the command line tool, but I'm afraid you're out of luck. Maybe this is implied, but you might also try to .DUMP tables *invididually* if .DUMP'ing

RE: [sqlite] Date Problems

2008-01-03 Thread Griggs, Donald
regarding: >>2006/03/31 minus 1 month : I could accept 28 Feb or 1 Mar as a reasonable answer and I can make that point to my users. >>03 March is not reasonable, I can't think of any logic that would give me that answer and I'm not able to make any case. I believe the logic used is to

RE: [sqlite] free excel-like COLORFUL gui for sqlite

2008-01-08 Thread Griggs, Donald
Regarding Moving colorful spreadsheet to sqlite. -- Would Christian Werner's free ODBC interface allow you to use the same spreadsheet to access an sqlite database? http://www.ch-werner.de/sqliteodbc -- Lots of automation can be performed within Excel spreadsheets (and, I imagine,

RE: [sqlite] Aggregates in SELECT without GROUP BY

2008-01-14 Thread Griggs, Donald
Hi Duncan, Regarding: " A DBMS accepting such queries isn't just a little dangerous, its flat out wrong. I would ask what rationale there is for this query not failing. -- Darren Duncan" I'm not asserting that you have to agree with the rationale, but did you see and read the discussion that

RE: [sqlite] Foreign Constraint Triggers Across Attached Databases

2008-01-24 Thread Griggs, Donald
From Nico: You could always copy the users_history table records to an attached DB and "delete from users_history;" after every, or every N, transactions on your main DB. This ways your users_history table size is bounded in the main DB and you still get to keep all your history in a separate

RE: [sqlite] Using LIKE to check the first digits?

2008-02-01 Thread Griggs, Donald
Regarding: >>Indices won't help with LIKE unless the column as a NOCASE collation. Use GLOB instead: >> ... WHERE number GLOB '1234*'; >>Note that "*" is the wildcard character with GLOB, not "%" >>as in LIKE. The above will use an index on the number column if it is available.

Re: [sqlite] replacing all newlines in a field

2008-02-11 Thread Griggs, Donald
Hi Puneet, Question: Is there a way I can search and replace all the line breaks? x'hh' should work, where hh are hex digits. So if your file contained hex 0D type line breaks: UPDATE t SET essay_without_newlines = Replace(essay, x'0D', '~'); This email and any attachments have been

RE: [sqlite] Replace of substring in sqlite-table - how can I do this?

2006-08-07 Thread Griggs, Donald
Hi Wolfgang, Regarding: "...thank you very much for your reply. But is there no command within sqlite to do this? In my case, only substrings of the cells of one column need to be changed!" Sqlite was designed as a small SQL library -- extremely small, considering its capabilities --

RE: [sqlite] Recovery tool ?

2006-08-08 Thread Griggs, Donald
"...alimentation interruption..." --- Power interruption -- fascinating how languages work! Yohann, Sqlite tends to be pretty good in the face of power interruptions on most OS's, sorry you are having trouble. I think you'll want to: 1) copy your database in its current state (for

RE: [sqlite] how to ".import" an Ascii file

2006-08-29 Thread Griggs, Donald
Hi Randall, Regarding: how to ".import" an Ascii file (separator is " ") Assuming that no translations have occurred in transit, it looks as though you're using a single ascii space as a separator. So, given a file such as: cat dog koala bananna orange kiwi You should be able to import it

[sqlite] The term "flat-file" as applied to sqlite

2006-09-25 Thread Griggs, Donald
I've noticed that more than one contributor to this list has referred to sqlite as a "flat file database." I had always thought of a flat file as a file composed of single table of records, with records defined either by fixed-width allocations or by some sort of delimiter (e.g.,

RE: [sqlite] Problem with .import

2006-09-28 Thread Griggs, Donald
Regarding Rich Shepard's problem: "...tells me that 31 columns are expected, but it found 32." And tagging onto Dennis Cote's explanation: "...I suspect you may have trailing spaces at the ends of your lines." I agree with Dennis. Apparently there are different interpretations for

RE: [sqlite] Problem with EXPLAIN in Sqlite-3.3.5

2006-09-29 Thread Griggs, Donald
Re: EXPLAIN is omitted by default. Recompile with -DSQLITE_DEBUG=1 to turn it on. That certainly explains it. - To unsubscribe, send email to [EMAIL PROTECTED]

RE: [sqlite] Optimize performance - reading from multiple databas e files, processing and writing to separate results database file?

2006-10-04 Thread Griggs, Donald
Hi Serena, I hope that more expert users will chime in here, but my initial thoughts were: -- 1 Gbyte is not at all too big for Sqlite to handle in one file. -- Some portion (large??) of the performance advantages of transactions will be lost in opening/closing files, even if transactions were

RE: [sqlite] Optimize performance - reading from multiple databas e files, processing and writing to separate results database file?

2006-10-04 Thread Griggs, Donald
Regarding: "...I believe my only option is to attach databases one at a time,..." I can't say I know enough of your system to be sure, but keeping each subject's data in a separate database may not serve you well in the long run. Since I would suspect you will want to do various searches that

RE: [sqlite] new sqlite-based webserver

2006-10-11 Thread Griggs, Donald
Greetings, Günter, Regarding: "...my server is running at home ... and has a dsl-(2mbit) connection to the world." Do you know if your connection is symmetric? In the U.S. most all home DSL circuits are ADSL, with the upload maximum speed just a fraction of the download maximum. Places like

RE: [sqlite] Escaping wildcards when using LIKE & UTF-16

2006-10-16 Thread Griggs, Donald
Re: "..a possible optimization I'm thinking of ..." Is it simple to place, say, 10 SQL Bind operations in series, then see if this time is even perceptible? Since this is a human interface, is it not likely that any efforts to avoid the binds will go unnoticed because the execution time is so

RE: [sqlite] Re: number problem with 3.2.8

2006-10-25 Thread Griggs, Donald
-Original Message- From: Lloyd Thomas [mailto:[EMAIL PROTECTED] Sent: Wednesday, October 25, 2006 7:49 PM To: sqlite-users@sqlite.org Subject: Re: [sqlite] Re: number problem with 3.2.8 I did try number literal >10 but mad no difference. I will rebuild the database row as an integer.

RE: [sqlite] Dropping Tables

2006-11-08 Thread Griggs, Donald
Regarding: "Since I cannot learn how to drop a table from a database by referring to Owens' book, I hope that someone here can point me in the right direction." See: http://www.sqlite.org/lang_droptable.html Just take the syntax link for most any syntax question:

RE: [sqlite] Importing text file via .bat file

2006-11-15 Thread Griggs, Donald
Regarding: "...but how would I combine all this in one .bat file ...?" Hello, RBS. The following is in windows commandline syntax: Echo .mode csv >MyCommands.tmp Echo .import ReadCode.txt ReadCode >>MyCommands.tmp Sqlite3 ReadCode.db ".read myCommands.tmp" or,

RE: [sqlite] Importing text file via .bat file

2006-11-15 Thread Griggs, Donald
Echo .mode csv >MyCommands.tmp Echo .import ReadCode.txt ReadCode >>MyCommands.tmp Sqlite3 ReadCode.db ".read myCommands.tmp" = -Original Message- From: RB Smissaert [mailto:[EMAIL PROTECTED] Sent: Wednesday, November 15, 2006 1:13

RE: [sqlite] Re: Saving tables

2006-11-27 Thread Griggs, Donald
Regarding: sebcity <[EMAIL PROTECTED]> wrote: > ... After you create your tables how do you save them so > they are permenently there? And Igor T's reply: They are "permanently there" from the very moment you create them. All changes are written to the database file when a >>transaction is

RE: [sqlite] a question about muticonnection

2006-12-06 Thread Griggs, Donald
-Original Message- From: Nikki Locke [mailto:[EMAIL PROTECTED] Sent: Wednesday, December 06, 2006 6:06 AM To: sqlite-users@sqlite.org Subject: Re: [sqlite] a question about muticonnection Hongdong wrote: > I just have a base question: > assume user A and user B now both connection to

RE: [sqlite] Joining tables in a single file

2006-12-29 Thread Griggs, Donald
Regarding: " I need something like: cat A.db B.db C.db > full.db # kidding" - Hi Alberto, My first inclination is to consider this a classic use of the ATTACH DATABASE command http://www.sqlite.org/lang_attach.html

RE: [sqlite] Odd indexing behavior, 2nd request for help

2007-01-04 Thread Griggs, Donald
Hi Michael, Regarding: "I sent this 2 days a go but have not received an explanation or solution. Anybody had this problem?" Joe Wilson tried providing some explanation on 2 January: "Hitting both the index and the underlying table can often be slower than just doing a table scan if you have

[sqlite] Sqlite used in open source phone system (pbx)

2007-02-01 Thread Griggs, Donald
Maybe this is old news, but I noticed that Sqlite is used by "OpenPBX," an open source PBX. I would think it's yet another tribute to Sqlite's reliability that it was chosen to run in a phone switch. - OpenPBX is a fork of the Asterisk PBX. On the home page of the OpenPBX

RE: [sqlite] Is there a SQLiteSpy-like thing that will let me change data from a grid?

2007-02-06 Thread Griggs, Donald
Regarding: "If I want to change data ." Sqlite3Explorer is free software, and works as you describe. I imagine there are several others. http://www.singular.gr/sqlite/ (Not sure if there will be future releases of this or not) [opinions are my own, not necessarily those of my

RE: [sqlite] Performance problems potentially related to index scalability

2007-02-08 Thread Griggs, Donald
Regarding: "...Next, I add in an index on [one] of my numeric columns. ... This is where the problem comes in." You may already know this, but if you can tolerate waiting until the loads are complete before adding the index, the total performance should be better.

RE: [sqlite] SQL query - TOP

2007-02-16 Thread Griggs, Donald
Regarding: "It would appear that the "TOP" syntax is not supported by SQLite (maybe just a Microsoft thing?). However is there an alternative? " Take it to the "LIMIT", Mark. See: http://sqlite.org/lang_select.html The LIMIT clause places an upper bound on the number of rows returned in

RE: [sqlite] Importing data without a primary key

2007-02-28 Thread Griggs, Donald
-Original Message- From: Sebastian Tennant [mailto:[EMAIL PROTECTED] Sent: Wednesday, February 28, 2007 12:56 PM To: sqlite-users@sqlite.org Subject: [sqlite] Importing data without a primary key Hi all, I have a CSV file of data that doesn't include a column suitable to be the primary

RE: [sqlite] Performance problem

2007-03-01 Thread Griggs, Donald
Regarding: "Can only one index be used per query?" Yes, I believe that *is* the defined behaviour of sqlite (though it does support compound indicies). Larger DBMS often have very involved code to determine query plans.

RE: [sqlite] Re: Any way to know the numbers of rows affected by a cmd?

2007-03-01 Thread Griggs, Donald
Regarding: Anderson, James H (IT) wrote: > I guess I forgot to mention the context. I'm interested in doing this > from the cmd shell. > > James, You can use the command pragma count_changes=1 in the shell to have it report the number of rows affected by insert, update, or delete

RE: [sqlite] Question about regexp function

2007-03-03 Thread Griggs, Donald
Hi Neil, Re: " I would like to perform regular expression queries interactively, i.e. from the sqlite> prompt"I I'm not sure what operating system you're using, but there are sqlite GUI utilities that register a REGEX function. In windows, one such free one is Sqlite3Explorer:

RE: [sqlite] A few (probably) simple questions ...

2007-03-06 Thread Griggs, Donald
Stef, Regarding: "(I'm interested in this differences, because I'm trying to generate SQL statements from a visual design, like in MS-Access. If anyone knows good literature about generating SQL statements from graphical designs, I'ld be much obliged.)" === I wondered if the source for the

FW: [sqlite] Re: A few (probably) simple questions ...-- or "Learning right from wrong."

2007-03-06 Thread Griggs, Donald
Regarding: where nothing is said about not supporting "RIGHT" UhRIGHT. Apparently, right is wrong. ;-) Though it may be corrected just by virtue of being posted on this list, anyone can submit a ticket on the documentation (or edit the wiki portion directly).

RE: [sqlite] I Need database fot some test

2007-03-07 Thread Griggs, Donald
Regarding: "... I thought SINGLE QUOTES were thé standard ?" I believe single quotes are the standard for literal strings, but double quotes for table names. - To unsubscribe, send email to [EMAIL PROTECTED]

RE: [sqlite] bug in the cmd shell

2007-03-08 Thread Griggs, Donald
Regarding: The .import cmd has a problem when it encounters binary zeros embedded in data. I should think this would be considered a bug. Hi Jim, While you can file a ticket for this, I wouldn't be shocked if it others disagreed. The command line utility requires

RE: [sqlite] DB recovery

2007-03-14 Thread Griggs, Donald
Hi, Pavan, Regarding: "In a situation where if the sqliteDB gets corrupted is there a way to recover the data ? I understand that the word *corrupted* is too generic from technical point of view. But, still would like to know if anyone has faced a situation where indirect methods are used to

RE: [sqlite] DB recovery

2007-03-14 Thread Griggs, Donald
Regarding: "In a situation where if the sqliteDB gets corrupted is there a way to recover the data ?" "...The scenrio is an embedded device with sqlite in it and user does not have direct access to the DB. So, are there any Sqlite interfaces which do the recovery job mentioned in your

RE: [sqlite] sqlite Performance

2007-03-15 Thread Griggs, Donald
Regarding: Creation of flat file takes 1.5 secs vs 3 seconds to create sqlite db. Flat file is 13 MB, sqlite db is 11 MB. "Any ideas how to get the sqlite output timings to a more respectable level would be appreciated. " I may be way off base if I'm not understanding correctly, but how can

RE: [sqlite] Search engines and the Sqlite.Org website

2007-03-16 Thread Griggs, Donald
Regarding: Does anybody know what "luggle.com" is? FWIW, I see that Luggle.com appears to be a small site run off a linux pentium by a few developers. It does contain mention of sqlite: http://luggle.com/~sean/Articles/sqlitePV.php Excerpt from page:

RE: [sqlite] Retrieve Database Metadata

2007-03-29 Thread Griggs, Donald
Hi Joel, Have you already looked at: http://www.sqlite.org/pragma.html#schema (as well as sqlite_master as mentioned earlier) -Original Message- From: Joel Cochran [mailto:[EMAIL PROTECTED] Sent: Thursday, March 29, 2007 1:55 PM To: sqlite-users@sqlite.org Subject: [sqlite]

RE: [sqlite] SQL and SQLite pronounciation?

2007-04-04 Thread Griggs, Donald
re: "S. Q. Lite... that is my pronunciation..." And calling it "squirrelite" is simply a tongue-in-cheek affectionate affectation ;-) - To unsubscribe, send email to [EMAIL PROTECTED]

RE: [sqlite] sqlite3.exe .import command

2007-04-06 Thread Griggs, Donald
Re: "...The file I am importing is comma delimited text ..." I believe the default separator is the vertical bar (virgule, "|"), but as Igor wrote, you can easily change it with: .separator , I *don't* think you can quote commas which might appear in your text. E.g. if you are importing a

RE: [sqlite] sqlite3.exe .import command

2007-04-06 Thread Griggs, Donald
Ouch! I of course meant to write "can't" instead of "can" in the (corrected) sentence below. E.g. if you are importing a list of names, you *can't* just surround the name with quote chars, such as: "John Smith, Jr.",Anytown,USA

RE: [sqlite] SQLite and nested transactions

2007-04-09 Thread Griggs, Donald
Regarding: "...As Igor pointed out this does not resemble a full implementation of transactions, as nested transactions can be committed and rolled back independently of the outer parent transaction." Nonetheless, it would seem, just from the couple of pages below, that some DB vendors find the

Re: [sqlite] network access problem

2010-05-24 Thread Griggs, Donald
I just tried -Original Message- From: sqlite-users-boun...@sqlite.org [mailto:sqlite-users-boun...@sqlite.org] On Behalf Of Black, Michael (IS) Sent: Monday, May 24, 2010 2:37 PM From: sqlite-users-boun...@sqlite.org on behalf of Art Sent: Mon

Re: [sqlite] Sqlite Insert Speed Optimization

2010-07-13 Thread Griggs, Donald
-Original Message- From: sqlite-users-boun...@sqlite.org [mailto:sqlite-users-boun...@sqlite.org] On Behalf Of John Drescher Sent: Tuesday, July 13, 2010 12:37 PM To: General Discussion of SQLite Database Subject: Re: [sqlite] Sqlite Insert Speed Optimization > I also wrap my

Re: [sqlite] Ticks to unixepoch date

2010-07-13 Thread Griggs, Donald
Hi Roberto, Re: Please find a test database in the attachment. I don't think attachments are permitted on the mailing list messages. If it's only ten rows, perhaps just using the command line utility to perform a .dump Command and pasting the text into a new message would do the trick.

Re: [sqlite] Sqlite Insert Speed Optimization

2010-07-13 Thread Griggs, Donald
Griggs, Donald wrote: > Is the percentage of the final rowcount really a criterion? The answer to that, according to my brief exploration, is somewhere between "yes" and "very much yes", depending on various factors. Thanks, Eric. I guess I was wondering if

Re: [sqlite] How to invoke successive SQLite script files

2010-07-15 Thread Griggs, Donald
Regarding: "My question is, what command do I use in script-A to invoke script-C, script-B, etc? Is it the same ".read" command? " I believe it does work that way. What did you get when you tried it? ___ sqlite-users mailing list

Re: [sqlite] Very Slow DB Access After Reboot on Windows

2010-07-22 Thread Griggs, Donald
Regarding: Also...try doing a "copy my.db nul:" to get it cached once before you use it. Am I right in thinking he may want to include the "/b" (binary) option so that the copy doesn't stop at the first nul byte? copy /b my.db nul ___

Re: [sqlite] Very Slow DB Access After Reboot on Windows

2010-07-22 Thread Griggs, Donald
Regarding win/dos COPY command and /b option: Thanks for correcting me, Michael. I somehow thought that NUL being the target would introduce some sort of "text affinity" but it's good to know the truth instead. ___ sqlite-users mailing list

Re: [sqlite] Statistics on integer primary key - Cardinality

2010-08-02 Thread Griggs, Donald
Hi Peter, Regarding: "Selectivity is known -- since it's a primary key, which is unique -- it will be 1. Cardinality can vary." I wonder if you're referring to the definition of *cardinality* as used in mathematics http://en.wikipedia.org/wiki/Cardinality In mathematics,

Re: [sqlite] Tables dropped (mac)

2008-03-21 Thread Griggs, Donald
Regarding: I created some tables at the sqlite prompt using the terminal window on a Mac. I checked with .tables and .schema and they were created and I inserted data. I closed the terminal window and went back later. At the sqlite prompt there were no tables. I tried .tables and

Re: [sqlite] Tables dropped (mac)

2008-03-21 Thread Griggs, Donald
=== Re: Maybe I left off the .db? Sqlite doesn't enforce filename restrictions -- you can name the file simply "test" if you prefer. Re: Am I right that you can only have one database file per sqlite installation? I'm not certain I understand

Re: [sqlite] Performance of bulk insertion

2008-03-24 Thread Griggs, Donald
Hi, Mahalakshmi, Regarding: "..Am I doing right or it's a lengthy process.If so suggest some other way for inserting the records?..." I must confess I have not spent much time looking at the details of your email, but you will want to be sure to use a single transaction to insert many rows in

  1   2   3   >