Re: What Am I missing?

From: Mladen Gogala <gogala.mladen_at_gmail.com>
Date: Mon, 7 Sep 2020 15:54:07 -0400
Message-ID: <ac223158-ee26-5398-9054-f64713c37f20_at_gmail.com>



BTW, you can use "execute immediate" to the same effect.

On 9/7/20 3:47 PM, Mladen Gogala wrote:
> Hi Dave,
> It's  a  PL/SQL parser bug. Boh SQL*Developer and SQL*Plus report an
> error on thee "/" line, Here is the version that works:
>
> SQL> create or replace function test_fn return integer as
>   2  vPercentage NUMBER;
>   3  cursor csr is select round(((select sum(vsize(ename)) from
> emp)/(SELECT SUM(bytes) FROM user_free_space WHERE tablespace_name =
> 'USERS')) *100, 2) from dual;
>   4  begin
>   5  open csr;
>   6  fetch csr into vPercentage;
>   7  close csr;
>   8  RETURN vPercentage;
>   9  END test_fn;
>  10  /
>
>
>
> Function TEST_FN compiled
>
>
> --
> Mladen Gogala
> /Database Consultant
> Tel: (347) 321-1217/

-- 
Mladen Gogala
Database Consultant
Tel: (347) 321-1217


--
http://www.freelists.org/webpage/oracle-l
Received on Mon Sep 07 2020 - 21:54:07 CEST

Original text of this message