Re: 08P01: unexpected EOF on client connection

From: Craig Ringer <craig(at)postnewspapers(dot)com(dot)au>
To: Tomas Vondra <tv(at)fuzzy(dot)cz>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: 08P01: unexpected EOF on client connection
Date: 2009-05-01 06:31:48
Message-ID: 49FA9754.8090100@postnewspapers.com.au
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Tomas Vondra wrote:

> $conn = pg_connect(...);
> $res = pg_query("SELECT mime, thumbnail_data FROM images WHERE filename
> = ....");
> $row = pg_fetch_assoc($row);
> header('Content-Type: ' . $row['mime']);
> echo pg_unescape_bytea($row['thumbnail_data']);

PHP?

Try running your script in a PHP debugger (from the command line or, if
your server supports it, while hosted) and see at what point exactly
things go pear shaped. Check your web server error log for any client
library or PHP errors, too.

Even just adding a bunch of logging statements into your script then
looking at your web server error log might help you a little.

--
Craig Ringer

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Dennis Brakhane 2009-05-01 08:40:47 Re: Understand this error
Previous Message Craig Ringer 2009-05-01 06:23:12 Re: could not bind IPv4 socket