Forum Discussion
raji
9 years agoRegular Visitor
user parameter in dynamic query
Hello! I'm trying to pass the value of a parameter to my dynamic query statement so that I can limit the dataset on the source db (dealing with extremely large data). I tried the following......
v-micsh-msft
9 years agoMicrosoft Employee
Hi raji,
Currently I don't think this could be done under Report level with users.
Query Parameter is available ehn query the data, not after the query. If we would like to filter the report, we could add the slicer Visual. Which user could be able to select in Reports:
Regards
ozmike
9 years agoResolver I
Here is an example using a HANA database , with working syntax
enjoy. Note you must use the internal SAP hana column names , the column displayed in PBI are "labels" and may have spaces in them or be completely different to the actual sap columns
let
xx = "0000610127",
sel = "select ""ColumnName"" from ""ZXXX.XXX::TABLE"" where ""ColumnName"" = '" & xx & "' ",
Source = SapHana.Database("Server:12345", [Query=sel])
in
Source