Re: [sqlite] Equivalent syntax?

2007-01-31 Thread P Kishor
On 1/31/07, Anderson, James H (IT) <[EMAIL PROTECTED]> wrote: What's the equivalent sqlite syntax for sybase convert function? For example, select distinct date, CDId, CDName, CDTicket, tradeId, tapsAccount, CDBook, coalesce(CDFid,'') CDFid, CDStatus, CDTradeDate, CDExpDa

Re: [sqlite] Equivalent syntax?

2007-01-31 Thread P Kishor
On 1/31/07, Anderson, James H (IT) <[EMAIL PROTECTED]> wrote: In the case shown, for example, convert(char(3), NULL) CDRefIndustry, It creates a char(3) column, sets it to null, and names it CDRefIndustry. Since SQLite has no datatypes, char(3) doesn't mean anything to it. How about

Re: [sqlite] Equivalent syntax?

2007-01-31 Thread P Kishor
On 1/31/07, Anderson, James H (IT) <[EMAIL PROTECTED]> wrote: Is cast documented on the sqlite website? I couldn't find it. .. http://www.sqlite.org/lang_expr.html -- Puneet Kishor http://punkish.eidesis.org/ Nelson Inst. for Env. Studies, UW-Madison http://www.nelson.wisc.edu/ Open Source Ge

[sqlite] glob function

2007-02-01 Thread P Kishor
"glob(X,Y) This function is used to implement the "X GLOB Y" syntax of SQLite. The sqlite3_create_function() interface can be used to override this function and thereby change the operation of the GLOB operator." Excuse my ignorance, but what exactly does glob(x, y) do? Or, what is the "X GLOB Y"

Re: [sqlite] Function question

2007-02-01 Thread P Kishor
On 2/1/07, Anderson, James H (IT) <[EMAIL PROTECTED]> wrote: On 2/1/07, Anderson, James H (IT) <[EMAIL PROTECTED]> wrote: > Does the fact that I have received no reply mean that there's no way to > get this functionality within the CLP? > > -Original Message- > From: Anderson, James H

Re: [sqlite] Function question

2007-02-01 Thread P Kishor
On 2/1/07, Anderson, James H (IT) <[EMAIL PROTECTED]> wrote: Does the fact that I have received no reply mean that there's no way to get this functionality within the CLP? -Original Message- From: Anderson, James H (IT) Sent: Thursday, February 01, 2007 9:09 AM To: sqlite-users@sqlite.or

Re: [sqlite] Passing parameters Python and CGI

2007-02-01 Thread P Kishor
On 2/1/07, Paul Issott <[EMAIL PROTECTED]> wrote: Hi, I'm a newbie using sqlite 3 via Python 2.5, I've created a db using CREATE TABLE messages ( id INTEGER PRIMARY KEY, subjectTEXT ) Populated it with a few lines and one of the row of rows is (1, u'News') after:- rows = curs.fetc

[sqlite] not allowing an empty column

2007-02-02 Thread P Kishor
how do I add a constraint to a column so neither null nor empty strings ("") are allowed? -- Puneet Kishor http://punkish.eidesis.org/ Nelson Inst. for Env. Studies, UW-Madison http://www.nelson.wisc.edu/ Open Source Geospatial Foundation http://www.osgeo.org/education/ --

Re: [sqlite] What does this mean???

2007-02-07 Thread P Kishor
On 2/7/07, Anderson, James H (IT) <[EMAIL PROTECTED]> wrote: not an error(21) at dbdimp.c line 398 I'm using DBD::SQLite and got this error. What does it mean and how best to hanle it? well, how about some context? What is the structure of the table(s) you are querying, what is the query, th

[sqlite] sqlite via jdbc on Mac OS X Tiger

2007-02-07 Thread P Kishor
volks, I need to do some prototyping, heck, maybe even final-typing, using (*shudder*) Java. Is there a jdbc driver for SQLite that works on Mac OS X? Essentially, I need to pull in the data from the database into a Java program which will then do its thang with it. -- Puneet Kishor http://punk

Re: [sqlite] What does this mean???

2007-02-07 Thread P Kishor
p find the cause of the error. Else, you can always open up dbdimp.c and look at line 398. That should set you in the right direction. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of P Kishor Sent: Wednesday, February 07, 2007 5:39 PM To: sqlite-users@sqli

Re: [sqlite] Emergency Bail Out

2007-02-09 Thread P Kishor
hmmm, I don't know what a "virtual console" is but on my computer... Lucknow:~ punkish$ sqlite3 foo.db SQLite version 3.3.8 Enter ".help" for instructions sqlite> ,e ...> ; SQL error: near ",": syntax error sqlite> .q Lucknow:~ punkish$ On 2/9/07, Rich Shepard <[EMAIL PROTECTED]> wrote: Ye

