How to resolve the error "Unable to determine the type of the specified object. when bind child selector" when"adbDateTime" type is defined as a foreign key in the child table.
book
Article ID: KB0078629
calendar_today
Updated On:
Products
Versions
TIBCO ActiveMatrix BusinessWorks Plug-in for Database
7.x
Description
When adding child tables, it is required to designate a foreign key column to each child table so that a relationship to the parent table can be defined: 1) Select the User Key check box for the foreign key column in the child table. A key icon is displayed next to the column name. 2) Then specify the relationship between the primary column in the parent table and the foreign key column in the child table by clicking the "Join To" field of the child table column, and select the name of the parent table primary key column from the drop-down list. Then click "Apply" button.
When a column in parent table having adbDateTime datatype is defined as 'primary key' and is also having Join-To relationship to the child table, then TIBCO ActiveMatrix Adapter for Database throws below exception: ========= "com.tibco.adapter.adb.database.DBSQLException: java.sql.SQLException: [tibcosoftwareinc][Oracle JDBC Driver]Unable to determine the type of the specified object. when bind child selector". ========= This exception is caused by passing 'java.util.Date' into a prepared statement rather than a 'java.sql.Date'.TIBCO ActiveMatrix Adapter for Database is based on Java-based SDK and is using JDBC driver to connect to the database. It handles JDBC date/time/adbDateTime datatype by using AEType as "adbDateTime". As such, if a table has a column with adbDateTime datatype as key field then it can not be used to specify Join-To relationship between parent and child table. However, "adbDateTime" type is not a valid JDBC type.
Issue/Introduction
"com.tibco.adapter.adb.database.DBSQLException: java.sql.SQLException: [tibcosoftwareinc][Oracle JDBC Driver]Unable to determine the type of the specified object. when bind child selector" when parent-child relationship is specified in which a particular column of the parent table is having 'adbDateTime' datatype and it is also having Join-To relationship with the child table.
Environment
Product: TIBCO ActiveMatrix Adapter for Database
Version: 7.0 and above
OS: All Supported Operating Systems
Resolution
To resolve this exception remove the key field with an adbDateTime datatype from the Join to value of the Parent/Child table configuration of the publication service or can use the latest hotfix of TIBCO ActiveMatrix Adapter for Database 7.2.0.