== Why is this an issue?

You should avoid closing a ``++CURSOR++`` inside a ``++PERFORM++`` statement, because it could impact performance or lead to unexpected behavior if the cursor was not opened in the same loop.


=== Noncompliant code example

[source,cobol]
----
 PERFORM UNTIL (NOT DA-OK)
       OR (Y00CIA-CD-RET-PGM = ZERO)
    EXEC SQL CLOSE C2
    END-EXEC
  END-PERFORM.
----

ifdef::env-github,rspecator-view[]

'''
== Implementation Specification
(visible only on this page)

=== Message

Move this close statement outside the loop.


endif::env-github,rspecator-view[]
