[Tutor] Databases in Python

Che M pine508 at hotmail.com
Tue Aug 24 19:03:09 CEST 2010

> The other day, I wrote a little database just to fiddle around, 
> but when I try to run it it says that it has an unexpected indent. 
> From what I can tell, it doesn't. Here's the code. I'm using SPE.

In the future, you should copy/paste error message you get into
your email.  This way it indicates to others the exact problem you

One thing I noticed that is wrong in your code is this line:

if searcher in database:			# Figure this out.			The comment doesn't count as a line of interpretable code, so
you have nothing in this code block.  If you want to do that, use
pass, like:

if searcher in database:    pass			
    # Figure this out.			
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/tutor/attachments/20100824/0ff989f1/attachment.html>

More information about the Tutor mailing list