Quantcast
Channel: SCN : Discussion List - SAP HANA Developer Center
Viewing all articles
Browse latest Browse all 6412

Dynamic Parameters using SQL Script in a Calculation View

$
0
0

Hi there

I am trying to create a dynamic parameter(prompt) where I select a range of values in SQL Script within a Calculation View however I don’t see how it can be done, as it seems that the ‘Input Parameter’ feature with the SQL Script has very limited functionality. What is the workaround for such a situation.

Below is the SQL Script code within the Calculation View (CV) & the generated SQL when viewing the CV.

 

CalcView1.png

 

/********* Begin Procedure Script ************/

BEGIN

 

var_out =

SELECT

VKONT AS "CONTRACT_ACCOUNT",

GPART AS "BUSINESS_PARTNER",

VKBEZ AS "ACCOUNT_NAME"

--  E.VERTRAG AS "CONTRACT"

FROM  "CQ1_SLT"."FKKVKP" AS F

INNER JOIN "CQ1_SLT"."EVER" AS E

ON E.VKONTO = F.VKONT  

WHERE VKONT in CONTRACT_ACC --= '000502274809'

AND E.AUSZDAT = '99991231'

;

 

END /********* End Procedure Script ************/

 

Generated SQL:

SELECT TOP 200 "CONTRACT_ACCOUNT", "BUSINESS_PARTNER", "ACCOUNT_NAME"

FROM (SELECT "CONTRACT_ACCOUNT", "BUSINESS_PARTNER", "ACCOUNT_NAME"

FROM "_SYS_BIC"."coj/YAG8_NEW" ('PLACEHOLDER' = ('$$CONTRACT_ACC$$', '000502274809'))

GROUP BY "CONTRACT_ACCOUNT", "BUSINESS_PARTNER", "ACCOUNT_NAME") TMP

 

As always, your help is very much appreciated and welcomed.

Regards,

Thatoyame


Viewing all articles
Browse latest Browse all 6412

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>