Skip to Main Content

SQL Developer for VS Code

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!

Interested in getting your voice heard by members of the Developer Marketing team at Oracle? Check out this post for AppDev or this post for AI focus group information.

version 24-4-0 december 2024 has broken compiling package when SET DEFINE OFF is included

GussayJan 10 2025 — edited Jan 10 2025

We store our code in .sql files. These can include DML, DDL and PACKAGE creation scripts.

We compile those PACKAGES in VS Code using F5 to run the file as a script.

Prior to Version 24.4.0 December 2024, I could compile packages that were stored in a file that were preceded by SET DEFINE OFF; and with SET DEFINE ON; at the end

We do not have a problem compiling files with PACKAGES that do not need SET DEFINE OFF; and SET DEFINE ON; included

Since Version 24.4.0 December 2024 (and it is still the same in Version 24.4.1 January 2025) I get errors in the script output

e.g.

Package Body XYZ.YYY when trying to compile

SET DEFINE OFF;
CREATE OR REPLACE PACKAGE BODY xyz.yyy
IS
FUNCTION zzz (pv_var1 IN VARCHAR2)
RETURN VARCHAR2
IS
    lv_date DATE;
    lv_boolean BOOLEAN DEFAULT FALSE;
BEGIN
… rest of package code

Produces the following SCRIPT OUTPUT when running via F5

Package Body XYZ.YYY compiled
Error starting at line : 16 in command -
lv_date DATE
Error report -
Unknown Command

Error starting at line : 17 in command -
lv_boolean BOOLEAN DEFAULT FALSE
Error report -
Unknown Command
Substitution cancelled

The file compiles OK when run from SQL Developer using @filepath/filename.sql

Comments
Post Details
Added on Jan 10 2025
7 comments
253 views