Re: Can't put SELECT in formula column Oracle Reports 4.5

From: Arjan van Bentem <avbentem_at_DONT-YOU-DAREdds.nl>
Date: Fri, 14 Aug 1998 19:33:25 +0200
Message-ID: <6r1sbr$g1h$1_at_newton.a2000.nl>


>Excuse me for unprecision I am using Oracle Reports ver 4.5

OK, then for sure my previous answer will help you out -- the normal PL/SQL rules apply in Forms and Reports. So anything you select in your function you should select "into" a variabele, as otherwise Oracle won't know what to do with the result. Furthermore, such queries should result in exactly one row, for otherwise Oracle raises the error "No data found" or "Exact fetch returned more than one row".

[Quoted] By the way, months_between is allowed in PL/SQL as well. So, you could simply write:

    ret_var := MONTHS_BETWEEN (:BIRTH_DATE, :CURRENT_DATE);     return ret_var;

The only function I can think of which is not allowed -- but would in fact be very useful -- is decode(..) .

Arjan. Received on Fri Aug 14 1998 - 19:33:25 CEST

Original text of this message