Re: [sqlite] UPDATE base on certain values

2007-02-13 Thread P Kishor
On 2/13/07, jose isaias cabrera <[EMAIL PROTECTED]> wrote: Greetings! I would like to be able to update certain columns based on their value. I was looking at "ON CONFLICT", but I could not understand it nor I could not find any examples quickly, so I say, "heck, that's what the list is for...

Re: [sqlite] UPDATE base on certain values

2007-02-13 Thread P Kishor
On 2/13/07, jose isaias cabrera <[EMAIL PROTECTED]> wrote: "P Kishor" wrote, > On 2/13/07, jose isaias cabrera <[EMAIL PROTECTED]> wrote: >> >> Greetings! >> >> I would like to be able to update certain columns based on their value. >

Re: [sqlite] Re: another

2007-02-14 Thread P Kishor
Hi Sam, On 2/14/07, Samuel R. Neff <[EMAIL PROTECTED]> wrote: Personally, I think the column names given to a result set from a SELECT by itself should be the same column names given to a table created through CREATE TABLE AS. For example, the following sql: .headers on create table a(col1 tex

Re: [sqlite] Update and insert questions

2007-02-16 Thread P Kishor
On 2/16/07, Jim Crafton <[EMAIL PROTECTED]> wrote: OK, please bear with me here, as I'm very much of an SQL newbie. I'm writing a wrapper around sqlite. I want the to code to be able to modify a given value (column) of a specific row. To do this, as I understand it, I need to use the SQL UPDATE

Re: [sqlite] Update and insert questions

2007-02-16 Thread P Kishor
I guess I wasn't clear (either that, or I am not understanding what you are doing). Let's try again (and, it doesn't matter that you are using sqlite3_bind; I am just talking workflow here). You have the following row -- Doe John 100 Nowhere Ave. 45

Re: [sqlite] Update and insert questions

2007-02-16 Thread P Kishor
On 2/16/07, Jim Crafton <[EMAIL PROTECTED]> wrote: > but it fails because the embedded WHERE clause is no longer catching > the row. It is still looking for > > WHERE LastName='Doe' AND > FirstName='John' AND > Address='100 Nowhere Ave.' AND > Age=45; > > instead of > > WHERE LastName='Doe'

Re: [sqlite] retrieval speedup help requested

2007-02-17 Thread P Kishor
On 2/17/07, Anderson, James H (IT) <[EMAIL PROTECTED]> wrote: Where does one get "analyze"? man, its pretty much a standard SQL command (at least all the dbs I've used thus far). Check out http://www.sqlite.org/lang.html. Most questions answered. -Original Message- From: RB Smissae

Re: FW: [sqlite] retrieval speedup help requested

2007-02-18 Thread P Kishor
" I would agree... it just seems a better practice to spell things out explicitly in programs, not just for the benefit for others but perhaps for one's own benefit when you come back to look at your own code 6 months later. -Original Message- From: [EMAIL PROTECTED] [mailto:[EM

Re: [sqlite] sqlite: current_time is off

2007-02-18 Thread P Kishor
On 2/18/07, Neil McLeod <[EMAIL PROTECTED]> wrote: Hello, I just started using SQLite, and it seems my timestamps are all 5 hours ahead of time (i.e. "select current_time" gives me 0:47 when it is actually 19:47 here). I guess this is GMT. Is there a way to adjust the time? I'm on Windows XP, an

Re: [sqlite] Binary data in SQLite3

2007-02-18 Thread P Kishor
On 2/19/07, jose isaias cabrera <[EMAIL PROTECTED]> wrote: Greetings! Can SQLite3 save binary data? I would like to save zip files on it. Is this possible? If so, is there a place where I can read or get some examples about it? blobs http://www.sqlite.org/datatype3.html -- Puneet Kishor

Re: [sqlite] Looking for equivalent syntax

2007-02-19 Thread P Kishor
On 2/19/07, Anderson, James H (IT) <[EMAIL PROTECTED]> wrote: I'm trying to convert the following statement in Sybase syntax into the equivalent sqlite syntax: update C1_credDerivEvent set a.CDEvent = a.CDEvent || ',' || b.CDEvent from C1_credDerivEvent a, C1_tmp_credDerivEvent b

Re: [sqlite] Looking for equivalent syntax

2007-02-19 Thread P Kishor
S tmp SET CDEvent = tmp.CDEvent -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of P Kishor Sent: Monday, February 19, 2007 1:56 PM To: sqlite-users@sqlite.org Subject: Re: [sqlite] Looking for equivalent syntax On 2/19/07, Anderson, James H (IT) <[EMAIL

Re: [sqlite] query on match between application and sqlite

2007-02-19 Thread P Kishor
On 2/19/07, Eric S. Johansson <[EMAIL PROTECTED]> wrote: Joe Wilson wrote: >> 2) can I use it for a message store and have it run faster than a 1 >> message per file system? > > What does that mean? Is "file system" a unit of time? ack! bad sentence construction... comparing a system storing 1

Re: [sqlite] deleting a single row

2007-02-19 Thread P Kishor
On 2/19/07, Jim Crafton <[EMAIL PROTECTED]> wrote: If I have a simple table without an index column, and have multiple rows with the same data, is it possible to *only* delete one row? In other words, is there anything like the LIMIT syntax that's found in the SELECT command for DELETEs? you

Re: [sqlite] deleting a single row

2007-02-19 Thread P Kishor
On 2/20/07, P Kishor <[EMAIL PROTECTED]> wrote: On 2/19/07, Jim Crafton <[EMAIL PROTECTED]> wrote: > If I have a simple table without an index column, and have multiple > rows with the same data, is it possible to *only* delete one row? In > other words, is there anything

Re: [sqlite] Precision of dates stores as Julian "real"

2007-02-21 Thread P Kishor
On 2/21/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: Dennis Cote <[EMAIL PROTECTED]> wrote: > > The problem is that you can't use a function like strftime as the > default value for a column when you create a tbale. It only accepts > NULL, a string constant, a number, or one of the magic curr

Re: [sqlite] Precision of dates stores as Julian "real"

2007-02-21 Thread P Kishor
On 2/21/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: "P Kishor" <[EMAIL PROTECTED]> wrote: > > is it possible to add usage such as the above, and many, many > wonderful SQL suggestions routinely provided by Igor Tandetnik (thanks > Igor!) to the syntax

Re: [sqlite] Effect of blobs on performance

2007-02-21 Thread P Kishor
On 2/21/07, Brett Keating <[EMAIL PROTECTED]> wrote: Hi, I'm curious about what the effect of having a blob in the database may be on performance. I have two design options: 1) put a small image file (15-30kbyte) into the database as a blob, and 2) store the image in a separate file on disk and

Re: [sqlite] Effect of blobs on performance

2007-02-22 Thread P Kishor
see below for a counter perspective On 2/22/07, John Stanton <[EMAIL PROTECTED]> wrote: Thomas Fjellstrom wrote: > On February 21, 2007, [EMAIL PROTECTED] wrote: > >>"Brett Keating" <[EMAIL PROTECTED]> wrote: >> >>>Hi, >>> >>>I'm curious about what the effect of having a blob in the database may

[sqlite] db design options

2007-02-23 Thread P Kishor
I want to store quite a bit of data about similar but different things... in this case, timestamped discharge and precipitation values from different sites. A simple schema would be CREATE TABLE sites ( site_id INTEGER PRIMARY KEY, lon REAL, lat REAL, site_nam

Re: [sqlite] db design options

2007-02-23 Thread P Kishor
On 2/23/07, Rich Shepard <[EMAIL PROTECTED]> wrote: On Fri, 23 Feb 2007, P Kishor wrote: .. > all is fine with this. However, there really is no relationship > between one site and another. You don't tell us the purpose of this exercise, but you might want to query f

Re: [sqlite] db design options

2007-02-23 Thread P Kishor
On 2/23/07, Dennis Cote <[EMAIL PROTECTED]> wrote: P Kishor wrote: > > > Most of the time I am looking at one site, so there is a speed gain by > not plowing through other sites' data. This is what is causing me to > pause before I rush forward. > If you have an i

Re: [sqlite] Sqlite3 in MAC Os

2007-02-26 Thread P Kishor
On 2/26/07, Kirrthana M <[EMAIL PROTECTED]> wrote: Hi everybody, Im developing an application using sqlite3 in MAC OS,I just wanted to know wheather sqlite3 can be used in MAC OS. yes. You can use coredata capabilities built into Tiger (but that will give you an older version of SQLite comp

Re: [sqlite] Re: Re: How to change or add fields to a table ?

2007-02-27 Thread P Kishor
On 2/27/07, Stef Mientki <[EMAIL PROTECTED]> wrote: > >> On the other hand I fear that I can only change the name of the Table. >> If the later is true, why isn't possible to change the name of a >> column (shouldn't be difficult to implement) ? > > Please feel free to submit a patch. Thank you,

Re: [sqlite] Insert

2007-02-28 Thread P Kishor
On 2/28/07, Christian POMPIER <[EMAIL PROTECTED]> wrote: Could i make to insert 10 000 row in my table with a loop ? Christian, This kind of a question is likely to either not result in an answer, or in an answer that is unsatisfactory to you -- either way, bandwidth wasted. Ask better quest

Re: [sqlite] Installing & Running Sqlite on Linux Webserver?

2007-02-28 Thread P Kishor
On 2/28/07, Tom VP <[EMAIL PROTECTED]> wrote: I would like to install and run sqlite on my host web server. Does anyone know how I can do this? I downloaded: sqlite-2.8.17.bin.gz and gunzipped it to: sqlite-2.8.17.bin. Is this what I would install and how. My website is on a shared server, so is

Re: [sqlite] Installing & Running Sqlite on Linux Webserver?

2007-02-28 Thread P Kishor
/download.html> Also, ask your web server company... in all likelihood they already have sqlite compiled and sitting under /usr/local/bin for you to use. - Original Message - From: "P Kishor" <[EMAIL PROTECTED]> To: Sent: Wednesday, February 28, 2007 10:37 AM Subj

[sqlite] OT: suitable web host (was Re: [sqlite] Installing & Running Sqlite on Linux Webserver?)

2007-02-28 Thread P Kishor
On 2/28/07, Tom VP <[EMAIL PROTECTED]> wrote: Thank you, John. The problem with shared servers is the real and extensive restrictions on running apps and scripts - I'm considering hosting my own web server. I am happy with Dreamhost. For $8 a month, I get more space and bandwidth than I can use

Re: [sqlite] Newbie question about LIKE and ESCAPE

2007-03-03 Thread P Kishor
On 3/3/07, A.J.Millan <[EMAIL PROTECTED]> wrote: Hi all: I need a simple search, say: SELECT someField IN someTable WHERE name LIKE '%xyzetc%'; This is standard SQL syntax, and works just fine in SQLite. It will match all rows where someField contains the string 'xyzetc' You can also anchor

Re: [sqlite] import operation - primary key need to be automatically generated by SQLite (not from csv file)

2007-03-07 Thread P Kishor
On 3/6/07, RohitPatel <[EMAIL PROTECTED]> wrote: /* SQLite 3.3.8 (Windows) used */ /* table t1 */ /* only two columns are given because other columns are irrelevant here */ create table t1 (id INTEGER PRIMARY KEY, name TEXT); /* few sample records from csv file data.csv */ 1,'name_text_1'

Re: [sqlite] table Attachments already exists at dbdimp.c line 271

2007-03-08 Thread P Kishor
On 3/8/07, Mariusz Stakowski <[EMAIL PROTECTED]> wrote: Hello list, I am totally new to SQLite. I try to use it with RT (Request Tracker). I tried to initialize dabase. The first try failed but it was not SQLite problem. I have corrected the error

Re: [sqlite] Case Insensitive Equality Searches

2007-03-08 Thread P Kishor
On 3/8/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: If I want to do "SELECT * FROM table WHERE field = value", how can I do this matching text only and not case? you can do it in your application using the language of your choice by upcasing or downcasing your field and value. Here is a

Re: [sqlite] Case Insensitive Equality Searches

2007-03-08 Thread P Kishor
On 3/8/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: [EMAIL PROTECTED] wrote: > If I want to do "SELECT * FROM table WHERE field = value", > how can I do this matching text only and not case? > SELECT * FROM table WHERE field COLLATE nocase = value; ahhh, I didn't know this could be

Re: [sqlite] Is there an inverse for .import?

2007-03-09 Thread P Kishor
On 3/9/07, Anderson, James H (IT) <[EMAIL PROTECTED]> wrote: I need to "export" a table to a file in the same format as used by .import, but I don't see any such cmd. Am I missing something, or does such a cmd just not exist? .dump -- Puneet Kishor http://punkish.eidesis.org/ Nelson Inst. fo

Re: [sqlite] sin and similar functions

2007-03-09 Thread P Kishor
Jakub, The documentation for creating user-defined functions is at . See section 2.3. Unfortunately, I don't know the A,B of C, so I can't guide you in this. On the other hand, if you are using Perl, I can write you a step-by-step process for creating your own fu

Re: Fwd: [sqlite] database is locked error on Mac OS X

2007-03-10 Thread P Kishor
On 3/10/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: T&B <[EMAIL PROTECTED]> wrote: > Can someone please tell me (politely ;-) where to put the - > DSQLITE_ENABLE_LOCKING_STYLE=1 > > I tried inserting it arbitrarily in the Makefile.in file but it > didn't seem to make a difference. > Do "con

Re: [sqlite] UPDATE colomns based on their values

2007-03-11 Thread P Kishor
On 3/12/07, jose isaias cabrera <[EMAIL PROTECTED]> wrote: Ok, I have figured out that I do not have null values on the data of my table, even though I do have empty strings. Here is my schema, sqlite> sqlite> .schema CREATE TABLE LSOpenJobs ( id integer primary key, ProjID in

Re: [sqlite] UPDATE colomns based on their values

2007-03-12 Thread P Kishor
On 3/12/07, jose isaias cabrera <[EMAIL PROTECTED]> wrote: "P Kishor" wrote, > On 3/12/07, jose isaias cabrera <[EMAIL PROTECTED]> wrote: >> >> Ok, I have figured out that I do not have null values on the data of my >> table, even though

Re: [sqlite] SQlite 2.8.16 -> SQLite 3

2007-03-12 Thread P Kishor
On 3/12/07, Mitchell Vincent <[EMAIL PROTECTED]> wrote: I'm converting a bunch of databases from SQLite 2.8.16 to SQLite 3.3.13 and am seeing something pretty amazing space saving. So good that it might be too good to be true! For example, a 17 meg database is cut down to 7 megs. That's fantasti

Re: [sqlite] Degrouping, desummarizing or integrating headings

2007-03-13 Thread P Kishor
On 3/13/07, T&B <[EMAIL PROTECTED]> wrote: Hi All, I come across a fair bit of source data in summary format, where the one field's values are used as a heading for a group of records for which it applies. For instance, this shopping list: Aisle Product Cost Dairy Milk

Re: [sqlite] SQLite samples or templates, including PHP

2007-03-15 Thread P Kishor
On 3/15/07, T&B <[EMAIL PROTECTED]> wrote: Hi All, Following in a similar thread to Shilpa's request: > Are there database schema's (eg. for Phonebook ) available on the > net? Are there any templates out there for SQLite databases? In particular, I'm after SQLite and PHP integrated solutions

Re: [sqlite] Adding columns of records and updating the result to a record

2007-03-15 Thread P Kishor
José, As Igor rightly points out, you are doing the "wrong" thing with this tool. A perfect database program, and SQLite approaches that in its simplicity, acts as simply an ultra-efficient device to store and retrieve your data. Everything else is up to you... like a perfect audio speaker that n

Re: [sqlite] Adding columns of records and updating the result to a record

2007-03-15 Thread P Kishor
On 3/15/07, jose isaias cabrera <[EMAIL PROTECTED]> wrote: "P Kishor" wrote, .. > Any basic tutorial in normalization and table design > will help you tremendously in figuring an efficient solution to your > problem. Any suggestions on the web? http://www.google.c

Re: [sqlite] Saving binary files

2007-03-17 Thread P Kishor
as far as we all know, it can be done, in that, yes, blobs can be stored in SQLite. As you yourself have realized, and as the creator of SQLite has confirmed, SQLite is not the right tool for that. That said, why don't you just do it and see what problem you encounter. That itself might be valid

Re: [sqlite] Strange performance behavior

2007-03-19 Thread P Kishor
On 3/19/07, Hubertus <[EMAIL PROTECTED]> wrote: Dear list, sorry to just come up with another performance question. I build a yet small database with one table. It has about 650.000 rows, 75 columns and has at the moment about 650 Mb. It runs on a Intel Pentium M with 2 GHz. The Laptop runs Suse

Re: [sqlite] Index creation on huge table will never finish.

2007-03-21 Thread P Kishor
On 3/21/07, Chris Jones <[EMAIL PROTECTED]> wrote: Hi all, I have a very simple schema. I need to assign a unique identifier to a large collection of strings, each at most 80-bytes, although typically shorter. The problem is I have 112 million of them. My schema looks as follows: CREATE TAB

Re: [sqlite] Index creation on huge table will never finish.

2007-03-21 Thread P Kishor
You stated in your OP I need to assign a unique identifier to a large collection of strings Obviously I misunderstood that to mean you wanted the strings tagged uniquely, not that the strings were unique. In your case, it seems then, you will have to put up with checking each string, and as th

Re: [sqlite] Index creation on huge table will never finish.

2007-03-22 Thread P Kishor
Richard, On 3/22/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: .. The problem is that your working set is bigger than your cache which is causing thrashing. I suggest a solution like this: Add entries to table ONE until the table and its unique index get so big that they no longer fit in ca

Re: [sqlite] Index creation on huge table will never finish.

2007-03-22 Thread P Kishor
On 3/22/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: "P Kishor" <[EMAIL PROTECTED]> wrote: > Richard, > > On 3/22/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > ... > > The problem is that your working set is bigger than your cache > &g

Re: [sqlite] Index creation on huge table will never finish.

2007-03-22 Thread P Kishor
On 3/22/07, Martin Jenkins <[EMAIL PROTECTED]> wrote: Chris Jones wrote: > realized that the unix "sort" If I'd known you were on 'nix I'd have suggested using 'sort' and/or 'md5sum' about 12 hours ago. ;) Mac/Unix person meself, but the Windows XP sort is pretty darn good as well. -- Pune

Re: [sqlite] INSERT or REPLACE

2007-03-22 Thread P Kishor
Oracle has MERGE. Search for UPSERT and SQL Server. On 3/22/07, Doug <[EMAIL PROTECTED]> wrote: The conflict algorithms in SQLite are brilliant. It's exactly what I've needed, and after working with SQLite for so long, I had forgotten that it wasn't part of the SQL standard (as far as I know--b

Re: [sqlite] Store and retreive 0D0A (CRLF) in string field

2007-03-26 Thread P Kishor
On 3/25/07, fangles <[EMAIL PROTECTED]> wrote: SQLite doesn't truncate anything. Whatever you put in you get out. If you see a truncation, it is either done by whatever wrapper you use on top of SQLite, or simply an artifact of the way you inspect the data (e.g. you look at the string in a debug

Re: [sqlite] How does SQLite store data?

2007-03-26 Thread P Kishor
On 3/26/07, Dennis Cote <[EMAIL PROTECTED]> wrote: John Stanton wrote: > It does not have fixed length columns except for the ones which hold > integer and real numbers and boolean values. > Actually, integers are stored in a variable length format as well. It takes less space to store smaller in

Re: [sqlite] Issue with trailing blanks

2007-03-26 Thread P Kishor
On 3/26/07, Joel Cochran <[EMAIL PROTECTED]> wrote: Howdy all, I am new to SQLite, so I hope this isn't too much of a newbie question, but I searched the Internet, the archives, and the help docs and could not find any mention of this. I am populating an SQLite database from a legacy IBM AS/400

Re: [sqlite] matching only part of a string

2007-03-28 Thread P Kishor
On 3/28/07, Lloyd K L <[EMAIL PROTECTED]> wrote: Hi, My table contains a text field called Name. Let the data be Name --- Abc abcd AB cab def I want to selcct all the rows which contains the term ab (not case sensitive). How can I do this? SELECT name FROM table WHERE Lower(name) LIKE

Re: [sqlite] Use of bind variable in sqlite

2007-03-28 Thread P Kishor
On 3/28/07, Amarjeet Kumar (RBIN/ECM4) <[EMAIL PROTECTED]> wrote: Hi, Can we use the bind variable in sqlite query, if so how? this is a basic question that has been answered many times. Search the list archives for details, but the general idea is -- prepare your statement with placeholders

Re: [sqlite] what's the fastest way to get the record count of a table?

2007-03-28 Thread P Kishor
On 3/28/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: Hi, I want to check the record count of a table every 5 seconds. It seems there's only one way to get a table's record count: select coun(*) from ATable but if the table gets big(1,000,000 rows), it will get slow. Any good idea? create a

Re: [sqlite] RE: Maintaining Master-Child relationships

2007-03-28 Thread P Kishor
On 3/28/07, Arora, Ajay <[EMAIL PROTECTED]> wrote: Can anyone please look into my query, I've tables Master ( id integer primary key, field1 text) And Child (id integer, name text) My application receive values for field1 and name. I need to populate master and child with incoming

Re: [sqlite] RE: Maintaining Master-Child relationships

2007-03-29 Thread P Kishor
may also fail eval { $dbh->rollback }; # add other application on-error-clean-up code here } -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of P Kishor Sent: 28 March 2007 17:42 To: sqlite-users@sqlite.org Subject: Re: [sqlite] RE: Maintaining Master-Child rela

Re: [sqlite] Using the Sqlite Btree Backend directly

2007-03-29 Thread P Kishor
On 3/29/07, Ludvig Strigeus <[EMAIL PROTECTED]> wrote: Hi, I'm looking at using Sqlite as a storage backend for a program. Using SQL is a little bit overkill and much more than we need. How complicated would it be to interface to the btree subsystem directly? Sqlite seems very modular from the l

Re: [sqlite] Retrieve Database Metadata

2007-03-29 Thread P Kishor
On 3/29/07, Joel Cochran <[EMAIL PROTECTED]> wrote: Hi all, Is there a way (through SQL) to retrieve metadata about an SQLite database? Specifically I would like to find lists of tables, indexes, views, and table schema. http://www.sqlite.org/faq.html#q9 -- Puneet Kishor http://punkish.eid

Re: [sqlite] Changing column data type

2007-03-30 Thread P Kishor
add "col4 text" and UPDATE foo SET col4 = col2 keep in mind, other than a few limitations, SQLite doesn't really give a rip about your data types and what you store in it. It is about as free-for-all as it gets. On 3/30/07, Sandeep Suresh <[EMAIL PROTECTED]> wrote: I have a table : Table foo

Re: [sqlite] sqlite and generate dynamic html

2007-04-03 Thread P Kishor
On 4/3/07, Vivek Rajan <[EMAIL PROTECTED]> wrote: Hello SQLite Community- For a personal project, I need to dynamically create HTML pages from an on-disk SQLite database. I don't need cross-network capability, I just need the ability to query and dynamically generate HTML from an on-disk SQLite

Re: [sqlite] Data integrity in extreme situations

2007-04-04 Thread P Kishor
On 4/4/07, Yves Goergen <[EMAIL PROTECTED]> wrote: Hi, I'm intending to use the SQLite database in a desktop e-mail application. Since most e-mails are quite valuable to me, I'd like to know if SQLite databases can get corrupted during normal use and exceptional situations like a sudden applicat

Re: [sqlite] SQL and SQLite pronounciation?

2007-04-04 Thread P Kishor
On 4/4/07, Dennis Cote <[EMAIL PROTECTED]> wrote: Hi All, I have a simple question; how do you pronounce SQL and SQLite? See-quell See-que-lite -- Puneet Kishor http://punkish.eidesis.org/ Nelson Inst. for Env. Studies, UW-Madison http://www.nelson.wisc.edu/ Open Source Geospatial Foundat

Re: [sqlite] SQL and SQLite pronounciation?

2007-04-05 Thread P Kishor
On 4/5/07, Dennis Cote <[EMAIL PROTECTED]> wrote: Martin Pelletier wrote: > > Hearing "sequel" for SQL always makes me cringe. > Me too! That is what prompted my original message. I just wanted to see if I was perhaps the only one who was bothered by that pronunciation. Thanks for the confirmati

[sqlite] storing funky text in TEXT field

2007-04-05 Thread P Kishor
Seems like a basic question, but I can't figure out a definitive answer to this. I want to store UTF-8 characters in a TEXT field, y'know, things like umlauts and accents and that Norwegian slashed-O thingy, perhaps even South Asian Devnagari. The documentation says about text -- "TEXT. The value

Re: [sqlite] SQL and SQLite pronounciation?

2007-04-05 Thread P Kishor
On 4/5/07, Dan Baker <[EMAIL PROTECTED]> wrote: - Original Message - From: "Dennis Cote" <[EMAIL PROTECTED]> To: "sqlite-users" Sent: Wednesday, April 04, 2007 2:24 PM Subject: [sqlite] SQL and SQLite pronounciation? > Hi All, > > I have a simple question; how do you pronounce SQL and

Re: [sqlite] storing funky text in TEXT field

2007-04-05 Thread P Kishor
UTF-16, or one of the 16 variants, BE/LE? - Original Message From: P Kishor <[EMAIL PROTECTED]> To: sqlite-users@sqlite.org Sent: Thursday, April 5, 2007 7:39:33 AM Subject: [sqlite] storing funky text in TEXT field Seems like a basic question, but I can't figure out a definitive answer

Re: [sqlite] storing funky text in TEXT field

2007-04-05 Thread P Kishor
On 4/5/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: "P Kishor" <[EMAIL PROTECTED]> wrote: > > But, the line I quoted in my OP, namely "TEXT. The value is a text > string, stored using the database encoding (UTF-8, UTF-16BE or > UTF-16-LE)." is c

Re: [sqlite] Some questions on hierarchical data (nested set model)

2007-04-06 Thread P Kishor
I am very interested in hearing on this as well. A recommendation has been Joe Celko's book "Trees and Hierarchies in SQL for Smarties" (.

Re: [sqlite] Data structure

2007-04-11 Thread P Kishor
On 4/11/07, Lloyd <[EMAIL PROTECTED]> wrote: Hi, I don't know whether this is an irrelevant question in SQLite list, but I don't see a better place to ask. Which data structure is best to store and retrieve data very fastly? There is a 95% chance that the searched data to be present in the data

Re: [sqlite] Data structure

2007-04-11 Thread P Kishor
On 4/11/07, Martin Jenkins <[EMAIL PROTECTED]> wrote: Lloyd wrote: > hi Puneet and Martin, > On Wed, 2007-04-11 at 14:27 +0100, Martin Jenkins wrote: >> File system cache and plenty of RAM? >> > > It is meant to run on an end user system (eg. Pentium 4 1GB RAM). If you > mean Swap space as file s

Re: [sqlite] SQLite join-mechanisms question

2007-04-12 Thread P Kishor
On 4/12/07, Cesar Rodas <[EMAIL PROTECTED]> wrote: Hello. I have a question about SQLite join-mechanisms. Let me explain with an example. I have the follow table. CREATE TABLE a( word_id INTEGER, doc_id INTEGER ); CREATE INDEX "a_index1" ON "a"( "doc_id" ASC ); CREATE INDEX "a_index" O

Re: [sqlite] Journal files not deleted.

2007-04-12 Thread P Kishor
Guilty of extending this silly thread... On 4/12/07, Noah Hart <[EMAIL PROTECTED]> wrote: Not to quibble, but to quote from wipro's website "Only Indian company to be ranked among the top 10 global outsourcing providers in IAOP's 2006 Global Outsourcing 100 listing" you are indeed quibbling

Re: [sqlite] Sqlite3 stable version

2007-04-13 Thread P Kishor
On 4/13/07, Hamid Benhocine <[EMAIL PROTECTED]> wrote: Dear drh, We do want install the latest version of sqlite.for the production ( 2007-Apr-09 - Version 3.3.15 ) But, Our sytem group, found the only flaged stable version of the sqlite3 in the web site is this one ( 2006-Jan-31 - Version 3.3.

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

2007-04-22 Thread P Kishor
Your question is so confusing that I am going to assume there is something you have not been able to express in the asking of it -- On 4/22/07, Gilles Roy <[EMAIL PROTECTED]> wrote: Given a arbitrary statement, I need to find out which row a specific result is in, as efficiently as possible. The

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

2007-04-22 Thread P Kishor
On 4/22/07, Gilles Roy <[EMAIL PROTECTED]> wrote: On Sun, Apr 22, 2007 at 05:33:43PM -0500, P Kishor wrote: >On 4/22/07, Gilles Roy <[EMAIL PROTECTED]> wrote: >>Given a arbitrary statement, I need to find out which row a specific >>result is in, as efficiently

Re: [sqlite] An explanation?

2007-04-23 Thread P Kishor
On 4/23/07, Marco Bambini <[EMAIL PROTECTED]> wrote: As a performance test I created a db with 300,000 records, table is: CREATE TABLE table1 (a INTEGER, b INTEGER) a query like: SELECT * FROM table1 WHERE a=5 AND b=11; takes 0.281 secs. if I add two indexes: CREATE INDEX index1 ON table1(a);

Re: [sqlite] License Queries

2007-04-26 Thread P Kishor
you don't have to do anything. SQLite is in public domain. You can cook with it, make castles with it, become a billionaire (although, if you do, remember to give some money to your favorite open source project), or roll pancakes with it. If you make and modifications to SQLite AND if you want th

Re: [sqlite] License Queries

2007-04-26 Thread P Kishor
alright. Let's do it again (DRH can chime in to educate us if I get it wrong) -- On 4/26/07, Pavan <[EMAIL PROTECTED]> wrote: Hi Kishor, >you don't have to do anything. Thanks for the quick reply. I did not quite understand to which part of the question this reply belongs. .. .. > > On 4/26

Re: [sqlite] Need Help with SQL Statement

2007-04-30 Thread P Kishor
see the LIMIT option On 4/30/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: I have a file with the columns: StockSymbol, OptionSymbol, StockPrice, StrikePrice, ExpiryDate For each StockSymbol, ExpiryDate, I would like to list just 4 of the records where the StrikePrice is lower than the Sto

Re: [sqlite] SQL query help (mutiple joins)

2007-05-01 Thread P Kishor
On 5/1/07, Allan, Mark <[EMAIL PROTECTED]> wrote: Hi, Thanks for your quick replies. I have tried this method but however I am getting a row returned for each entry in ForcedSpiroTable or RelaxedSpiroTable that matches the search criteria. i.e. If a single patient say "Joe Bloggs" has 5 tests

Re: [sqlite] SQL query help (mutiple joins)

2007-05-01 Thread P Kishor
actually SELECT COUNT(DISTINCT ... On 5/1/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: It will be as the below query, but replace: distinct p.* with: count(p.ID) RBS >> Allan, Mark wrote: >> > What I want is Joe Blogs just the once. >> > >> > >> Mark, >> >> Then try adding distinct like t

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

2007-05-02 Thread P Kishor
On 5/2/07, Tito Ciuro <[EMAIL PROTECTED]> wrote: Hello, Assume the following scenario: I store people in a table, like this: People ROWID, idx GUID, idx First, idx Last, idx Email ... In the app, the user can select People GUIDs from different so

Re: [sqlite] Transaction journal corrupted by antivirus

2007-05-03 Thread P Kishor
You are in a sticky situation. Read below -- On 5/3/07, Voxen <[EMAIL PROTECTED]> wrote: Hi, My application is storing email messages in a SQLite database (raw email messages as they are downloaded from the mail server). This is done under a transaction. Sometimes I get the SQLITE_MISUSE error

[sqlite] DBD::SQLite with FTS

2007-05-10 Thread P Kishor
has anyone created a DBD::SQLite with the full-text search option turned on? else, are there any guidelines on how to hook a new SQLite lib with the DBD package since the CPAN version seems to be running a few versions late. -- Puneet Kishor http://punkish.eidesis.org/ Nelson Inst. for Env. Studi

Re: [sqlite] Unsupported file format

2007-05-11 Thread P Kishor
On 5/11/07, Alberto Simões <[EMAIL PROTECTED]> wrote: Hi, I am using a Mac, and probably doing something weird with fink software and (probably) other installations. The fact is that I create a database using DBD::SQLite, and then: [EMAIL PROTECTED] ProjectoDicionario]$ sqlite3 dic.db SQLit

  1   2   3   4   5   6   7   8   9   10   >