Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Reg: PLS-00428: an INTO clause is expected in this SELECT statement

747393Jan 19 2010 — edited Jan 19 2010
Hi Friends,

I am creating stored procedure in oracle 10g with TOAD as follow,


CREATE OR REPLACE PROCEDURE SPROC_GETLOVTotalandTranslated
(
v_lid integer
)
IS
BEGIN

SELECT
L1.TYPE,
COUNT(L1.LOVID) AS Total,
(SELECT COUNT(L2.LOVID) FROM MM_LIST_OF_VALUES L2 WHERE L2.TYPE = L1.TYPE AND (L2.TEXT IS NULL OR L2.TEXT = '') and L2.L_id = v_lid) AS UnTranslated,
(SELECT COUNT(L2.LOVID) FROM MM_LIST_OF_VALUES L2 WHERE L2.TYPE = L1.TYPE AND (L2.TEXT IS NOT NULL OR L2.TEXT != '') and L2.L_id = v_lid) AS Translated
FROM
MM_LIST_OF_VALUES L1
WHERE
L1.L_ID = v_lid
GROUP BY
L1.TYPE;

END SPROC_GETLOVTotalandTranslated;


But, when i compile this statement, it shows the compilation error as "PLS-00428: an INTO clause is expected in this SELECT statement"


Please let me know whats the error and how to resolve it.

Thanks & Regards,
Senthilnathan
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Feb 16 2010
Added on Jan 19 2010
4 comments
7,265 views