Re: [sqlite] How to get column description from table using SQL

2006-06-27 Thread C.Peachment
On Wed, 28 Jun 2006 10:29:47 +0600, blins wrote: > How to get column description from table using SQL To get table definition for '': select sql from sqlite_master where type='table' and name='';

[sqlite] How to get column description from table using SQL

2006-06-27 Thread blins
Hi sqlite-users@sqlite.org, How to get column description from table using SQL -- А у нас как не было порядка, так и есть! С наилучшими пожеланиями, blins mailto:[EMAIL PROTECTED]

Re: [sqlite] sqlite too slow for me?

2006-06-27 Thread Cesar David Rodas Maldonado
I dont know a lot about MySQL... but mysql is not so faster as you think... I have in my computer the mysql 5 is good, but sqlite is so faster too!!! but MySQL has a query cache so i think the cache make it seems more faster than sqlite... On 6/27/06, Péter Szabó <[EMAIL PROTECTED]>

Re: [sqlite] sqlite too slow for me?

2006-06-27 Thread Péter Szabó
First, thank you all for the answers. UNIQUE(col1, col4, col5, col2), Adding this would surely make the query run faster -- provided that SQLite chooses the right index. But I also use the UNIQUE(col1, col4, col5) constraint to ensure the uniqueness of these three columns. So instead I

[sqlite] update or insert.

2006-06-27 Thread Mario . Hebert
My brain does not seem to be able to function properly today. I can think of many ways to do what I want to do but none of them I like. I will describe the problem in the most symplistic form. I have two tables. The first table, has a row which includes an 'id' pointing to a row of another

Re: [sqlite] Multibyte

2006-06-27 Thread Roberto
I am confused what are you trying to acheive by building a Unicode DLL? On 27/06/06, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: Hi to all I have created my own 2 SQLite-DLL's, one as a Unicode-DLL and the other one as Multibyte-DLL. If I create a Test-App with Unicode selected and

[sqlite] unsubscribing from sqlite

2006-06-27 Thread Darren Duncan
At 5:53 PM + 6/27/06, prabhu kumaravelu wrote: i want to unsubscribe. I have been email from sqlite and fill up my inbox please unsubcribe this The instructions to get yourself off are in the header of every email: List-Post: List-Help:

Re: [sqlite] Database design questions

2006-06-27 Thread prabhu kumaravelu
i want to unsubscribe. I have been email from sqlite and fill up my inbox please unsubcribe this From: Darren Duncan <[EMAIL PROTECTED]> Reply-To: sqlite-users@sqlite.org To: sqlite-users@sqlite.org Subject: Re: [sqlite] Database design questions Date: Tue, 27 Jun 2006 10:33:03 -0700 At

[sqlite] Re: ORDER BY clause with column values not case-sensitive

2006-06-27 Thread Igor Tandetnik
Dennis Cote <[EMAIL PROTECTED]> wrote: Srikanth wrote: Is there a way to order the results of a select statement using the values of a column name, with the values in that column insensitive? Add COLLATE NOCASE to the column definition of the country column in your table. ... or directly in

Re: [sqlite] Database design questions

2006-06-27 Thread Brian Johnson
Bud Beacham ([EMAIL PROTECTED]) wrote: > > If I offer an upgrade version with new tables how difficult will > it be for the user to merge their database into the latest > version? I will insure that any customer table names will not > conflict with my table names. > > Would it make more sense to

[sqlite] Database design questions

2006-06-27 Thread Bud Beacham
I am using SQLite to add a database engine to a product I hope to sell. One thing that is desirable is to allow the customers to enhance the database for their specific needs. For example, they could add new tables to reflect their environment, and then design queries that look at both the

[sqlite] Icon for sqlite?

2006-06-27 Thread Edwin Knoppert
My tool needs an sqlite icon, is there one? I see a logo only. :)

Re: [sqlite] ORDER BY clause with column values not case-sensitive

2006-06-27 Thread Srikanth
Dennis, It works. Thanks a lot. Srikanth. On 6/27/06, Dennis Cote <[EMAIL PROTECTED]> wrote: Srikanth wrote: > Is there a way to order the results of a select statement using the > values of a column name, with the values in that column insensitive? > E.g., If the column has the following

Re: [sqlite] v3.2.1 and current differences!

2006-06-27 Thread Edwin Knoppert
Question remains if it isn't better to go to a new major version on such changes. Forward compatibility is assumed by users imo. - Original Message - From: <[EMAIL PROTECTED]> To: Sent: Tuesday, June 27, 2006 1:08 PM Subject: Re: [sqlite] v3.2.1 and current

Re: [sqlite] ORDER BY clause with column values not case-sensitive

