Return-Path: owner-postman
Received: from localhost.Berkeley.EDU (localhost.Berkeley.EDU [127.0.0.1]) by nobozo.CS.Berkeley.EDU (8.6.9/8.6.3) with SMTP id QAA18259 for postgres-redist; Fri, 14 Oct 1994 16:32:12 -0700
Resent-From: POSTGRES mailing list <postman@postgres.Berkeley.EDU>
Resent-Message-Id: <199410142332.QAA18259@nobozo.CS.Berkeley.EDU>
X-Authentication-Warning: nobozo.CS.Berkeley.EDU: Host localhost.Berkeley.EDU didn't use HELO protocol
Sender: owner-postman@postgres.Berkeley.EDU
X-Return-Path: owner-postman
Received: from NMSU.Edu (dns1.NMSU.Edu [128.123.3.5]) by nobozo.CS.Berkeley.EDU (8.6.9/8.6.3) with ESMTP id QAA18249 for <postgres@postgres.berkeley.edu>; Fri, 14 Oct 1994 16:32:11 -0700
Received: from cs by NMSU.Edu (8.6.8.1/NMSU-1.18)
	id RAA00871; Fri, 14 Oct 1994 17:32:09 -0600
Received: from chaperito (chaperito.CS.NMSU.Edu) by cs (4.1/SMI-4.1)
	id AA11327; Fri, 14 Oct 94 17:32:08 MDT
Received: by chaperito (5.0/SMI-4.1)
	id AA01058; Fri, 14 Oct 1994 17:27:30 +0700
Date: Fri, 14 Oct 1994 17:27:30 +0700
From: pmamnani@cs.nmsu.edu (Praveen Mamnani)
Message-Id: <9410142327.AA01058@chaperito>
To: postgres@postgres.Berkeley.EDU
Subject: sorry..
Cc: pmamnani@nmsu.edu
Content-Length: 1138
Resent-To: postgres-redist@postgres.Berkeley.EDU
Resent-Date: Fri, 14 Oct 94 16:32:12 -0700
Resent-XMts: smtp


I am sorry, by mistake the last message was sent in a wrong format.
The following is my original message..

I had some embedded SQL programs that I was converting to PQL,
 
In SQL one can do a SELECT <field name>. In PQL one can retrieve a
field in a similar manner :
 
retrieve (result = EMP.salary)
      where EMP.name = "Bill" \g
 
But when using libpq, executing such simpler queries is not easy.
One has to get the instance in a portal buffer then apply some more
functions (such as PQnfields(), PQgetvalue(), etc.) to get to that
particular field (EMP.salary), for that particular employer "Bill".
 
So every time when I have to retrieve a specific field in a class, I
have to go through this process, instead of just specifying the field
name and the "where" condition (as done in monitor).
 
        In the programs that I am converting I have many-many retrieve
statements, and for each retrieve, I will have to go through all this 
process for each different field in a different class. Is there
another way or an easier way to do such retrieve statments when using libpq?
 
your help would be greatly appriciated.
 
Praveen.

==============================================================================
   To add/remove yourself to/from the POSTGRES mailing list: send mail with 
   the subject line ADD or DEL to "postgres-request@postgres.Berkeley.EDU"

   If this fails, send mail to "post_questions@postgres.Berkeley.EDU" and
   a human will deal with it.  DO NOT post to the "postgres" mailing list.
==============================================================================
