Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Retrieving report information from APS Store 1

Status
Not open for further replies.

cmmrfrds

Programmer
Feb 13, 2000
4,690
US
With the following query, I can retrieve all the instances of the report. I set up 3 recurring instances. From the query I can see 6 instances, 3 of which are runned instances. How do I identify the 3 recurring instances. Also, where do I find (what element contains) the directory that the report is in?

Query.
Dim str1 As String, str2 As String, str3 As String

str1 = str1 & "SELECT SI_PROCESSINFO, SI_FILES, SI_SCHEDULEINFO FROM CI_INFOOBJECTS "
str1 = str1 & "WHERE SI_NAME = 'AuditBVReport2.rpt' and SI_INSTANCE = 1 "

Thank you.
 
To get the recurring objects use "SI_RECURRING = 1" (true) in your where clause.

For the folder, that is the SI_PARENT_FOLDER value. Add it to your SELECT fields.



Chris
Data Intelligence Group
 
That worked perfect for the recurring=1. I added the si_parent_folder to the query, but I am not sure what element/object to find the folder in. I set up a loop of the results to get the following.
For indx = 1 To aResult.Count
Debug.Print " loop Title = "; aResult(indx).Title
Debug.Print " loop ID = "; aResult(indx).ID
Debug.Print " obj type = "; aResult.Item(indx).ObjectType
Debug.Print " parent id = "; aResult(indx).ParentID
Debug.Print " begin date = "; aResult.Item(indx).SchedulingInfo.BeginDate
Next '- end of for loop

I can't find the element for the folder. Do I need to use a plugin?
 
No plugin necessary. Just add it to the SELECT:

SELECT SI_PROCESSINFO, SI_PARENT_FOLDER FROM CI_INFOOBJECTS WHERE...etc,etc,etc...

This is not returning a value for you?



Chris
Data Intelligence Group
 
I did add it to the query like you show, but when going through the results I can't find the element name. Notice above when I looped through the results I found the element names for ID, BeginDate, Title, etc... but no folder name. I am doing this in VB code.

Thank you.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top