Skip to Content
Author's profile photo Javier Martin

Replicating data to HANA using SAP Sybase Replication Server

     As most of you already know Real Time Data Platform (RTDP) consists on several SAP software products that will enable extreme data management capabilities in your company and both HANA and SAP Sybase Replication Server are included in it. SAP Sybase Replication Server version 15.7.1 SP100 is general available in June 2013 and this is the first version including support for data replication to HANA, it is important to remark that at the moment it is only certified with non-SAP applications, certification for SAP applications will come with next SAP Sybase Replication Server release in the near future.


     In today’s post I am going to describe the architecture for data replication to HANA using SAP Sybase Replication Server, explaining some specific details to take into account and I will also show how to configure data replication to HANA with a “how to” video.

Architecture for data replication to HANA


      Points to remark in this architecture:

    • Primary DB can be any SAP Sybase Replication Server primary supported DBMS (ASE, Oracle, MSSQL and DB2/UDB)
    • A new connector called ECH (Express Connect for HANA) has been implemented similar to the one we have for Oracle (ECO). ECH establishes a direct
    • Interesting SAP Sybase Replication Server functionalities can be used with HANA:
      • Multipath replication supported from ASE and Oracle
      • Supports function string customization
      • Supports Multiple Site Availabitily
      • New materialization method called  “Direct load” (no materialization queues created so best performance)
      • HVAR replication (Advanced Service Options license required)

ECH connector properties

  • This new connector accesses SAP HANA instance via SAP HANA odbc driver
  • ECH consists in 2 dynamic libraries shipped with SAP Sybase Replication Server (libsybhdb and libsybhdbodbc) that are linked with SAP HANA odbc driver (libodbcHDB)
  • SAP HANA odbc driver is not shipped with SAP Sybase Replication Server, you have to download and install it yourself
  • ECH works in a similar way than the connector for Oracle (ECO) and using it we avoid the need of a gateway/middleware that would impact performance
  • ECH is integrated both with SAP Sybase Replication Server interfaces file and with hdbuserstore utility in HANA client. This means that you can add an entry for the HANA instance in SAP Sybase Replication Server interfaces file or use hdbuserstore HANA client utility to create a KEY (HANA instance) specifiying HANA instance name, host, port, user name and password so that SAP Sybase Replication Server can access HANA instance bypassing interfaces file and using the hdbuserstore KEY
  • Direct load materialization support for HANA, no need to use materialization queues (this requires Rep Agent 15.7.1 SP100)

          Configuring replication from ASE to HANA

      In the “how to” video below I go through the steps for establishing a replication system replication from ASE to HANA using SAP Sybase Replication Server.


    1. Create the connection to primary ASE database (rs_init)
    2. Create the connection to the HANA database (manually with create connection command). Note that: connection has to be created using profile rs_ase_to_hanadb;ech
    3. Create table at primary ASE database and mark it
    4. Create table at replicate HANA database
    5. Create replication definition
    6. Create subscription

     I hope this post can be useful to anyone who wants to start replicating to SAP HANA using SAP Sybase Replication Server system. More interesting discussions on the topic of heterogeneous replication and data replication techniques will be described in upcoming blog posts.

More details in SAP Sybase documentation:


Other/Related Posts:

