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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

CE 10 - List of report

Status
Not open for further replies.

kutoose

Technical User
Sep 11, 2002
169
US
Hello !

I will like to query that will return me the list of reports in Crystal Enterprise, grouped by folders.

 
Hi,
You can use the Query Builder from the User launchpad to do that - it cannot be accessed by a standard Sql statement or a standard reporting tool, like CR.



[profile]

To Paraphrase:"The Help you get is proportional to the Help you give.."
 
I am looking for the syntax in query builder to get the list of reports grouped by folders
 
Hi,
Probably cannot - It is not a sophisticated report generator just a helpful utility..
You could try writing custom code ( using the InfoObject to connect ) and the syntax from the CE SDK Com docs..

If you do not have those search the Business Objects support site for:

ce10_com_docs_en.zip

The CE_SDK.chm file has a full Query Language Reference..




[profile]

To Paraphrase:"The Help you get is proportional to the Help you give.."
 
Hi,
Try the following code on an .asp page to list your reports by Folder Name:

Code:
<BODY>

<%

Const APS = "YourCMS"

Const UserID = "REadUser"

Const Password= "Pass"

Const Aut = "secEnterprise"

Function Logon(ByRef IStore)

    Dim SessionManager 
    Dim Result
    Result = FALSE
    Set SessionManager = Server.CreateObject("CrystalEnterprise.SessionMgr")
    If Err.Number = 0 then
        Dim Sess
        Set Sess = SessionManager.Logon(UserID, Password, APS, Aut)
        If Err.Number = 0 then 
          Set IStore = Sess.Service ("", "InfoStore")
          Set Session("IStore") = IStore
          Result = TRUE
        End If
    end if
   Logon = Result
End Function

Sub ShowReports(Rid,FolderName,IStore)
    Dim indx,Result3,Istr
    Response.Write("<Table><TH> Folder: " & FolderName & "</TH><TR>")
    Set Result3 = IStore.Query("Select SI_NAME, SI_ID, SI_DESCRIPTION From CI_INFOOBJECTS Where SI_PROGID='CrystalEnterprise.Report' And SI_INSTANCE=0 AND SI_PARENT_FOLDER=" & Rid & "ORDER BY SI_DESCRIPTION")
	  for indx = 1 to Result3.count
	    Response.Write("<TD>" & Result3.Item(indx).Title & "</TD><TR>")
	  Next
    Response.Write("</TR></TABLE>")
End Sub

Sub Main
   Dim IStore,Result2,FolderName
   Dim itm
   Logon IStore
   Set Result2 = IStore.Query("SELECT SI_ID, SI_NAME FROM CI_INFOOBJECTS WHERE SI_PROGID = 'CrystalEnterprise.Folder' ORDER BY SI_NAME")
   for itm = 1 to Result2.Count
    ShowReports Result2.Item(itm).ID, Result2.Item(itm).Title,IStore
   Next
  End Sub

Substitute your authentication info, of course, and see if it does what you need..You can also add additional info to be displayed for each report ( Like its ID)..





[profile]

To Paraphrase:"The Help you get is proportional to the Help you give.."
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top