Re: [Tutor] flask/sqlite3 problem - 'OperationalError: no such table'?

2013-09-18 Thread Alan Gauld
On 18/09/13 18:13, Timo wrote: You are trying to execute on the database rather than on a cursor. You need to create a cursor first to hold your results. Something like; cur = g.db.cursor() cur.execute(.) Not really. sqlite3.connect() returns a sqlite3.Connection object which has a execu

Re: [Tutor] Web Services with python

2013-09-18 Thread Alan Gauld
On 18/09/13 10:05, Ismar Sehic wrote: Hello, can someone point me to some good guality resources to learn Web Services with Python?with some exaples, tutorials, exercises and such. Python can do web services just fine both as server or client. But what kind of web service? REST? SOAP? XMLRPC?

Re: [Tutor] flask/sqlite3 problem - 'OperationalError: no such table'?

2013-09-18 Thread Timo
Op 18-09-13 15:37, Alan Gauld schreef: On 18/09/13 09:10, memilanuk wrote: def main(): g.db = connect_db() cur = g.db.execute('SELECT * FROM posts') You are trying to execute on the database rather than on a cursor. You need to create a cursor first to hold your results. Something

Re: [Tutor] Copy and paste python on Microsoft word

2013-09-18 Thread Alan Gauld
On 18/09/13 05:59, Sammy Cornet wrote: I'm using python 3.3.0, I have made a program on my script and output it. I have tried several times to copy and paste the output and the script on Microsoft word, How are you creating and running your script? I'm guessing this is an IDE issue rather than

Re: [Tutor] Web Services with python

2013-09-18 Thread Natal Ngétal
On 09/18/13 11:05, Ismar Sehic wrote: > Hello, can someone point me to some good guality resources to learn Web > Services with Python?with some exaples, tutorials, exercises and such. If you want to implement a server, you can look on the side of bottle or flask. __

Re: [Tutor] Copy and paste python on Microsoft word

2013-09-18 Thread Don Jennings
On Sep 18, 2013, at 12:59 AM, Sammy Cornet wrote: > I'm using python 3.3.0, I have made a program on my script and output it. I > have tried several times to copy and paste the output and the script on > Microsoft word, every time I select the part that I need and right click on > it, this mes

Re: [Tutor] Copy and paste python on Microsoft word

2013-09-18 Thread Amit Saha
On Wed, Sep 18, 2013 at 2:59 PM, Sammy Cornet wrote: > I'm using python 3.3.0, I have made a program on my script and output it. I > have tried several times to copy and paste the output and the script on > Microsoft word, every time I select the part that I need and right click on > it, this m

Re: [Tutor] Web Services with python

2013-09-18 Thread Amit Saha
On Wed, Sep 18, 2013 at 7:05 PM, Ismar Sehic wrote: > Hello, can someone point me to some good guality resources to learn Web > Services with Python?with some exaples, tutorials, exercises and such. What do you want to do? Do you want to connect to a remote server or do you want to implement a se

[Tutor] Copy and paste python on Microsoft word

2013-09-18 Thread Sammy Cornet
I'm using python 3.3.0, I have made a program on my script and output it. I have tried several times to copy and paste the output and the script on Microsoft word, every time I select the part that I need and right click on it, this message appears: go to the file/line. It provides me no access

[Tutor] Web Services with python

2013-09-18 Thread Ismar Sehic
Hello, can someone point me to some good guality resources to learn Web Services with Python?with some exaples, tutorials, exercises and such. ___ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: https://mail.python.org/m

Re: [Tutor] flask/sqlite3 problem - 'OperationalError: no such table'?

2013-09-18 Thread Alan Gauld
On 18/09/13 09:10, memilanuk wrote: that I'm missing, but I can't seem to spot it. Below is the tail end of the traceback error message, followed by the code from the file in question. Any help would be much appreciated. line 57, in main cur = g.db.execute('SELECT * FROM posts') Operatio

Re: [Tutor] flask/sqlite3 problem - 'OperationalError: no such table'?

2013-09-18 Thread memilanuk
Sheeesh... After reading your message, I realized I was running the script from inside a new-to-me IDE (pycharm), and started wondering if somehow a path or working directory was not what I thought it might be. I closed out the IDE window, and ran the script directly from the terminal - succ

Re: [Tutor] flask/sqlite3 problem - 'OperationalError: no such table'?

2013-09-18 Thread Peter Otten
memilanuk wrote: > I'm working thru a Flask tutorial, and when I get to the portion for > querying the database (sqlite3) for the existing posts, i.e. 'SELECT * > FROM posts', I get an error that says there is no such table 'posts' in > my database. Yet I can query said db file from either the sq

[Tutor] flask/sqlite3 problem - 'OperationalError: no such table'?

2013-09-18 Thread memilanuk
Hello there, I'm working thru a Flask tutorial, and when I get to the portion for querying the database (sqlite3) for the existing posts, i.e. 'SELECT * FROM posts', I get an error that says there is no such table 'posts' in my database. Yet I can query said db file from either the sqlite3 c