Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: A simple SELECT ?
In article <7i3sr8$js8$1_at_xenon.inbe.net>,
"ACT_at_BLUEGATE" <act_at_bluegate.be> wrote:
> It seems simple...
>
> I've a deliveries table with three columns: date, customer id, and
quantity.
>
> How can i retrieve in a query the last (in time) 10 deliveries for a
> specified customer ?
This is not the sort of thing that SQL does easily (at least, I don't think so). However, you might try writing a PL/SQL stored procedure with a cursor that reads the deliveries information in date order and stores the results in a PL/SQL table and counts them, then outputs the last ten entries in the PL/SQL table.
--
Replies send to this email address are automatically discarded. To
reply, please post in this newsgroup, or email to (make the obvious
substitutions) harknessATskepticsDOTorg
--== Sent via Deja.com http://www.deja.com/ ==-- ---Share what you know. Learn what you don't.--- Received on Fri May 21 1999 - 12:52:12 CDT