On Apr 29, 2:56 pm, jmontani <jmont...@gmail.com> wrote:
> Does anyone know what's the equivalence in Oracle of the "first"
> function used by Access?
> ie: Select C.PO_NUM, First(C.SHIPMENT_LINE_ID) AS SHIPMENT_LINE_ID
> FROM C

As I understand it, the Access First()  function returns the first
value of a resultset. It is important to note that in Oracle (or in
Access even) there is no guarantee that any particular ordering is
going to exist in the rows of a result set unless there is an explicit
ORDER BY clause even though for simple one table queries the rows
USUALLY come out in the same order.

You might want to take a peek at the analytical function First_Value,
because I think that does about what you want.
http://download.oracle.com/docs/cd/B10501_01/server.920/a96540/functions46a.htm#1000828

Another possibility is the use of FIRST in the analytical versions of
Min or Max
http://download.oracle.com/docs/cd/B10501_01/server.920/a96540/functions45a.htm#1129681

Hope this is of some small help
Rob




--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Oracle PL/SQL" group.
To post to this group, send email to Oracle-PLSQL@googlegroups.com
To unsubscribe from this group, send email to
oracle-plsql-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/Oracle-PLSQL?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to