PostgreSQL query failed: pqReadData() -- read() failed: errno=0 - Mailing list pgsql-novice

From Juliet May
Subject PostgreSQL query failed: pqReadData() -- read() failed: errno=0
Date
Msg-id 007401c2bbea$f3c572a0$a1d2a8c0@impsu.net
Whole thread Raw
In response to Re: Had to drop some table columns, managed to annoy MS  (Cheryl Thompson <cthompso@ci.irving.tx.us>)
List pgsql-novice
I'm at a total loss! My application was running fine and I didn't change
anything and my coworker claims he didn't change anything  then I started
getting the following error. I looked through the archives for a similar
problem and found that either a.) I didn't understand what caused the
problem or the solution or b.) My scenario is different than the one
mentioned in the archives. I am running Postgresql 7.2 in a cygwin
environment on an NT machine. I don't want to spend a lot of time
troubleshooting if it is a Windows problem since we are in the process of
setting up a Linux machine to handle Postgresql and PHP. Let me know if you
need more info to help identify the problem. Thanks in advance for any help
you can provide.

Julie

/*Error message on page*/

Warning: PostgreSQL query failed: pqReadData() -- read() failed: errno=0 No
error in c:\php\includes\db_pgsql.inc on line 69
Database error: Invalid SQL: select val from active_sessions where sid =
'0e0460e75e2fc7783b9c991e14e3af9f' and name = 'Agtrac_Session'
PostgreSQL Error: 1 (pqReadData() -- read() failed: errno=0 No error )
Session halted.

/* snippet from db_pgsql.inc including line 69 (marked) below */

function query($Query_String) {
    /* No empty queries, please, since PHP4 chokes on them. */
    if ($Query_String == "")
      /* The empty query string is passed on from the constructor,
       * when calling the class without a query, e.g. in situations
       * like these: '$db = new DB_Sql_Subclass;'
       */
      return 0;

    $this->connect();

    if ($this->Debug)
      printf("<br>Debug: query = %s<br>\n", $Query_String);

/* line 69 */    $this->Query_ID = pg_Exec($this->Link_ID, $Query_String);
    $this->Row   = 0;

    $this->Error = pg_ErrorMessage($this->Link_ID);
    $this->Errno = ($this->Error == "")?0:1;
    if (!$this->Query_ID) {
      $this->halt("Invalid SQL: ".$Query_String);
    }

    return $this->Query_ID;
  }



pgsql-novice by date:

Previous
From: Paul Gobble
Date:
Subject: FATAL error on launch
Next
From: Tom Lane
Date:
Subject: Re: FATAL error on launch