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

ROQL query on Profile table in report

Received Response
60
Views
12
Comments
edited Dec 10, 2018 2:43PM in Integrations and APIs 12 comments

Content

Hi there.

I'm trying to get a ROQL query on the Profile table in a report.
I found the following documentation

The following example shows a ROQL query on the Profile managed table:
SELECT * FROM Profile; DESCRIBE Profile;

I tried the following custom script inside a report (report also attached)

Initialisation
require_once(get_cfg_var('doc_root')."/ConnectPHP/Connect_init.php");
initConnectAPI();
 

Process
$profile_id = $rows[0][0]->val;

//build the ROQL query using the profile id
$query = "SELECT P.CreatedTime FROM Profile P WHERE P.ID=".$profile_id;

//run the query
$query_results = RightNow\Connect\v1_2\ROQL::query($query)->next();

Tagged:

Howdy, Stranger!

Log In

To view full details, sign in.

Register

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