Received: from localhost (unknown [200.46.208.211]) by mail.postgresql.org (Postfix) with ESMTP id 5974C62E9C1 for ; Mon, 5 Oct 2009 18:51:04 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by localhost (mx1.hub.org [200.46.208.211]) (amavisd-maia, port 10024) with ESMTP id 62807-05 for ; Mon, 5 Oct 2009 21:50:48 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from mail19.svc.cra.dublin.eircom.net (mail19.svc.cra.dublin.eircom.net [159.134.118.218]) by mail.postgresql.org (Postfix) with SMTP id 84678634280 for ; Mon, 5 Oct 2009 18:50:53 -0300 (ADT) Received: (qmail 82104 messnum 335943 invoked from network[86.46.36.98/86-46-36-98-dynamic.b-ras3.mvw.galway.eircom.net]); 5 Oct 2009 21:50:50 -0000 Received: from 86-46-36-98-dynamic.b-ras3.mvw.galway.eircom.net (HELO ?127.0.0.1?) (86.46.36.98) by mail19.svc.cra.dublin.eircom.net (qp 82104) with SMTP; 5 Oct 2009 21:50:50 -0000 Message-ID: <4ACA6A3B.50005@iol.ie> Date: Mon, 05 Oct 2009 22:50:51 +0100 From: Raymond O'Donnell Reply-To: rod@iol.ie User-Agent: Thunderbird 2.0.0.23 (Windows/20090812) MIME-Version: 1.0 To: Marco Dieckhoff CC: pgsql-php@postgresql.org Subject: Re: checking select query syntax and semantics via php without executing References: <4ACA6668.2000701@gmx.de> In-Reply-To: <4ACA6668.2000701@gmx.de> X-Enigmail-Version: 0.96.0 Content-Type: text/plain; charset=ISO-8859-15 Content-Transfer-Encoding: 7bit X-Antivirus: avast! (VPS 091004-0, 04/10/2009), Outbound message X-Antivirus-Status: Clean X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-0.123 tagged_above=-10 required=5 tests=AWL=-0.124, BAYES_50=0.001 X-Spam-Level: X-Archive-Number: 200910/2 X-Sequence-Number: 4081 On 05/10/2009 22:34, Marco Dieckhoff wrote: > Is it possible in PHP to give a sql (select) query to Postgres via pg_* > so that it is NOT executed but merely checked for syntax including > correct, existing field and table names, and data types? How about prepending "explain" to the query? Just a wild notion. Ray. ------------------------------------------------------------------ Raymond O'Donnell, Director of Music, Galway Cathedral, Ireland rod@iol.ie Galway Cathedral Recitals: http://www.galwaycathedral.org/recitals ------------------------------------------------------------------