[DB-SIG] document contains no data
Marcos Sánchez Provencio
msanchez at grupoburke.com
Fri Jan 23 05:05:44 EST 2004
Are you using cgi?
Be sure to include the correct headers in your cgi. Check also that the
environment for the cgi (path, etc.) is the same as for the user you are
testing from. You may try to create a minimal cgi first.
helena bhaska escribió:
> Hi everybody,
> I am trying to connect to a database and read
> something from it in a program that runs under apache.
> Here's my code:
> db = MySQLdb.Connect(host="host", user="usr",
> passwd="pswd", db="db")
> c = db.cursor()
> c.execute("""SELECT * FROM SomeTable""")
> results = c.fetchall()
> The execute statement causes the internet browser to
> spit out a dialog box with a message "document
> contains no data"
> If I run these statements from python command line, it
> works fine.
> First of all, I would like what that message about no
> data means...
> The apache error log gives me the following:
> [Thu Jan 22 17:49:58 2004] [notice] child pid 9186
> exit signal Segmentation fault (11) - which obviously
> is bad, but I again don't know what this means.
> Thanks for any pointers.
> Do you Yahoo!?
> Yahoo! SiteBuilder - Free web site building tool. Try it!
> DB-SIG maillist - DB-SIG at python.org
More information about the DB-SIG