Trusted Contributor.. Trusted Contributor..
Trusted Contributor..

I have a kind of weird issue with UCMDB DB Adapter


I am using DB Adapter to populate the CIs and Relationships into uCMDB through an sql query from oracle database. CIs and relationships are getting loaded as expected except in one case where I have an issue while loading relationships between two classes(Business application and a custom class under Ci Collection). The following error is being thrown while running the integration job and the job is getting failed.

Caused by: java.sql.SQLException: [mercury][Oracle JDBC Driver][Oracle]ORA-01747: invalid user.table.column, table.column, or column specification  

I found this weird because it is not happening every time. I could load relationships when I created sample data to test.

<entity name="business_application_containment_colr_ict_component" class="generic_db_adapter.business_application_containment_colr_ict_component">
<table name="(SELECT (CASE WHEN (business_rel.IUDN_FLAG = 'D') THEN 1 ELSE 0 END) COLR_SOFT_DELETE, business_rel.DATA_ORIGIN COLR_ORIGIN, LOWER (business_rel.DATA_EXTERNAL_ID_TO) || '_' || LOWER (business_rel.ROOT_CLASS_TO) CHILD_CI_ID, LOWER (business_rel.DATA_EXTERNAL_ID_FROM) || '_' || LOWER (business_rel.ROOT_CLASS_FROM) PARENT_CI_ID FROM test_schema.test_business_rel business_rel WHERE LOWER (business_rel.ROOT_CLASS_FROM) = 'businessapplication' AND LOWER (business_rel.ROOT_CLASS_TO) = 'colrictcomponent' AND LOWER (business_rel.RELATION_TYPE) = 'containment')"/>
<id name="id1">
<column updatable="false" insertable="false" name="CHILD_CI_ID"/>
<generated-value strategy="TABLE"/>
<id name="id2">
<column updatable="false" insertable="false" name="PARENT_CI_ID"/>
<generated-value strategy="TABLE"/>
<basic name="colr_soft_delete_rel">
<column updatable="false" insertable="false" name="COLR_SOFT_DELETE"/>
<basic name="data_origin">
<column updatable="false" insertable="false" name="COLR_ORIGIN"/>
<many-to-one target-entity="business_application" name="end1">
<join-column updatable="false" insertable="false" referenced-column-name="CI_ID" name="PARENT_CI_ID"/>
<many-to-one target-entity="colr_ict_component" name="end2">
<join-column updatable="false" insertable="false" referenced-column-name="CI_ID" name="CHILD_CI_ID"/>

colr_ict_component is the custom class I have created under CI Collection.

colr_soft_delete_rel is a custom relationship property to soft delete the relationship. It works fine for other relationships that are being loaded through DB Adapter.



Thanks in advance!

0 Replies
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.