cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Table name with special character '/' in from clause of select query of AMDP procedure.

avinashd_m
Participant
0 Kudos
3,143

Hi All,

I have created AMDP procedure and trying to consume in AMDP class which is implementing  the required AMDP interface and everything is working fine, but  in my procedure i am trying to use one table name (which has special character '/' in it) which is giving an error.

Please find my procedure as follows:

      METHOD my_hana_procedure by database procedure

      for hdb

      language sqlscript

      options read-only.

      using /CPD/D_PFP_TEST.

               table = select  * from  /CPD/D_PFP_TEST;  /*------ Here i will get an error saying SQL SCRIPT : &a0&a1&a3&a4.......&a9   */


     ENDMETHOD.

Note: The above mentioned table /CPD/D_PFP_TEST is in system SID schema.

FYI, If i am using any table which do not contains special character '/' in it will work without any error.

Did anyone faced the same issue?, at least here error information should be meaning full we can correct our errors inside AMDP procedures.

Thanks in advance,

Avinash

Accepted Solutions (0)

Answers (2)

Answers (2)

avinashd_m
Participant
0 Kudos

Hi All,

Issue got resolved.

I have tested same code block of the procedure in SAP HANA studio 1.1.1 with the same user  with double quote for the table name in select query(which was not working initilally with SAP hana 2.1.3), not sure issue was not occurring in 1.1.1 version, later again i checked same in my version of SAP hana studio 2.1.3, it worked surprisingly, not sure what could be the issue.

Thanks for all the suggesion.

Avinash

pfefferf
Active Contributor
0 Kudos

Hello Avinash,

you have to enclose your table name by double quotes in the body of the procedure (table = select * from "/CPD/D_PFP_TEST";).

Regards,

Florian

avinashd_m
Participant
0 Kudos

Hi Florian,

Thanks for the suggestion.

I have tried enclosing the table name with double quotes in select query, but issue still persist.

just to add here other table like MARA,COSP etc it is working fine without any double quotes.

Thanks,

Avinash

pfefferf
Active Contributor
0 Kudos

Can you show a screenhot of your coding and the exact error message?

avinashd_m
Participant
0 Kudos

Hi Florian,


Please find a screenshot for the proper error and procedure information.



Thanks,

Avinash

pfefferf
Active Contributor
0 Kudos

Ok, the message looks strange . Seems to be an issue of either the dev-tools or the background service. Are you using the latest ABAP Dev Tools? Which NW system version and Kernel you are using?

Regarding your coding, you need the double quotes. If you then still get the error, there must be still something else wrong. Is "Prices" an export parameter and does it match the structure of the table?

avinashd_m
Participant
0 Kudos

Hi Florian,

1. With double quotes also i am facing same issue as i explained in earlier reply.

2. Here in the procedure "Prices" is not any importing /exporting paramter FYI, and i believe "Prices" does'nt  need any declaration as it is automatically get the structure of the data that we are going to assign. I am able to confirm this statement because after activating the class with the usage of  MARA or COSP tables in procedure , at debug i can see variable "Prices" is hoilding data with the structure of corresponding assigned result from the select quey.

3. The related system NW version is 750, SP 0 and Kernel release is 745.

4. For ABAP Dev tools version, please have a look into the following snapshot.

Thanks,

Avinash