Oracle Error OCI-21704: cannot terminate cache or connection without flushing first

Oracle Error Message

OCI-21704: cannot terminate cache or connection without flushing first

Reason for the Error

See the error message.

Solution

The transaction should be aborted or committed before terminating the cache or connection.