Re: [sqlite] Is sqlite case-sensitive?

2014-05-19 Thread Dominique Devienne
On Sun, May 18, 2014 at 9:46 PM, James K. Lowden wrote: > I can easily imagine uses for a generalized SQLite parser, one that > returned an abstract syntax tree. A program might use such a thing for > all sorts of "server-side" functionality, for example to process a > string provided to a virtua

Re: [sqlite] Is sqlite case-sensitive?

2014-05-18 Thread Jean-Christophe Deschamps
At 22:36 18/05/2014, you wrote: The more I think of it, though, I think that the solution is as simple as converting all letters to lower(/upper) case and converting all whitespace to a single space each, except for within matching [ ], " ", ' ' or ` `. After that, I can do a memcmp(). You'r

Re: [sqlite] Is sqlite case-sensitive?

2014-05-18 Thread Baruch Burstein
On Sun, May 18, 2014 at 10:46 PM, James K. Lowden wrote: > On Sun, 18 May 2014 19:15:18 +0200 > RSmith wrote: > > > > As Igor says, http://sqlite.org/c3ref/prepare.html would be > > > appropriate. However, a database connection is required for this. > > > > But of course What kind of syntact

Re: [sqlite] Is sqlite case-sensitive?

2014-05-18 Thread James K. Lowden
On Sun, 18 May 2014 19:15:18 +0200 RSmith wrote: > > As Igor says, http://sqlite.org/c3ref/prepare.html would be > > appropriate. However, a database connection is required for this. > > But of course What kind of syntactical correctness can you hope > to check without a connection? You co

Re: [sqlite] Is sqlite case-sensitive?

2014-05-18 Thread RSmith
On 2014/05/18 19:28, Wolfgang Enzinger wrote: Completely agreed. I was just referring to the OP who asked for an "API Indeed - my apologies too - I took your statement to imply that the solution (which Igor and yourself discussed) would not work for the OP precisely because of it needing

Re: [sqlite] Is sqlite case-sensitive?

2014-05-18 Thread Wolfgang Enzinger
Am Sun, 18 May 2014 19:15:18 +0200 schrieb RSmith: > But of course What kind of syntactical correctness can you hope to > check without a connection? [...] Completely agreed. I was just referring to the OP who asked for an "API to validate a SQL statement, either in the context of the curre

Re: [sqlite] Is sqlite case-sensitive?

2014-05-18 Thread RSmith
On 2014/05/18 17:24, Wolfgang Enzinger wrote: i _think_ what you want is: http://sqlite.org/c3ref/complete.html I don't think so, because this function essentially checks "if [the statement] ends with a semicolon token". Furthermore, "these routines do not parse the SQL statements thus will n

Re: [sqlite] Is sqlite case-sensitive?

2014-05-18 Thread Wolfgang Enzinger
>>> names), or without context (just validate syntax, e.g. that it can be >>> parsed)? >>> >> I am asking about this API since I think I remember seeing it once, but >> can't find it now >> > > i _think_ what you want is: > > http://sqlite.org/c3ref/complete.html I don't think so, because this

Re: [sqlite] Is sqlite case-sensitive?

2014-05-18 Thread Simon Slavin
On 18 May 2014, at 3:32pm, Baruch Burstein wrote: > Sqlite is case-insensitive as far as table/column/db names. Is this > documented as official behavior or it may change? I would like to expand the scope of this question because I think an answer to just what Baruch asked may be over-specific

Re: [sqlite] Is sqlite case-sensitive?

2014-05-18 Thread Igor Tandetnik
On 5/18/2014 10:32 AM, Baruch Burstein wrote: Sqlite is case-insensitive as far as table/column/db names. Is this documented as official behavior or it may change? It's highly unlikely to change, since that would break countless applications. Also, is there a function in the API to validate

Re: [sqlite] Is sqlite case-sensitive?

2014-05-18 Thread Stephan Beal
On Sun, May 18, 2014 at 4:37 PM, Baruch Burstein wrote: > > names), or without context (just validate syntax, e.g. that it can be > > parsed)? > > > I am asking about this API since I think I remember seeing it once, but > can't find it now > i _think_ what you want is: http://sqlite.org/c3ref/c

Re: [sqlite] Is sqlite case-sensitive?

2014-05-18 Thread Baruch Burstein
On Sun, May 18, 2014 at 5:32 PM, Baruch Burstein wrote: > Sqlite is case-insensitive as far as table/column/db names. Is this > documented as official behavior or it may change? > > Also, is there a function in the API to validate a SQL statement, either > in the context of the current connection

[sqlite] Is sqlite case-sensitive?

2014-05-18 Thread Baruch Burstein
Sqlite is case-insensitive as far as table/column/db names. Is this documented as official behavior or it may change? Also, is there a function in the API to validate a SQL statement, either in the context of the current connection (validate also table/column/db names), or without context (just va

RE: [sqlite] Is SQLite Case Sensitive?

2007-08-08 Thread Lee Crain
m. Thanks, Lee Crain __ -Original Message- From: Dwight Ingersoll [mailto:[EMAIL PROTECTED] Sent: Wednesday, August 08, 2007 5:11 PM To: sqlite-users@sqlite.org Subject: Re: [sqlite] Is SQLite Case Sensitive? --- Lee Crain <[EMAIL PROTECTED]> wrote: >

Re: [sqlite] Is SQLite Case Sensitive?

2007-08-08 Thread Dwight Ingersoll
--- Lee Crain <[EMAIL PROTECTED]> wrote: > I am working on an application where I am importing > data for which great care has NOT been taken to > ensure uppercase and lowercase letters have been > entered appropriately. Just a suggestion: This sounds like it's a candidate for some data scrubbi

RE: [sqlite] Is SQLite Case Sensitive?

2007-08-07 Thread Samuel R. Neff
rs@sqlite.org Subject: Re: [sqlite] Is SQLite Case Sensitive? SQL is not case-sensitive, but SQL comparisons are. Use the following SELECT * FROM table WHERE field1 = 'a' OR field1 = 'A' you can also use WHERE Lowe

Re: [sqlite] Is SQLite Case Sensitive?

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

Re: [sqlite] Is SQLite Case Sensitive?

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

[sqlite] Is SQLite Case Sensitive?

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