Received: from localhost (maia-5.hub.org [200.46.204.182]) by postgresql.org (Postfix) with ESMTP id 416179FBDBB for ; Mon, 4 Jun 2007 11:51:31 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.182]) (amavisd-maia, port 10024) with ESMTP id 31455-05-5 for ; Mon, 4 Jun 2007 11:51:15 -0300 (ADT) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.4 Received: from an-out-0708.google.com (an-out-0708.google.com [209.85.132.241]) by postgresql.org (Postfix) with ESMTP id 89F0B9FBD02 for ; Mon, 4 Jun 2007 11:51:14 -0300 (ADT) Received: by an-out-0708.google.com with SMTP id c36so324623ana for ; Mon, 04 Jun 2007 07:51:13 -0700 (PDT) DKIM-Signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:references; b=NfFQNIRL+QyBDBMd8WDEA3ojkm882bZ1WiNfyyRAPrVC0wBAv1I+pLke2IArYqh+35XLuhqLVI7KNopYTuVXJmVYo/Q1KJBwj+MV2S8TeScGCGaW21NfGm5MDuPHrGT2y1CEMfL6uV/1BzP648jddRpPb7S4WaFzPyOfABCvlbI= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:references; b=RCkdaTOjFcvWICE5C7CHsNa5dDWVhLk9qAqFJonToyy1pr4g28SBm+DdTboiLHwyPY5qTgTB3oQBPa4OUw/gvS8ZWkFqVRAwytvK6NbxI4BW4cC9hB1y3j45jSFhWmLMnzuNizNhrgVlF80m73BvutZ9ks3KTnF9wVTyPfqODak= Received: by 10.100.166.14 with SMTP id o14mr2618953ane.1180968673200; Mon, 04 Jun 2007 07:51:13 -0700 (PDT) Received: by 10.100.168.8 with HTTP; Mon, 4 Jun 2007 07:51:13 -0700 (PDT) Message-ID: Date: Mon, 4 Jun 2007 22:51:13 +0800 From: "Wilhansen Li" To: pgsql-interfaces@postgresql.org Subject: Re: Bytea network traffic: binary vs text result format In-Reply-To: <46640B8F.8040503@bluegap.ch> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_3424_20068182.1180968673094" References: <466299A7.20403@eba.si> <46640B8F.8040503@bluegap.ch> X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200706/3 X-Sequence-Number: 6572 ------=_Part_3424_20068182.1180968673094 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline On 6/4/07, Markus Schiltknecht wrote: > > > There already are. Not in libpq, though. Most (if not all) internal > types have those functions. Well, I don't think it would be puzzling that someone will ask for them even if those functions already exist in PostgreSQL because, as you stated, it's not in libpq. People will actually have to dig in the source to pinpoint where in the source tree those functions exist and how to include them in the program, which, I assume, is less ideal than when it's already included in libpq in the first place. There was a post before on a user who got disappointed because of the "crappy" support of libpq (not PostgreSQL) for binary formats. In line with this, I'm aware of the issues that this may pose: http://archives.postgresql.org/pgsql-hackers/1999-08/msg00374.php this is already very old (8 years ago!). And they discuss about the issue that the representation might change from version to version so it's not done. There have been plans to incorporate CORBA, which IMHO is an overkill, to solve this problem but I don't think it's done yet because it's probably too complex (?). I'd rather recommend them to use ASN.1 (if that's feasible..). -- Life is too short for dial-up. ------=_Part_3424_20068182.1180968673094 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline

On 6/4/07, Markus Schiltknecht <markus@bluegap.ch> wrote:

There already are. Not in libpq, though. Most (if not all) internal
types have those functions.

Well, I don't think it would be puzzling that someone will ask for them even if those functions already exist in PostgreSQL because, as you stated, it's not in libpq. People will actually have to dig in the source to pinpoint where in the source tree those functions exist and how to include them in the program, which, I assume, is less ideal than when it's already included in libpq in the first place. There was a post before on a user who got disappointed because of the "crappy" support of libpq (not PostgreSQL) for binary formats.

In line with this, I'm aware of the issues that this may pose: http://archives.postgresql.org/pgsql-hackers/1999-08/msg00374.php this is already very old (8 years ago!). And they discuss about the issue that the representation might change from version to version so it's not done. There have been plans to incorporate CORBA, which IMHO is an overkill, to solve this problem but I don't think it's done yet because it's probably too complex (?). I'd rather recommend them to use  ASN.1 (if that's feasible..).


--
Life is too short for dial-up. ------=_Part_3424_20068182.1180968673094--