Issue Details (XML | Word | Printable)

Key: CORE-5383
Type: Bug Bug
Status: Closed Closed
Resolution: Fixed
Priority: Critical Critical
Assignee: Adriano dos Santos Fernandes
Reporter: Rainer Hornung
Votes: 0
Watchers: 2
Operations

If you were logged in you would be able to see more operations.
Firebird Core

Dependencies in Package not recognised

Created: 27/Oct/16 07:34 AM   Updated: 29/Oct/16 10:38 AM
Component/s: Engine
Affects Version/s: 3.0.1
Fix Version/s: 3.0.2, 4.0 Alpha 1

QA Status: Done successfully


 Description  « Hide
Only the last package body procedure/function block is included for dependencies check.

CREATE TABLE T_NEW_TABLE_01 (NEW_FIELD_01 INTEGER NOT NULL, FIELD01 INTEGER);
ALTER TABLE T_NEW_TABLE_01 ADD CONSTRAINT PK_T_NEW_TABLE_01 PRIMARY KEY (NEW_FIELD_01);

CREATE TABLE T_NEW_TABLE_02 (NEW_FIELD_02 INTEGER NOT NULL, FIELD02 INTEGER);
ALTER TABLE T_NEW_TABLE_02 ADD CONSTRAINT PK_T_NEW_TABLE_02 PRIMARY KEY (NEW_FIELD_02);

CREATE TABLE T_NEW_TABLE_03 (NEW_FIELD_03 INTEGER NOT NULL, FIELD03 INTEGER);
ALTER TABLE T_NEW_TABLE_03 ADD CONSTRAINT PK_T_NEW_TABLE_03 PRIMARY KEY (NEW_FIELD_03);

CREATE package package_01
as
begin
 
end;

CREATE package body package_01
as
BEGIN
 PROCEDURE P01(iInput INTEGER) RETURNS (oOutput INTEGER)
 AS
 BEGIN
/* Dependencies is created for T_New_Tabel01 */
   SELECT NEW_FIELD_01 FROM T_NEW_TABLE_01 INTO :oOutput;
  END
END;

CREATE package package_02
as
begin
 
end;

CREATE package body package_02
as
BEGIN
 PROCEDURE P01(iInput INTEGER) RETURNS (oOutput INTEGER)
 AS
 BEGIN
   /* Dependencies is created for T_New_Tabel01 and T_New_Tabel02 and T_New_Tabel03 */
   SELECT NEW_FIELD_01 FROM T_NEW_TABLE_01 INTO :oOutput;
   SELECT NEW_FIELD_02 FROM T_NEW_TABLE_02 INTO :oOutput;
   SELECT NEW_FIELD_03 FROM T_NEW_TABLE_03 INTO :oOutput;
  END
END;

CREATE package package_03
as
begin
 
end;

CREATE package body package_03
as
BEGIN
 PROCEDURE P01(iInput INTEGER) RETURNS (oOutput INTEGER)
 AS
 BEGIN
   /*No Dependencies is created !!! */

   SELECT NEW_FIELD_01 FROM T_NEW_TABLE_01 INTO :oOutput;
  END

 PROCEDURE P02(iInput INTEGER) RETURNS (oOutput INTEGER)
 AS
 BEGIN
   /*No Dependencies is created !!! */
   SELECT NEW_FIELD_02 FROM T_NEW_TABLE_02 INTO :oOutput;
  END

 PROCEDURE P03(iInput INTEGER) RETURNS (oOutput INTEGER)
 AS
 BEGIN
   /* Dependencies is only created for T_New_Tabel03 */
   SELECT NEW_FIELD_03 FROM T_NEW_TABLE_03 INTO :oOutput;
  END

END;

CREATE package package_04
as
begin
   /*Package has no Dependencies, because last code block hat no table/procedure ... !!! */
 
end;

CREATE package body package_04
as
BEGIN
 PROCEDURE P01(iInput INTEGER) RETURNS (oOutput INTEGER)
 AS
 BEGIN
   /*No Dependencies is created !!! */
   SELECT NEW_FIELD_01 FROM T_NEW_TABLE_01 INTO :oOutput;
 END

 PROCEDURE P02(iInput INTEGER) RETURNS (oOutput INTEGER)
 AS
 BEGIN
   /*No Dependencies is created !!! */
   SELECT NEW_FIELD_02 FROM T_NEW_TABLE_02 INTO :oOutput;
 END

 PROCEDURE P03(iInput INTEGER) RETURNS (oOutput INTEGER)
 AS
 BEGIN
   /*No Dependencies is created !!! */
   SELECT NEW_FIELD_03 FROM T_NEW_TABLE_03 INTO :oOutput;
 END

 FUNCTION F_Add(Value1 Integer, Value2 Integer) RETURNS Integer AS
  BEGIN
   /*No Dependencies is created. Is Ok there is no Table etc. */
  RETURN :Value1 + Value2;
  END
END;
 

 All   Comments   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
There are no comments yet on this issue.