2006-06-27 Thread Dennis Cote
Srikanth wrote: Is there a way to order the results of a select statement using the values of a column name, with the values in that column insensitive? E.g., If the column has the following values: Zambia, italy,Iceland, then a regular "ORDER BY tablename.country DESC" would result in: italy

Re: [sqlite] Huge performance difference between SQLite on Windows XP and Windows 2000

2006-06-27 Thread Christian Smith
Lukáš Neumann uttered: Hello, I am using SQLite DLL version 3.2.1 to access a single file database. I use sqlite3_exec() to call this simple query: BEGIN; INSERT INTO Messages (IDMessage, Body) VALUES (1054, 'Test'); COMMIT; When the application runs under Windows XP, the query takes

[sqlite] ORDER BY clause with column values not case-sensitive

2006-06-27 Thread Srikanth
Hi, Is there a way to order the results of a select statement using the values of a column name, with the values in that column insensitive? E.g., If the column has the following values: Zambia, italy,Iceland, then a regular "ORDER BY tablename.country DESC" would result in: italy Zambia Iceland

Re: [sqlite] use of index in ORDER BY clause

2006-06-27 Thread Dennis Cote
Jens Miltner wrote: I have a schema similar to this: CREATE TABLE foo (id integer primary key, name text); CREATE TABLE bar (id integer primary key, foo_id integer, something text); CREATE INDEX bar_idx on bar(foo_id, something); When I run a query like SELECT foo.id AS foo_id,

Re: [sqlite] use of index in ORDER BY clause

2006-06-27 Thread Jay Sprenkle
On 6/27/06, Jens Miltner <[EMAIL PROTECTED]> wrote: When I run a query like SELECT foo.id AS foo_id, bar.id AS bar_id FROM bar LEFT JOIN foo ON foo.id=bar.foo_id ORDER BY bar.something I think it's using the join first to determine what goes in the

Re: [sqlite] sqlite3_free()

2006-06-27 Thread Christian Smith
Andrew Piskorski uttered: On Tue, Jun 27, 2006 at 04:14:37PM +0100, Christian Smith wrote: Anyway, it's not difficult to provide thread local storage. HP-UX's netdb.h functions (gethostbyname etc.) are fully re-entrant despite returning 'static' data, for example. Other UNIXs got hamstrung

[sqlite] use of index in ORDER BY clause

2006-06-27 Thread Jens Miltner
I have a schema similar to this: CREATE TABLE foo (id integer primary key, name text); CREATE TABLE bar (id integer primary key, foo_id integer, something text); CREATE INDEX bar_idx on bar(foo_id, something); When I run a query like SELECT foo.id AS foo_id, bar.id AS

Re: [sqlite] sqlite3_free()

2006-06-27 Thread Andrew Piskorski
On Tue, Jun 27, 2006 at 04:14:37PM +0100, Christian Smith wrote: > Anyway, it's not difficult to provide thread local storage. HP-UX's > netdb.h functions (gethostbyname etc.) are fully re-entrant despite > returning 'static' data, for example. Other UNIXs got hamstrung with > various

Re: [sqlite] sqlite3_free()

2006-06-27 Thread Christian Smith
Dennis Cote uttered: Christian Smith wrote: Yes, of course, Windows sticks it's oar in again. Going back to the previous DLL discussion, this alone is surely confirmation of why the Windows DLL system sucks. This really has nothing to do with the Windows DLL system. It is simply the case

[sqlite] Huge performance difference between SQLite on Windows XP and Windows 2000

2006-06-27 Thread Lukáš Neumann
Hello, I am using SQLite DLL version 3.2.1 to access a single file database. I use sqlite3_exec() to call this simple query: BEGIN; INSERT INTO Messages (IDMessage, Body) VALUES (1054, 'Test'); COMMIT; When the application runs under Windows XP, the query takes unnoticable amout of time

Re: [sqlite] subtracting days from two dates

