agora inbox for [email protected]  
help / color / mirror / Atom feed
From: M.S.Jackson <[email protected]>
To: [email protected]
Subject: A few questions
Date: Tue, 29 Sep 92 9:27:24 MET DST
Message-ID: <[email protected]> (raw)


I have two very straightforward questions:

1) The following script creates and uses a function to find the names
   of all highly paid employees. How would I alter it to find all the
   attributes of highly paid employees?


spog > create EMP (name=text, salary=int4, age=int4,dept=char16)
CREATE successful
spog > append EMP(name="JOE",salary=1400,age=40,dept="shoe")
APPEND 54708 successful
spog > append EMP(name="Sam",salary=1200,age=29,dept="toy")
APPEND 54720 successful
spog > append EMP(name="Bill",salary=1200,age=29,dept="candy")
APPEND 54721 successful
spog > define function high_pay (language="postquel", returntype = setof EMP)
as "retrieve (EMP.all) where EMP.salary > 1200"
DEFINE successful
spog > retrieve (names=name(high_pay()))
 JOE         

2) The paper entitled "The POSTGRES Data Model" by Rowe and Stonebraker
   talks about relation attributes of type procedure. It gives an example
   of a column declared with type postquel. Has this idea been abandoned?


-- 

*****************************************************************************
*                                                                           *
*  Mike Jackson                                                             *
*  Reader in Software Engineering                                           *
*  School of Computing and Information Technology                           *
*  University of Wolverhampton                                              *
*  Wulfruna St.                              Phone: +44 902 322194          *
*  Wolverhampton WV1 1LY                     Fax:   +44 902 322268          *
*  UNITED KINGDOM                            e-mail: [email protected]  *
*                                                                           *
*****************************************************************************



reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: [email protected]
  Cc: [email protected]
  Subject: Re: A few questions
  In-Reply-To: <[email protected]>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox