Oracle BI EE 10.1.3.4.1 – Catalog Manager Command Line Options

June 23rd, 2010 by Venkatakrishnan J

One of the common drawbacks with BI EE currently is the inability to use any automated scripting methods to add users/groups/folders/reports to the web catalog. Following are the possible ways to add/create new groups, create new folders, copying reports etc

1. Use Catalog Manager to do all the above

2. Use of Web Services – This method works well. But the biggest problem with this is, we will have to establish a session with the BI Server. But the tasks like Creating new folders, copying reports etc are Web Catalog specific actions which ideally should not require/mandate creation of BI Server sessions. This is where a stateless Java API will be very handy.

3. Do the process of moving reports/dashboards through the Web Catalog UI within BI EE

The most preferred approach is the first option. But so far there was no way of scripting these using Catalog Manager since it does not have a set of documented command line options. I am not sure how or why Oracle missed this important piece of information in the docs but again i thought it was worthwhile for people to know the various command line options that are available(yes Catalog Manager supports command line options). I found this out hidden in the java source codes while trying to build an automated utility for Web Catalog Auditing (more on that in a future blog entry). The set of command line options available are comprehensive. Some of them are experimental (yes there is an experimental command line switch) and some of them work really well. Had only Oracle released the Catalog Manager for Linux platforms as well, this would have become even more beneficial.

The general syntax for doing operations without opening up the catalog manager is given below

catalogmanager –online/offline
<URL/Full WebCatalog Path>
–cmd {report | replace | export}
{command line options}

For example, to open up the catalog in online mode, the following command needs to be executed

catalogmanager –online

http://localhost:9704/analytics/saw.dll

–login Administrator –pwd Administrator

This will automatically open up the catalogmanager without having the need to enter the connection details everytime. To open in offline mode, the command is

catalogmanager –offline C:\\Oracle\\OracleBIData\\web\\catalog\\samplesales

The most common requirement is to export the Catalog Reports automatically through a script. That can be done using the syntax below

catalogmanager -online

http://localhost:9704/analytics/saw.dll

-login Administrator -pwd Administrator
-cmd report
-of c:\\report.txt
-delimiter \",\" -type
Requests \”Request Name\” \"Request Criteria Column\"

This will automatically export all the Requests and their corresponding Request Columns into a comma de-limited text file

Picture 1

There are some experimental options as well. The general syntax to try experimental options is given below

catalogmanager
–online/offline <Login Option>
–expermimental –cmd { archive | unarchive | diff |
merge | renameAccount | forgetAccount | createAccount |
joinGroup | leaveGroup | getGroups | getMembers | belongs}

The typo in the syntax above was deliberate. Somehow the code seems to take -expermimental switch instead of –experimental(probably a mistake by a developer). But as the name suggests, i would recommend everyone to test this completely as some of the options have not been tested by oracle(probably the reason why this is not documented). But the export options, report options etc should work out of the box without any issues.

I will try to follow this up with a comprehensive syntax list. In the mean time, if you do face issues in using the above command line options, leave a comment here i should be able to verify the correctness of the syntax directly in the java source.

Comments

  1. rnm1978 Says:

    Great find venkat!

  2. John Minkjan Says:

    Sweet.. ;-)

    Regards

    John

  3. @lex Says:

    Venkat, you did it again! ;-)

    Cheers

    @lex

  4. Gerry Langton Says:

    Brilliant post! I was recently asked if it was possible to produce an impact analysis based on sub-query filter requests. I.e. which requests reference a particular query in their advanced filter. Any ideas if this is possible using catalog manager functionality?

  5. Sid Says:

    Good one, Venkat!!!

  6. rnm1978 Says:

    Hey Venkat,
    Is there any way to get diagnostics / error output from these commands?
    I’m trying to use -cmd report but getting no file written, and no error. catalogmanager.exe fires up and uses CPU for about 10 seconds, and then exits.
    thanks.

  7. Venkatakrishnan J Says:

    @Robin – Unfortunately there is no error logging parameter that is available. Ideally the catalogmanager should not fire up (only in background) when we use the command line options. If it fires up then probably the command we used is wrong. Can you paste the command that you are trying to use? I will test it out.

    If you do see CPU usage, you will notice that the output file will be created after some time. In my case, depending on the size of the web catalog, it took anywhere between 2 to 4 mins. But should work. Also try to use this in offline mode as much as possible.

    -Venkat

  8. Hasso Says:

    Hi,

    Any updates on the syntax list yet?
    And how about this Web Catlog Auditing Util: what’s the idea?

    Thanks.

  9. DaveAtCornell Says:

    I was very happy to learn that there is indeed a commandline option for Catalog Manager, but like rnm1978, I could not get any results or even error messages.
    Then I discovered the “magic formula”: simply redirect standard output to a file, and standard error to standard out. Thus,

    catalogmanager -help > catmgr_help.txt 2>&1

    writes usage information to file catmgr_help.txt, and yields:

    ———————————————-
    Overview:
    catalogmanager -offline -cmd ( report | replace | export ) { command options }

    -cmd report
    catalogmanager -offline -cmd report -of [-delimiter ] [-distinct] [-folder ] -type Requests { }
    where must be one or more of
    “Created Time”, “Last Accessed Time”, “Last Modified Time”, “Owner”,
    “Request Criteria Column”, “Request Criteria Formula”, “Request Criteria Table”,
    “Request Description”, “Request Folder”, “Request Name”, “Request Path”,
    “Request XML”, “Request Subject Area”, “Request SQL”
    Example: catalogmanager -offline c:\oraclebi\data\web\catalog\paint -cmd report -of c:\temp\report.txt -delimiter ” ” -type Requests “Request Criteria Column” “Request Criteria Table”

    catalomganager -offline -cmd report -of [-delimiter ] [-distinct] [-folder ] -type Dashboards { }
    where must be one or more of
    “Dashboard Created Time”, “Dashboard Last Accessed Time”, “Dashboard Last Modified Time”,
    “Dashboard Name”, “Dashboard Path”, “Dashboard Description”,
    “Dashboard Style”, “Dashboard Page Name”, “Dashboard Page Path”, “Dashboard Page Description”,
    “Dashboard Page Created Time”, “Dashboard Page Last Accessed Time”, “Dashboard Page Last Modified Time”,
    “Dashboard Page Xml”, “Request Name”, “Request Path”, “Request Description”, “Request SQL”
    Example: catalogmanager -offline c:\oraclebi\data\web\catalog\paint -cmd report -of c:\temp\report.txt -folder “/shared” -type Dashboards “Request Name” “Request SQL”

    -cmd replace
    catalogmanager -offline -cmd replace ( -if | ( -old -new ) ) [-folder ]
    Example: catalogmanager -offline c:\oraclebi\data\web\catalog\paint -cmd replace -if c:\temp\replace.xml
    Example: catalogmanager -offline c:\oraclebi\data\web\catalog\paint -cmd replace -old “Sales” -new “Marketing”

    -cmd export
    catalogmanager -offline -cmd export -od [-excludeDesc] [-incremental] [-folder ]
    Example: catalogmanager -offline c:\oraclebi\data\web\catalog\paint -cmd export -od c:\temp\export -incremental
    ———————————————-

    A couple of points to note:
    1) All OS file or folder names MUST have an absolute path, including the drive letter!
    2) Quotes and backslashes should NOT be escaped, i.e. “c:\temp\report.txt”, and not: “c:\\temp\\report.txt”
    3) Although I have not tried it, one should use “-experimental” and not “-expermimental”, as that is what the source code is looking for
    (the typo is only in the usage text,. not in the code)
    4) I haven’t figured out a way to use TAB as the delimiter. Tried \t, ox9, 11 (both quoted and not) – nothing seems to work. Ideas?

    -Dave

  10. shan Says:

    I was to trying to archieve the catalog using the commandline mentioned above but seems like the same is not working. May be be i am wrong using the syntax.

    catalogmanager –online -login SADMIN -pwd SADMIN –expermimental –cmd archive

    Thanks in advance for your help.

  11. Karthik Says:

    Hi Venkat,

    I was trying to find the catalogmanager utility for our Unix installation but never found it under the installation folders:

    ../obiee/obi/
    ../obiee/obidata/

    Any idea where this utility is hidden?

    Thanks,
    Karthik

  12. Lavanya Says:

    Hi Venkat,

    Is this catalogmanager cmd line utility available in 10g version also?

    Thanks

Write a comment





Website Design & Build: tymedia.co.uk