Error code |
F_JT04E8 |
Message |
Rename expression '<expression>' contained unrecognized substitution {hvr_<column>} |
Affected HVR function(s) |
Initialize/Capture/Integration/Refresh/Compare |
Operating System |
Windows/Linux/AIX/Solaris |
Replication Type |
Database to Database (DB2DB) / File to Database(F2DB) / Database to File (DB2F) / File to File (F2F) |
Error Type |
Internal |
Example
A channel containing Action → ColumnProperties /Name=seq_no /IntegrateExpression="select NVL(max(seq_no),0)+1 from {hvr_schema}.{hvr_tbl_base_name} where {emp_no}=emp_no"
fails during HVR Initialize or HVR Refresh with error:
F_JT04E8: Rename expression 'select NVL(max(seq_no),0)+1 from {hvr_schema}.{hvr_tbl_base_name} where customer_id={customer_id}' contained unrecognized substitution {hvr_schema}. Available substitutions: {hvr_integ_tstamp}, {hvr_integ_key}, {hvr_tbl_name}, {customer_id}, {customer_name}, {order_no}.
Explanation
HVR recognizes different types of expressions. There are SQL-based expressions and INLINE expressions.
-
SQL-based expressions are evaluated in the source or target database. These are SQL_PER_CYCLE, SQL_PER_ROW and SQL WHERE_ROW.
-
INLINE expressions are string-based replacements by HVR itself. This type is the only supported expression type for File Locations.
Not all substitutions are available for all expression types. The type or expression can explicitly be chosen for CaptureExpression (using /CaptureExpressionType), but for IntegrateExpressions the type is implied by:
-
The {} substitutions used in the expression. If all {} can be supported using an SQL type, the SQL type is preferred. If any of the substitutions is “INLINE only” the expression will be evaluated as an INLINE type.
-
The location class: for file locations only INLINE expressions are allowed
-
The mode of operation (bulk refresh or replication)
A consequence of using an “INLINE only” substitution is that these cannot be combined with SQL statements that need to be evaluated in the database.
For example. one can use:
/IntegrateExpression="select NVL(max(seq_no),0)+1 from tpcc.employee where emp_no={emp_no}"
But one cannot combine this with “INLINE only” substitutions like {hvr_schema} to create a more generic expression like:
/IntegrateExpression="select NVL(max(seq_no),0)+1 from {hvr_schema}.{hvr_tbl_base_name} where {hvr_key_names}={{hvr_key_names}}"
This expression will result in the following error:
F_JT04E8: Rename expression 'select NVL(max(seq_no),0)+1 from {hvr_schema}.{hvr_tbl_base_name} where customer_id={customer_id}' contained unrecognized substitution {hvr_schema}. Available substitutions: {hvr_integ_tstamp}, {hvr_integ_key}, {hvr_tbl_name}, {customer_id}, {customer_name}, {order_no}.
The following substitutions are always “INLINE only”:
-
{hvr_cap_tstamp} with a format specifier.
-
{hvr_integ_key}
-
{hvr_integ_seq}
-
{hvr_op}
-
{hvr_schema}
-
{hvr_tbl_name}
-
{hvr_tbl_basename}
-
{hvr_tx_scn}
-
{hvr_integ_tstamp}
The following substitutions are “INLINE only” during HVR Refresh, but not during Integration:
-
{hvr_tx_seq} - can be used, but it only has a proper value when HVR refresh -M option is used
-
{hvr_tx_countdown} can be used, but it only has a proper value when HVR refresh -M option is used
-
{hvr_cap_user} can can be used, but it will always have value UNKNOWN
-
{hvr_cap_loc}
Note that {hvr_cap_tstamp} is not available during refresh.
Conclusion
The substitutions marked as “INLINE only” should not be used in combination with integrate expressions that require SQL evaluation in the database.