Skip to Content
0

HANA XSA: Using table functions in CDS Views

Jun 17, 2017 at 07:19 AM

160

avatar image

Dear Experts,

I would like to use a user defined table function in a cds view. But I will get a syntax error in CDS code editor.

Function definition:

FUNCTION "xyz.db.function::getUserClientIdsFromRoles" ( )    
RETURNS TABLE ( "Id"   NVARCHAR(10) )  
   LANGUAGE SQLSCRIPT SQL 
   SECURITY INVOKER               
AS 
BEGIN ..... END

View definition:

DEFINE VIEW UserClientView AS
           SELECT FROM "xyz.db.function::getUserClientIdsFromRoles"() 
           {
                Id AS "Client"
           };        

The WebIDE CDS Editor is showing an error in the view definition:

"CDS: error: Unexpected token "(""

Regards

Achim

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

1 Answer

Carl Soane
Jun 23, 2017 at 05:26 PM
0

Hello Achim:

I don't know what causes that problem, but I have alerted some colleagues on the WebIDE team to the problem you are seeing.

Regards,

Carl Soane

Share
10 |10000 characters needed characters left characters exceeded