on 08-23-2018 2:33 PM
Hi experts,
1. I want to use a decision table, but I'm modelling with the Web Based Development Workbench. I did not find any way to create one. Is there any?
2. Is there a possibility to create UDF table functions in the Web Based Development Workbench. Is it possible by the .hdbtablefunction or even by CDS?
3. I want to pass a two values into a procedure within a graphical calc view and return the output of the procedure as column. Is there any way?
Thanks and best regards
Johannes
1. I would not suggest the use of decision tables. They are obsolete and don't cover to HDI/XSA which you eventually must move to.
2. You can create table functions with HDBTABLEFUNCTION in the old Repository.
3. You can use a table function (procedure) as a data source in a Calculation View.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Thomas,
thanks for your answers. A few questions arise:
1. How can I avoid it. Yes, I can create a calculated column, if I dont have many criterias, but how to handle it, if I have a lot of rows in my decision table. Is there any to go if I have a large decision datasets?
To be precise I want to decide based on the name, a MaxValue and a minValue and return a specific column of the reference table.
My thought was to do this with the help of a table function in the view. With your tips 2/3 I have created the function and it works properly in Catalog. How can I now pass a specific column of a Projection as input parameter for this function and how can I use the output in the graphical view?
There is no possibility to create a connection from the projection to the table function in graphical view.
Thanks and best regards
Johannes
1. I would suggest probably a table function if possible.
2. When you add the table function as a data source in the view, you have the option to map into the parameters of the table function.
>There is no possibility to create a connection from the projection to the table function in graphical view.
What kind of node are you trying to use. Most likely you need a join or union. Also what release of HANA. The ability to use a table function in a Calculation View is relatively recent.
Hi,
We are using 1.00.122.16.1520578817.
the problem I have with that is, that there are no parameters shown and also no output columns of the table function.
This is the code of the hdbtablefunction:
FUNCTION "<Schema>"."<Name>" (
-- parameters input --
IN messagePriority varchar(15),
IN age integer
)
RETURNS table("flag" varchar(15), "priority" varchar(15))
LANGUAGE SQLSCRIPT
SQL SECURITY INVOKER
--DEFAULT SCHEMA <default_schema_name>
READS SQL DATA AS
BEGIN
return (SELECT "flag", "priority" FROM "<Table>"
WHERE "priority" = messagePriority
AND age >= "minValue"
AND age <= "maxValue");
END;<br>
When I add it as datasource, there are not output columns and no parameters shown.
Its completly strange, because I created a new calc view, there i had the parameters but no output column. I deleted that one again and now there is neither of both.
Thank you.
Best regards
Johannes
User | Count |
---|---|
90 | |
10 | |
10 | |
10 | |
7 | |
7 | |
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.