Received: from maia.hub.org (maia-3.hub.org [200.46.204.243]) by mail.postgresql.org (Postfix) with ESMTP id 4703F632785 for ; Sun, 29 Aug 2010 11:58:29 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.243]) (amavisd-maia, port 10024) with ESMTP id 64380-10 for ; Sun, 29 Aug 2010 14:58:20 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from sss.pgh.pa.us (sss.pgh.pa.us [66.207.139.130]) by mail.postgresql.org (Postfix) with ESMTP id 5AA83632585 for ; Sun, 29 Aug 2010 11:58:22 -0300 (ADT) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.2/8.14.2) with ESMTP id o7TEwJO3016892; Sun, 29 Aug 2010 10:58:19 -0400 (EDT) To: Dmitriy Igrishin cc: pgsql-docs@postgresql.org Subject: Re: libpq (PQprepared) In-reply-to: References: Comments: In-reply-to Dmitriy Igrishin message dated "Sun, 29 Aug 2010 13:17:37 +0400" Date: Sun, 29 Aug 2010 10:58:19 -0400 Message-ID: <16891.1283093899@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.91 tagged_above=-5 required=5 tests=BAYES_00=-1.9, T_RP_MATCHES_RCVD=-0.01 X-Spam-Level: X-Archive-Number: 201008/120 X-Sequence-Number: 5944 Dmitriy Igrishin writes: > The description of PQprepare() of libpq > (http://www.postgresql.org/docs/9.0/static/libpq-exec.html) > says: > (But PQprepare is more flexible since it does not require parameter > types to be pre-specified.) > But the description of PREPARE > (http://www.postgresql.org/docs/9.0/static/sql-prepare.html) > says: > The data type of a parameter to the prepared statement. If the data > type of a particular parameter is unspecified or is specified as unknown, > it will be inferred from the context in which the parameter is used. > So, PQprepare() is NOT more flexible in this case because PREPARE > does not require parameters types to be pre-specifies also. Hmmm ... it was true when written, but is out of date now. AFAICS it's sufficient to just remove the parenthetical remark. regards, tom lane