rules repository

G-7520

🆓
Warning

Avoid using deprecated units in your own code.

Reason

Deprecated units (packages, package procedures, package functions and types) are not maintained anymore and may be removed in future releases. Therefore, you should replace these usages with supported alternatives.

Example

Non-Compliant Example

begin
   sys.dbms_lock.sleep(1);
end;
/
Issues
LineColumnMessage
28sys.dbms_lock.sleep is deprecated.

Compliant Solution - ★★★★★

begin
   sys.dbms_session.sleep(1);
end;
/

Parameters

Use parameters to customize the rule to your needs.

ParameterDescriptionDefault Value
DeprecatedUnitsComma separated list of deprecated units (PL/SQL packages, package procedures, package functions and types).dbms_debug, dbms_job, dbms_xmlquery, dbms_xmlsave, ord_audio, ord_doc, ord_image, ord_video, dbms_lob.loadfromfile, dbms_utility.get_parameter_value, dbms_utility.analyze_part_object, dbms_xslprocessor.clob2file, dbms_xslprocessor.read2clob, dbms_audit_mgmt, dbms_lock.sleep, dbms_session.is_role_enabled

References