Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Oracle Analytical Function ratio_to_report
Is it possible to use ratio_to_report function within PL/SQL block ? I used it from SQL*PLUS, it worked. I could have it work from Perl DBI also. When I try to use it with PL/SQL blockor PRO*C program then it generates syntax error . Any help will be greatly appreciated .
DECLARE
v_sales sales%ROWTYPE ;
BEGIN
SELECT name,
country, SUM(SUM(amt)) OVER (PARTITION BY COUNTRY) AS sum_amtINTO v_sales
*
ORA-06550: line 6, column 30: PLS-00103: Encountered the symbol "(" when expecting one of the following:
![]() |
![]() |