Assigned Tags

      You must be Logged on to comment or reply to a post.
      Author's profile photo Andy Silvey
      Andy Silvey

      Hi Javier,

      very nice informative blog.

      Thank you.


      Author's profile photo Javier Martin
      Javier Martin
      Blog Post Author

      Hi Andy,

      Glad to see you find it useful.



      Author's profile photo Robert LIGHTFOOT
      Robert LIGHTFOOT

      Hi Javier,

      I noticed you were loading into a ROW table in HANA. I assume that there is no issues loading into a columnar table?

      Great blog btw 🙂



      Author's profile photo Javier Martin
      Javier Martin
      Blog Post Author

          Hi Rob,

          It will work no matter if it is a a row or column table, you have to think about Sybase Replication Server executing inserts/updates/deletes as any other client.

          Regards and thansk.


      Author's profile photo Angeles Criado
      Angeles Criado

      Hi Javier,

        a really useful article. I am looking forward to see your next topic.

      Thank you very much,


      Author's profile photo Mark Terry
      Mark Terry


      Great article.  Where can I learn support details for supporting SAP applications - when, what versions, pre-requisites, etc.?



      Author's profile photo Javier Martin
      Javier Martin
      Blog Post Author

          Hi  Mark,

          At the moment the only info I have is that replication from BS to HANA using SRS is planned for Q1 2014. As far as I understand BS should run in any primary DBMS supported by SRS. I don't find any official page to check this, I suggest you to follow PAM (Product Availability Matrix) in marketplace just in case some info appears there.


      Author's profile photo Michal Krawczyk
      Michal Krawczyk

      hi Javier,

      would you have any updates for ECH certified with SAP applications ? Would it be possible that ECH in new version can call a BAPI or enterprise service to be able to create a transaction from a replicated data ? Or will it always need something in between (like SAP PO, SAP Data Services, or ABAP program) to call BAPIs after replication ?

      Thank you,


      Michal Krawczyk

      Author's profile photo Former Member
      Former Member

      Hi Javier,

      Any idea if SAP will release either a developer or subscription-priced version of Sybase Replication Server that developers could use for building "side-car" prototypes on smaller systems (i.e. HANA on AWS)?



      Author's profile photo Former Member
      Former Member

      Hi Javier

           I have encountered a problem when configuring replication from oracle to SAP HANA using Sybase Replication Server:

      create subscription tsttab_sub

      for ra$pds_orcl_orcl4RS_OUTLN_TSTTAB

      with replicate at hana_server_tst.hana_tst

      without holdlock


      user pds_user password mypasswd

      when i try to create subscription using above code, it run to error:

      2014/02/13 11:03:08. ERROR #1027 SUB(tsttab_sub) - seful\cm.c(6030)

      Open Client Client-Library error: Error: 84083974, Severity 5 -- 'ct_connect(): network packet layer: internal net library error: Net-Library operation terminated due to disconnect'.

      E. 2014/02/13 11:03:08. ERROR #13045 SUB(tsttab_sub) - seful\cm.c(6035)

      Failed to connect to server 'pds_orcl' as user 'PDS_USER'. See CT-Lib and/or server error messages for more information.

      I. 2014/02/13 11:03:08. Trying to connect to server 'pds_orcl' as user 'PDS_USER' ......

      Could you please give me some help, thanks in advance.

      Author's profile photo Javier Martin
      Javier Martin
      Blog Post Author

      Hi Leo,

        For direct load materialization for non ASE sources SRS connects to the REP agent to extrac the data, check this link below:

        From the error I can see here you can have problem connecting from SRS to Rep Agent or maybe Rep agent to primary Oracle server. I suggest you to check Rep Agent log to see if you find extra info there.

        Note: remeber not to use same user at primary oracle for the Rep Agent user and the repserver user when you create the connection.



      Author's profile photo Former Member
      Former Member

      Hi Javier

           Thanks for your reply. There's no error message in Rep Agent log. And both the test_connection PDS and test_connection RS succeed.

           As described in guide, the Rep server connects to Rep Agent for non-ASE database, however, the pds_orcl points to primary oracle database, why did the Rep Server connects to primary database instead of Rep Agent, or this connection require is not sent by Rep Server ?

      Author's profile photo Former Member
      Former Member


      Could any one please provide the step by step configuration for sybase replication server for oracle.

      I have to configure the setup from source Oracle database to SAP Hana target database using Sybase replication server.

      Author's profile photo Javier Martin
      Javier Martin
      Blog Post Author

      Take a look at:

      Data Replication Architecture for Integrating Heterogeneous Systems with Oracle Databases

      You can use that post to configure Oracle as primary DB and this one for HANA as replicate DB.


      Author's profile photo Former Member
      Former Member

      Hi Javier,

      Thanks for your quick response.

      Initial setup has been completed successfully. Connection from Replication server to Source(Oracle) and Target (Hana DB) is working fine. I can see that the tables RS_tables on source database and target database. but the problem here is the data is not replicating from source to target. I can't see any errors in replication server log or agent log.



      Author's profile photo William Echevarria
      William Echevarria

      Thanks Javier!  Followed your demo and worked like a charm!  The only tidbit to add is make sure the C:\Program Files\SAP\hdbclient  directory is in your environment path before starting REPSERVER.

      Author's profile photo Agustin Adolfo Calderon Coronado
      Agustin Adolfo Calderon Coronado

      I'm getting this message, it's like a SYSAM issue

      I. 2014/11/29 00:06:43. SySAM: For further information, refer to the Sybase Software Asset Management website at

      T. 2014/11/29 00:06:43. (17): No permission to produce connector for unlicensed feature [REP_EC_HANA].

      E. 2014/11/29 00:06:43. ERROR #13113 DSI(105 HANA_PRO.RS_USER) - \generic\useful\cm.c(5217)

              Failed to obtain a reference to the indicated Connector. See messages from Connector factory for details. Data server make: hdb. Connector type: odbc. Data server: HANA_PRO. Database: RS_USER.

      I. 2014/11/29 00:06:43. No Sybase library information is available.

      I. 2014/11/29 00:06:43. The DSI thread for database 'HANA_PRO.RS_USER' is shutdown.

      Author's profile photo Javier Martin
      Javier Martin
      Blog Post Author

        Do you have a valid license ?. Take a look at your .lic license files under $SYBASE/SYSAM_2-0/licenses and be sure you have an express connect for Hana license. Check this out:

      Component Licensing
      Replication Agent A SySAM served or unserved license                            obtained from the                            Sybase                            Product Download Center (SPDC) or Service Marketplace (SMP) is                            required.
      ECH ExpressConnect                                for SAP HANA database is installed with SAP Replication Server.                                There is no separate installer for ExpressConnect for SAP HANA                                database. For replication to SAP HANA database, use the license key                                that you generate for your product during installation:

      • SAP Replication                                        Server, option for SAP HANA, or
      • SAP Replication Server, SAP HANA                                        edition

      See SAP Replication Server Quick Start                                    Guide for SAP HANA Database.


      Author's profile photo Former Member
      Former Member

      Hi Javier,

      I have followed all the instructions in your video and configured the primary and target connections. I am using Rep Server to replicate from ASE to HANA.

      When inserting a record into ASE, my DSI thread for HANA is suspended.

      I. 2015/05/13 16:36:20. The DSI thread for database 'MDS.rdb' is started.
      I. 2015/05/13 16:36:21. Message from server: Message: -1, State 0, Severity 5 -- '[ statement ][ MDS ] SQLPrepare [SAP AG][LIBODBCHDB SO][HDBODBC] General error;287 cannot insert NULL or update to NULL: IDNO'.
      H. 2015/05/13 16:36:21. THREAD FATAL ERROR #5049 DSI EXEC(104(1) MDS.rdb) - dsiqmint.c(4723)
              The DSI thread for database 'MDS.rdb' is being shutdown. DSI received data server error #-1 which is mapped to STOP_REPLICATION. See logged data server errors for more information. The data server error was caused by output command #0 mapped from input command #0 of the failed transaction.
      E. 2015/05/13 16:36:21. ERROR #5024 DSI EXEC(104(1) MDS.rdb) - /dsiutil.c(8308)
              The database with siteid '0 ' does not exist in the rs_databases system table. It is not known to this Replication Server.
      I. 2015/05/13 16:36:21. The DSI thread for database 'MDS.rdb' is shutdown.

      The inserted record in ASE is:

      insert into ptab1 values (1,'Asif Arif')

      I cannot quite work out where the issue is.

      Any suggestions?



      Author's profile photo Javier Martin
      Javier Martin
      Blog Post Author

        I have seen similar problems before when servers were configured case sensitive and name for columns in tables are not identical to name of columns in replication definitions, can this be your case ?. A good idea could be activate dsi_buf_dump trace in repserver and check SRS errorlog to see what it is exactly sending to HANA. If you need further help please send me a email and once we narrow the problem down we can summarize here.

         Good luck.

      Author's profile photo Eisen Wang
      Eisen Wang

      Hi Javier,


      Thanks for your great post here... And just one more question -- if I need to configure the Replication from Hana to Hana -- then when I run "create connection" to the target Hana -- which profile I should use -- the "admin show_connection_profiles" shows no profile for Hana to Hana.

      I've configured one SRS from Oracle to Hana, using profile of "rs_oracle_to_hanadb;ech".

      But which one should be Hana to Hana?

      Please kind help. Thanks





      Author's profile photo Javier Martin
      Javier Martin
      Blog Post Author

      HI Eisen, Hana is not supported as source with Replicatoin Server,  you have add a Hana database so a Repliation Server system only as target.




      Author's profile photo Subodh Singh
      Subodh Singh

      Hello Javier,

      Thank you for sharing the article.

      With this architecture, can it be assumed that replicate HANA Data server can also act as DR site.

      If yes, then after the failover to DR site, can SAP Application connect with HANA.?