Re: [sqlite] COMMIT in SQLite

2008-12-14 Thread hussainfarzana
Thanks for your reply Igor. We have used BEGIN and COMMIT while executing our statements.While executing the BEGIN the return value is 0,but for COMMIT its returning 1. Please guide us. Regards, Farzana. Igor Tandetnik wrote: > > "hussainfarzana" > wrote in >

Re: [sqlite] Adding data with periods

2008-12-14 Thread John Stanton
Single quotes are SQL, as chosen by he designers. It is good practice to stick to the standard rather than rely on extensions which vary from implementatiopn tio implementation. Mohd Radzi Ibrahim wrote: > It seems to works either way. > > I'm just wondering is there any hidden reason that

Re: [sqlite] Adding data with periods

2008-12-14 Thread Mohd Radzi Ibrahim
It seems to works either way. I'm just wondering is there any hidden reason that single quote is preferred? Portability? Or is double-qoute has some kind of special meaning that we should use it for that special purpose? -radzi- - Original Message - From: "P Kishor"

Re: [sqlite] Adding data with periods

2008-12-14 Thread P Kishor
On 12/14/08, aditya siram wrote: > Thanks a lot. The issue has been fixed with: > INSERT INTO TEST_TABLE(CONTENTS) VALUES ("Hello. World!"); > Use single quotes to delimit text, not double quotes. ___ sqlite-users mailing list

Re: [sqlite] Adding data with periods

2008-12-14 Thread aditya siram
Thanks a lot. The issue has been fixed with: INSERT INTO TEST_TABLE(CONTENTS) VALUES ("Hello. World!"); I was thrown by the error message that seemed to be complaining about the periods when I was actually missing the VALUES(...) clause. Appreciate the quick response ... deech On Sun, Dec 14,

Re: [sqlite] Adding data with periods

2008-12-14 Thread John Stanton
Note that literal delimiters in SQL are single quotes, e.g. 'This is an SQL literal'. It is good practice with Sqlite to use bound variables. You avoid possible SQL injection attacks and limit sensitivity to data content. aditya siram wrote: > Hi all, > I'm having trouble adding data with

Re: [sqlite] Adding data with periods

2008-12-14 Thread Mohd Radzi Ibrahim
The syntax is wrong. INSERT INTO TEST_TABLE(CONTENTS) VALUES ("Hello. World!"); is the correct one. -radzi- - Original Message - From: "aditya siram" To: Sent: Monday, December 15, 2008 1:04 PM Subject: [sqlite] Adding data with

Re: [sqlite] Adding data with periods

2008-12-14 Thread P Kishor
On 12/14/08, aditya siram wrote: > Hi all, > I'm having trouble adding data with period characters in it. I tries to > escape the period with a `'` but that didn' t seem to work. Here is an > example interaction: > > sqlite> create table test_table ("Contents"

Re: [sqlite] Adding data with periods

2008-12-14 Thread kirrthana
Hi, Sqlite takes the period as a special character. Wherever you get a period ' make it as ''. This will make it as a normal character and will work fine. Hope the solution solves your problem. Regards, Kirrthana -Original Message- From: sqlite-users-boun...@sqlite.org

[sqlite] Adding data with periods

2008-12-14 Thread aditya siram
Hi all, I'm having trouble adding data with period characters in it. I tries to escape the period with a `'` but that didn' t seem to work. Here is an example interaction: sqlite> create table test_table ("Contents" varchar); sqlite> insert into test_table "hello . world"; SQL error: near ""hello

Re: [sqlite] Impossible to declare field type BIGINT PRIMARY KEY

2008-12-14 Thread Jay A. Kreibich
On Sun, Dec 14, 2008 at 08:25:02PM +, Nathan Catlow scratched on the wall: > I am trying to use libdbi + sqlite for my project. It is impossible > for libdbi to determine the PRIMARY KEY type (64bit) using PRAGMA > table_info(). Why impossible? The type in INTEGER, just as returned.

Re: [sqlite] Impossible to declare field type BIGINT PRIMARY KEY

2008-12-14 Thread Roger Binns
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Nathan Catlow wrote: > ... INTEGER (32 bit in at least mysql) ... > ... (id BIGINT ... You seem to be under the impression that SQLite has multiple variable sized integers. It doesn't. The SQLite integer type is 64 bit signed. (It will use less

Re: [sqlite] General index information

2008-12-14 Thread Florian Weimer
* Igor Tandetnik: > L B wrote: >> The explanation you made is only valid for sqlite or >> for SQL in general? > > For SQL in general. True, but there are some database engines that support skip-index scans, so if there are only few different values of X, say x_1, ...

[sqlite] Impossible to declare field type BIGINT PRIMARY KEY

2008-12-14 Thread Nathan Catlow
I am trying to use libdbi + sqlite for my project. It is impossible for libdbi to determine the PRIMARY KEY type (64bit) using PRAGMA table_info(). This has completely crippled my project that relies on autoincrement. As the PRIMARY KEY is an alias to ROWID (64bit), the data should be