Access violation in 64 bit

Discussion of open issues, suggestions and bugs regarding ODAC (Oracle Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
jdorlon
Posts: 202
Joined: Fri 05 Jan 2007 22:07

Access violation in 64 bit

Post by jdorlon » Wed 25 Mar 2020 16:35

Hello,

Using
Delphi Rad Studio 10.1 Berlin,
Compiling 64 bit WIndows. The error does NOT occur in 32 bit.
ODAC version 11.1.3

If I create these objects in an Oracle database (server or client version does not seem to matter. I tested in 19c and 12c release 2.)

Code: Select all

drop type type_level1;
drop type type_level2;

CREATE OR REPLACE TYPE TYPE_LEVEL2 AS Object
( a_number number,
  a_varchar2 varchar2(40),
  CONSTRUCTOR FUNCTION TYPE_LEVEL2 RETURN SELF AS RESULT
 );
/

CREATE OR REPLACE TYPE BODY TYPE_LEVEL2 IS
  CONSTRUCTOR FUNCTION TYPE_LEVEL2
  RETURN SELF AS RESULT
  IS
  BEGIN
    RETURN;
  END TYPE_LEVEL2;
END;
/

CREATE OR REPLACE TYPE TYPE_LEVEL1 AS Object
( a_number number,
  b_number number,
  a_type_level2 type_level2,
  CONSTRUCTOR FUNCTION TYPE_LEVEL1 RETURN SELF AS RESULT
)
/

CREATE OR REPLACE TYPE BODY TYPE_LEVEL1 IS
  CONSTRUCTOR FUNCTION TYPE_LEVEL1
  RETURN SELF AS RESULT
  IS
  BEGIN
    self.a_type_level2 := type_level2(0, null);
    RETURN;
  END TYPE_LEVEL1;
END;
/
Then run this SQL in a TSmartQuery, I get an access violation. If I use a NULL instead of 'a', there is no error.

Code: Select all

SELECT TYPE_LEVEL1(890480363, 
                   888445111,
                   type_level2(1, 'a')
                  )  
from dual;
Last edited by jdorlon on Fri 27 Mar 2020 15:44, edited 2 times in total.

MaximG
Devart Team
Posts: 1822
Joined: Mon 06 Jul 2015 11:34

Re: Access violation in 64 bit

Post by MaximG » Wed 01 Apr 2020 08:21

Thank you for the information. We have reproduced the issue and will investigate its origin. We will inform you about the results shortly.

Post Reply