Re: [Tutor] sqlite3 Question

2012-06-06 Thread Prasad, Ramit
> > 1. import sqlite3 > 2. conn=sqlite3.connect("mydb2.db") > 3. c=conn.cursor() > 4. c.execute('create table family (Id integer primary key, name text, age > integer)') > 5. c.execute("insert into family values (1,'elham',32)") > 6. c.execute('select * from family') > 7. conn.commit() > 8. for i

[Tutor] sqlite3 Question

2012-06-06 Thread Khalid Al-Ghamdi
Hi All, hi Joel, Regarding sqlite3 practice code below: 1. import sqlite3 2. conn=sqlite3.connect("mydb2.db") 3. c=conn.cursor() 4. c.execute('create table family (Id integer primary key, name text, age integer)') 5. c.execute("insert into family values (1,'elham',32)") 6.

Re: [Tutor] sqlite3 question

2012-05-24 Thread Peter Otten
Alan Gauld wrote: > On 23/05/12 17:11, Khalid Al-Ghamdi wrote: > >> I'm using Python 3 and have read that you need sqlite to be installed to >> use the sqlite3 module, but when it is imported it seems to work ok. > > The info is wrong. > Unlike other SQL databases SQLite is not a server based sy

Re: [Tutor] sqlite3 question

2012-05-23 Thread Alan Gauld
On 23/05/12 17:11, Khalid Al-Ghamdi wrote: I'm using Python 3 and have read that you need sqlite to be installed to use the sqlite3 module, but when it is imported it seems to work ok. The info is wrong. Unlike other SQL databases SQLite is not a server based system so there is nothing to ins

Re: [Tutor] sqlite3 question

2012-05-23 Thread Ken G.
On 05/23/2012 12:51 PM, Joel Goldstick wrote: On Wed, May 23, 2012 at 12:11 PM, Khalid Al-Ghamdi wrote: hi all, I'm using Python 3 and have read that you need sqlite to be installed to use the sqlite3 module, but when it is imported it seems to work ok. so, do you need to install it? also, w

Re: [Tutor] sqlite3 question

2012-05-23 Thread Joel Goldstick
On Wed, May 23, 2012 at 12:11 PM, Khalid Al-Ghamdi wrote: > hi all, > > I'm using Python 3 and have read that you need sqlite to be installed to use > the sqlite3 module, but when it is imported it seems to work ok. so, do you > need to install it? also, when you create the database where is it sa

[Tutor] sqlite3 question

2012-05-23 Thread Khalid Al-Ghamdi
hi all, I'm using Python 3 and have read that you need sqlite to be installed to use the sqlite3 module, but when it is imported it seems to work ok. so, do you need to install it? also, when you create the database where is it saved? thanks ___ Tutor