Received: from mail0.lig.bellsouth.net (mail0.lig.bellsouth.net [207.203.120.39]) by postgresql.org (8.11.3/8.11.1) with ESMTP id f482DgA91187 for ; Mon, 7 May 2001 22:13:42 -0400 (EDT) (envelope-from rgp@systame.com) Received: from [216.77.205.109] (host-216-77-205-109.psl.bellsouth.net [216.77.205.109]) by mail0.lig.bellsouth.net (3.3.5alt/0.75.2) with ESMTP id WAA10910 for ; Mon, 7 May 2001 22:13:37 -0400 (EDT) User-Agent: Microsoft-Outlook-Express-Macintosh-Edition/5.02.2022 Date: Mon, 07 May 2001 22:12:18 -0400 Subject: how to use $result->ruseltStatus From: Randall Perry To: Message-ID: Mime-version: 1.0 Content-type: text/plain; charset="US-ASCII" Content-transfer-encoding: 7bit X-Archive-Number: 200105/31 X-Sequence-Number: 1557 I want to make sure queries returned aren't empty. Tried this: $conn = Pg::connectdb("dbname=$db"); $res = $conn->exec("$q"); $result_status = $res->resultStatus; ($result_status != PGRES_EMPTY_QUERY) ? print "query not empty\n" : print "query empty\n"; But it returns '2' (not sure which constant it is, but it's not PGRES_EMPTY_QUERY) on empty queries. What's the right use of this property? -- Randy Perry sysTame Mac Consulting/Sales