on 03-09-2018 7:17 AM
Hi Friends,
I have written a stored procedure with tables from schema - "DEV" in my source hana system and the same tables are under a different schema "QAL" in target hana system.
I have to transport this stored procedure, how will this work?
For Ex :
I have written below statement in Stored procedure in Source HANA system:
select * from "DEV"."MARA"
However, in Target it has to become "QAL"."MARA" after transport.
Schema Mapping will not help in this scenario, Please help.
Thanks,
Gaurav
You are talking about a XS Classic Procedure?
Schema Mapping can be helpful here too. You have to set the DEFAULT SCHEMA in the procedure header to the authoring schema defined in the schema mapping. Within the body, you don't have to specify the schema name for the objects which should refer to the default schema. With that and the corresponding schema mapping on the Dev system, the select is applied to your DEV schema and on your Q system to your QAL schema.
Dummy coding for orientation:
PROCEDURE <procedure name> ( )
LANGUAGE SQLSCRIPT
SQL SECURITY INVOKER
DEFAULT <authoring schema name>
READS SQL DATA AS
BEGIN
lt_test = select * from "MARA";
END
Regards,
Florian
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
I'd suggest you to create a simple calculation view on MARA.
Then, in procedure, call that calculation view (it will be always "_SYS_BIC"."YOUR_CALCULATION_VIEW".
BR,
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
85 | |
10 | |
10 | |
9 | |
6 | |
6 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.