How to fix the Oracle error PLS-00374: illegal EXIT/CONTINUE statement; must appear inside the loop labeled ‘string’?

In this post, you’ll learn more about the Oracle ErrorPLS-00374: illegal EXIT/CONTINUE statement; must appear inside the loop labeled ‘string’ with the details on why you receive this error and the possible solution to fix it.

Oracle Error Description

PLS-00374: illegal EXIT/CONTINUE statement; must appear inside the loop labeled ‘string’

Reason for the Error PLS-00374: illegal EXIT/CONTINUE statement; must appear inside the loop labeled ‘string’

The label in the EXIT or CONTINUE statement did not refer to a loop statement. An EXIT or CONTINUE statement need not specify a label. However, if a label is specified (as in EXIT my_label or CONTINUE my_label), the EXIT or CONTINUE statement must be inside the LOOP statement designated by that label.

How to fix the Error PLS-00374: illegal EXIT/CONTINUE statement; must appear inside the loop labeled ‘string’ ?

You can fix this error in Oracle by following the below steps

Make sure the label name is spelled correctly; if necessary, move the EXIT or CONTINUE statement inside the LOOP statement to which the label refers.

Tags :

Leave Your Comment