Discussions
Categories
Choose a Product
THRUST SERVICES
CORE APPS
CE PRODUCTS
...
Quick Links
POPULAR
HELPFUL TIPS
Groups
My Links
FOR SIGNED IN MEMBERS:
Back to website
Home
Designing Analytics Reports
Runtime parameter issue
Migrateduser
Hi - I have the following query in my dataset.
=====================================================================================================
select ASSETID,ASSETURN,ASSETNAME,"ASSET-SOURCE-NAME" from erruser.RPT_CLASSIFIERS_36
WHERE "ASSET-SOURCE-NAME"='COMMON_LIB'
=====================================================================================================
And I am using the below scirpt in beforeopen for the same dataset, to pass runtime Library_Id value.
=====================================================================================================
//Here I am passing the table name in runtime
var id = new String(params["libraryID"]);
var name = new String(params["ASSET_SOURCE_NAME"]);
var num = id.substr(id.indexOf(':',0)+1,id.length);
query = new String(this.queryText);
query = query.replace(/(RPT_[a-zA-Z_]+)(\d+)/g,"$1"+num);
this.queryText = query;
=====================================================================================================
The above script is working fine as it is. But is I try to pass the 'ASSET-SOURCE-NAME' in run time I am facing issue. I tried with the following script ...
=====================================================================================================
//Here I am passing the table name in runtime
var id = new String(params["libraryID"]);
var name = new String(params["ASSET_SOURCE_NAME"]);
var num = id.substr(id.indexOf(':',0)+1,id.length);
query = new String(this.queryText);
query = query.replace((/(RPT_[a-zA-Z_]+)(\d+)/g,"$1"+num),(/'COMMON_LIB'/,'name');
this.queryText = query;
=====================================================================================================
Please help me with your suggestions and inputs.
Thanks,
AR
Find more posts tagged with
Comments
There are no comments yet