Skip to content

fails when a grand child nested type have NULL #1098

Description

@hirerajan

Describe the bug
Lets say you have type of an object with three layers, i.e grand parent, parent and child type.
for example m_package_tab

m_package_obj( a varchar2(2), b number, t_parent_tab( p_ame varchar2(100), c_child_tab(name varchar2,age number)))

and lets say for our data, our child_tab we have null data,
and when you compare the data using following, you will get an error saying Fetched column value is NULL

ut.expect(anydata.convertcollection(l_package_tab)).to_equal(anydata.convertcollection(l_test_package_tab)).unordered;

OUTPUT:
ORA-01405: fetched column value is NULL
ORA-06512: at "UTP3.UT_DATA_VALUE_REFCURSOR", line 336
ORA-06512: at "SYS.DBMS_CRYPTO_FFI", line 159
ORA-06512: at "SYS.DBMS_CRYPTO", line 86
ORA-06512: at "UTP3.UT_UTILS", line 868
ORA-06512: at line 1
ORA-06512: at "UTP3.UT_DATA_VALUE_REFCURSOR", line 331
ORA-06512: at "UTP3.UT_DATA_VALUE_REFCURSOR", line 384
ORA-06512: at "UTP3.UT_DATA_VALUE_ANYDATA", line 129
ORA-06512: at "UTP3.UT_EQUAL", line 229
ORA-06512: at "UTP3.UT_EXPECTATION", line 26
ORA-06512: at "UTP3.UT_EXPECTATION_COMPOUND", line 146

Workout Around
ut.expect( xmltype( anydata.convertCollection(l_package_tab ) ).getClobVal() ).to_equal( xmltype(anydata.convertCollection(l_test_package_tab) ).getClobVal() );

There is also problem with workout Around as the order of the output does not match. I cannot use .unordered with perhaps three layer nested loop or with xmltype. Not sure why.

utPLSQL version : v3.1.10.3349

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions