CARIOTOGLOU MIKE wrote:
> I can verify this :
>
> Select "columnName" from someTable gives columns with quoted names !
> ("ColumnName") instead of ColumnName
>
> This *feels* like a bug
>
I believe this is a bug as well.
The following script demonstrates the problems using the sqlite3 shell. I
us
I'm using SQLite 3.08 for Windows, SQLite.Net.
Sqlite3Explorer(developed by delphi) can also see this situation.
create table tb (ID varchar);
Code example:
IDataReader reader = command.ExecuteReader("select * from tb");
Console.WriteLine((string)reader["ID"]);
While:
IDataReader reader = command.ExecuteReader("select \"ID\" from tb");
Console.WriteLine((string)reader["\"ID\"]; // using reader["ID"]
wi
> select "ID" from tb"
>
> Doesn't this mean select the literal value "ID"?
No, if ID is a valid column name in the context, "ID" will
evaluate to a column reference; you must use single quotes
to ensure evaluation as a literal -- BTW, this is correct
behavior for std SQL.
Regards
27;il
m^Ne from two or more threads
**
-Original Message-
From: D. Richard Hipp [mailto:[EMAIL PROTECTED]
Sent: Tuesday, December 21, 2004 11:55 AM
To: [EMAIL PROTECTED]
Subject: Re: [sqlite] What's the difference of "select * fr
red forks wrote:
A table:
create table tb (ID varchar);
When execute select * from tb, I can refer the column row["ID"], while
using "select "ID" from tb", I must using row["\"ID\"'].
Why Sqlite return column name as "ID"?
I do not understand the question.
--
D. Richard Hipp -- [EMAIL PROTECTED] --
6 matches
Mail list logo