Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

What will be the syntax in SQL Script and in CE functions while using tables or fields starting with '/' ?


I am trying to implement some basic aggregation using AMDP. My table starts with '/' and I also have fields starting with '/'.

I am using HANA Studio to implement this. I am getting t error message while using the '/' table name or field name. I have tried using single quotes ( ' ),

as well as double quotes ( " ).  Below is my sample code inside the AMDP method. Please suggest the syntax to use  these '/' table/fields.

method get_aggregate by database procedure

                     for hdb

                     language sqlscript

                     options read-only

                     using /BIC/AZCPOINSN00.

Here the studio doesn't throw any error. It picks up the table as such given in the 'using' option.

In the below statement, i get the following error.

"SQLSCRIPT message: Parameter must be a valid column table name: ZCL_AMDP_SALES_REPORT=>/BIC/AZCPOINSN00#covw"

result_tab = ce_column_table ("/BIC/AZCPOINSN00",["PLANT","/BIC/ZTOTLSTCK"]);

Note: /BIC/AZCPOINSN00 is a column stored table.

Without CE functions:

result_tab = select PLANT SUM(/BIC/ZTOTLSTCK) from "/BIC/AZCPOINSN00" group by PLANT;

I get the below error after SUM.

'SQLSCRIPT: sql syntax error: incorrect syntax near "("'

Thank you.

Former Member

Helpful Answer

Not what you were looking for? View more on this topic or Ask a question