Hello Javier,
for that scenario you can use the SAP HANA Application Accelerator AddOn for ERP (aka SWT2DB). This AddOn gives you the option to configure per program if the data should be select via your HANA secondary database connection.
Note 1694697 contains a guide for the tool (it is attached to the note). Consider also note 1696402regarding the prerequisites.
Best Regards,
Florian