2006-06-27 Thread Dennis Cote
mithin wrote: Hi, I want to find if the difference between the days of two dates is less than or greater than some number. The year is not in the picture and it can be anything. I gave the following query but it is not working. SELECT * FROM date_details WHERE (date(date_details.value,%j) -

Re: [sqlite] sqlite3_free()

2006-06-27 Thread Dennis Cote
Christian Smith wrote: Yes, of course, Windows sticks it's oar in again. Going back to the previous DLL discussion, this alone is surely confirmation of why the Windows DLL system sucks. This really has nothing to do with the Windows DLL system. It is simply the case that the main

Re: [sqlite] subtracting days from two dates

2006-06-27 Thread Jay Sprenkle
On 6/27/06, mithin <[EMAIL PROTECTED]> wrote: Hi, I want to find if the difference between the days of two dates is less than or greater than some number. The year is not in the picture and it can be anything. I gave the following query but it is not working. SELECT * FROM date_details WHERE

[sqlite] subtracting days from two dates

2006-06-27 Thread mithin
Hi, I want to find if the difference between the days of two dates is less than or greater than some number. The year is not in the picture and it can be anything. I gave the following query but it is not working. SELECT * FROM date_details WHERE (date(date_details.value,%j) - date('now',%j) <

Re: [sqlite] Hardcopy docs?

2006-06-27 Thread Dennis Cote
Bernie Cosell wrote: Hmmm... Since I don't really need 450+ pages of info, but just something akin to a crib sheet of the SQL that sqlite supports (which I'd guess would end up at about 20 pages if it weren't so difficultly-embedded in html files), the option of a fifty dollar book isn't

Re: [sqlite] sqlite3_free()

2006-06-27 Thread Christian Smith
[EMAIL PROTECTED] uttered: Christian Smith <[EMAIL PROTECTED]> wrote: My own personal opinion on these coding style issues is if the API requires special handling of cleanup, then the API should do the cleanup. Returning an allocated string that requires special cleanup results in a

Re: [sqlite] 2PC / two-phase commit?

2006-06-27 Thread Gerhard Häring
Eino Mäkitalo wrote: I am playing with zodb storages and there is some kind of 2pc support. I dont know if I really need it to implement my storage (for fun) zodb over sqlite but at least I was thinking possibility to not make those temporary changes programmatic way but to use sqlite

[sqlite] parsing explain output

2006-06-27 Thread Jay Sprenkle
It occurs to me a program to read explain output and provide suggesions in english would be a useful thing. Has anyone already done anything along this line? Thanks! -- SqliteImporter and SqliteReplicator: Command line utilities for Sqlite http://www.reddawn.net/~jsprenkl/Sqlite Cthulhu Bucks!

Re: [sqlite] sqlite and in memory databases

2006-06-27 Thread Jay Sprenkle
Yes, several others on this forum have done exactly that. I believe the forum is archived somewhere, but I don't know where. It might provide some leads. On 6/26/06, james osburn <[EMAIL PROTECTED]> wrote: i am looking for a embeddable sql database that i can use to manipulate memory stored in

Re: [sqlite] sqlite3_free()

2006-06-27 Thread drh
Christian Smith <[EMAIL PROTECTED]> wrote: > > My own personal opinion on these coding style issues is if the API > requires special handling of cleanup, then the API should do the cleanup. > Returning an allocated string that requires special cleanup results in a > potentially generic

Re: [sqlite] 2PC / two-phase commit?

2006-06-27 Thread Eino Mäkitalo
I am playing with zodb storages and there is some kind of 2pc support. I dont know if I really need it to implement my storage (for fun) zodb over sqlite but at least I was thinking possibility to not make those temporary changes programmatic way but to use sqlite transactions as they are.

Re: [sqlite] 2PC / two-phase commit?

2006-06-27 Thread drh
=?ISO-8859-1?Q?Eino_M=E4kitalo?= <[EMAIL PROTECTED]> wrote: > Does sqlite support two-phase commit (2PC)? > Found some hints about it only with virtual tables. > SQLite uses a 2-phase commit internally when it is making changes to two or more ATTACHed database files. But that is probably not

[sqlite] Multibyte

2006-06-27 Thread Anne . Kirchhellen
Hi to all I have created my own 2 SQLite-DLL's, one as a Unicode-DLL and the other one as Multibyte-DLL. If I create a Test-App with Unicode selected and import the Unicode-DLL it works fine. If I do the same, but have Multibyte select und import the MBCS-DLL, some crazy things happens: Some in

Re: [sqlite] sqlite3_free()

2006-06-27 Thread Christian Smith
[EMAIL PROTECTED] uttered: Two SQLite APIs, sqlite3_exec() and sqlite3_mprintf(), return strings in memory obtained from a malloc-like memory allocator. The documentation has always said that you need to use sqlite3_free() in order to free those strings. But, as it happens, it has until now

[sqlite] 2PC / two-phase commit?

2006-06-27 Thread Eino Mäkitalo
Does sqlite support two-phase commit (2PC)? Found some hints about it only with virtual tables. Eino

[sqlite] sqlite3_free()

2006-06-27 Thread drh
Two SQLite APIs, sqlite3_exec() and sqlite3_mprintf(), return strings in memory obtained from a malloc-like memory allocator. The documentation has always said that you need to use sqlite3_free() in order to free those strings. But, as it happens, it has until now worked to call plain old free().

Re: [sqlite] Hardcopy docs?

2006-06-27 Thread Dan Kennedy
> I guess I'll work harder at getting something readable out of the > 'lang.html' pages... It looks like that if I cobble up a little script > to take the pages linked out of lang.html and just delete the and > blocks at the start of each page it'll get me just the reference > info, and