You're almost there! Please answer a few more questions for access to the Applications content. Complete registration
Interested in joining? Complete your registration by providing Areas of Interest here. Register

how to fetch filter values in report for ROQL query

edited Dec 16, 2019 5:18PM in Reporting & Analytics for B2C Service 2 comments

Summary

fetch filter values in report for ROQL query

Content

Hi ,

Please help me. I need it urgent.

I am trying to fetch filter values from report to be used in Custom script for ROQL query filtering.

I used the following code in init tab 

 global $filters;

 $filters = print_r($params, true);

-------------------------------------------------

I used the following code in Process tab 

 

  $val1 = $params["search_args"]["search_field0"]["val"]; //dept
  $val2 = $params["search_args"]["search_field1"]["val"]; //Incident Type
  $val3 = $params["search_args"]["search_field2"]["val"]; //Form Type
  $val4 = $params["search_args"]["search_field3"]["val"]; // Created Date Range 

$query1 = "select count(*) cnt1 from CO.TagIncident T join T.TagIncidentID I where T.TagList.LookupName = '" . $rows[0][0]->val . "' and i.createdTime between date_add(sysdate(), " . $val1. " ,'day',1) and sysdate()  " ;

Howdy, Stranger!

Log In

To view full details, sign in.

Register

Don't have an account? Click here to get started!