Quantcast
Channel: SCN : Blog List - SAP LT Replication Server
Viewing all articles
Browse latest Browse all 38

How to replicate data from an Oracle table which has a long field

$
0
0

When using SLT to replicate data from Oracle DB to HANA, you might see SQL error 932 occurred on a specific table and the initial load was failed.
The reason is that you have defined a long field in the table, e.g. VARCHAR(2000).
Following is an example of the problem and the workaround.

 

  • We create table SLT_DEMO with 3 long fields - BBB, CCC and DDD, and insert 2 records into it as below.
    capture1.png
  • We start to load the table in SLT.
    capture2.png
    However the load failed. We can see SQL error 932 below in tag "Application Log" or by clicking "View Errors" button.
    capture3.png
    capture4.png
    We also can see the following shortdump occurred in ST22.
    capture5.png
  • Now let's check the proxy table of SLT_DEMO.
    You can see the data type of CCC and DDD were converted to "STRING" which should be "CHAR".
    However BBB was converted to "CHAR" correctly.
    capture6.png
    Data type "STRING" is for "LONG" and "CLOB", so when SLT tried to read data from SLT_DEMO on the source DB, it hoped field CCC and DDD should be "LONG" or "CLOB".
    However it found the data type of CCC and DDD were"VARCHAR", then error "inconsistent datatype" occurred.
  • We can use table IUUC_DB_COL_TYPE to specify the data type of a field in SLT as below.
    We need to stop the load and add 2 records in table IUUC_DB_COL_TYPE for CCC and DDD in SE11.
    capture7.png
    We need to specify the values as below.
    capture8.png
    Field "DBCON NAME" and "DB SCHEMA" can be found in tag "Administration Data" in LTRC.
    capture9.png
    Now we have 2 convert rules in table IUUC_DB_COL_TYPE.
    capture10.png
  • Let's start the load in LTRC again.
    You can see the data was loaded without any problem.
    capture11.png
    capture12.png

 

We do not have a plan to enhance this functionality at the moment and the design may change, so there is no Note or KBA to introduce the workaround.
If you have the same problem, you have to refer to this blog.


Viewing all articles
Browse latest Browse all 38

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>