It's all about the answers!

Ask a question

How to run report in RPE 2.1.1 that only has a dynamic query?


Robert Huet (23112884) | asked Jun 20 '17, 4:18 p.m.

Using the RPE Launcher, I can leave the URI blank and run a report template that only has a dynamic query.  However, the RPE remote services require a Connection and a URI in order to run, even if the template only references a dynamic query.

The reason I want to use the dynamic query is that the driving query returns work items that have been modified in the past week.  If I pass in the modified date as part of the RTC REST xpath query, then it has to be updated every time it is run.

Any suggestions?  I realize that I could use a JRS data source, but I need the real-time data, and I also need the work item history records with comments.

Thanks,
Robert

3 answers



permanent link
Kumaraswamy Gowda (39115) | answered Jun 21 '17, 3:38 a.m.

The better solution would be to hide the data source from being configured within the template itself.
- Open template in studio editor
- In outline view, select the data source
- In properties view, set "configuration need" to hidden.
- Save

If you switch to Launcher perspective, you should not see this data source for configuration.


Comments
Robert Huet commented Jun 21 '17, 2:54 p.m.

Under "configuration required", I set the property to "credentials", because I still need to pass the credentials from the launcher even though I don't need to supply a URI.  However, when I go to run from the RPE Web UI, I still cannot run the report without selecting a Connection.  And If I create a connection, I'm forced to provide a URI.


permanent link
Subramanya Prasad Pilar (4.6k16) | answered Jun 21 '17, 3:01 a.m.
edited Jun 21 '17, 3:03 a.m.

Unlike RPE Launcher, Document Builder does not allow document generation if URI is not specified (i.e., associated with a connection) for (any of) the datasources.
If you want to leave the URL blank in Document Builder, you can click "Edit Advanced Configuration" for the report and check "Hide" option for the datasource for which you do not want to specify the URI.


Comments
Subramanya Prasad Pilar commented Jun 21 '17, 6:11 a.m.

You can consider this solution if you do not wish to make any changes to RPE template.
If you are modifying the template, I would suggest using native filter to get only the work items modified in past week. You can use the same data source URL. Please refer sample template (under %rpe_home%\templates\RTC) for usage of native filters.


permanent link
Kumaraswamy Gowda (39115) | answered Jun 21 '17, 3:43 a.m.

>>> The reason I want to use the dynamic query is that the driving query returns work items that have been modified in the past week.  If I pass in the modified date as part of the RTC REST xpath query, then it has to be updated every time it is run.
You should be able to achieve it through javascript to calculate modified data as current date minus one week. The number one (week) could be a runtime variable for you to set it to different value like 2 or 3.

>>> Any suggestions?  I realize that I could use a JRS data source, but I need the real-time data, and I also need the work item history records with comments.
You could generate document for JRS report using RPE or with in JRS (6.0.4 and above). See
https://www.youtube.com/watch?v=lvqqPGvd408
https://www.youtube.com/watch?v=Mj9ktFzoRXQ


Comments
Robert Huet commented Jun 21 '17, 2:56 p.m.

So far, I'm thinking this is the only workable solution with the RPE Web UI.  I created a JRS query with a query of "SELECT SYSDATE from DUAL".  So I use this query as my parent query, but I don't use it in the template other than to pass on the credentials to the dynamic query.  This seems to work.
Thanks,
Robert

Your answer


Register or to post your answer.


Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.