X-Original-To: pgsql-interfaces-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id ACBA15370A for ; Tue, 5 Apr 2005 04:39:45 +0100 (BST) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 87611-06 for ; Tue, 5 Apr 2005 03:39:40 +0000 (GMT) Received: from tigger.fuhr.org (tigger.fuhr.org [63.214.45.158]) by svr1.postgresql.org (Postfix) with ESMTP id BCE1C53707 for ; Tue, 5 Apr 2005 04:39:38 +0100 (BST) Received: from winnie.fuhr.org (winnie.fuhr.org [10.1.0.1]) by tigger.fuhr.org (8.13.3/8.13.3) with ESMTP id j353dXEX010250 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Mon, 4 Apr 2005 21:39:36 -0600 (MDT) (envelope-from mfuhr@winnie.fuhr.org) Received: from winnie.fuhr.org (localhost [127.0.0.1]) by winnie.fuhr.org (8.13.3/8.13.3) with ESMTP id j353dXld021741; Mon, 4 Apr 2005 21:39:33 -0600 (MDT) (envelope-from mfuhr@winnie.fuhr.org) Received: (from mfuhr@localhost) by winnie.fuhr.org (8.13.3/8.13.3/Submit) id j353dX5V021740; Mon, 4 Apr 2005 21:39:33 -0600 (MDT) (envelope-from mfuhr) Date: Mon, 4 Apr 2005 21:39:33 -0600 From: Michael Fuhr To: Marvin Bellamy Cc: "'pgsql-interfaces@postgresql.org'" Subject: Re: libpq and referencing data type OIDs Message-ID: <20050405033933.GA21612@winnie.fuhr.org> References: <4251AA64.7040909@innovision.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4251AA64.7040909@innovision.com> X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.004 tagged_above=0 required=5 tests=AWL X-Spam-Level: X-Archive-Number: 200504/21 X-Sequence-Number: 5437 On Mon, Apr 04, 2005 at 03:58:12PM -0500, Marvin Bellamy wrote: > > I want to use postgres' datatype OID definitions and not use the literal > Oid int values (I'm feeding them into PQexecParams()). But, it looks > like these values are defined in a header not included by libpq-fe.h. > When I try importing catalog/pg_type.h, I get a slew of missing data > type errors. So, what's the appropriate way to reference OID data types? Including postgres.h before catalog/pg_type.h should work. I'm not sure how appropriate it is for clients to include backend headers, but it's worked when I've done it. -- Michael Fuhr http://www.fuhr.org/~mfuhr/