For posting questions on Content Manager OnDemand, please go to Computer Help Me! Forum (Click Here)

Thursday, April 2, 2009

OnDemand ARSADMIN UnLoad - UnLoading reports

One of the most frequent items I am asked to do for Content Manager OnDemand users is to delete a report. This is not an easy task unless you are familiar with the command line tools. There is not and option in the client to delete a report after it is loaded. A duplicate or bad load is often jsut dealt with by ignoring it and pretending it is not there. This often works, but is sometimes not an option. I had a client (a bank, as you will figure out) one time who had accidently loaded all of the bank employees checking account statements into a portion of OnDemand that was open to all users in the bank. Obviously this had to be cleared up fast and could not be ignored. I walked this client through the deletion process very quickly and it worked out for them.

One item to note right up front is that a report as displayed in OnDemand often is not a one to one relationship to the report that was loaded. As you know, a report can be split up when it is loaded into OnDemand so that a single report might be viewed as hundreds or thousands of online reports. If just one of the viewable reports needs to be deleted then all of the reports must be deleted. The deletion is by the load, not the viewed report.

So, that said, let's look at the options for the command to unload a report. First step is to get to the location of the command. It is located under ....\OnDemand for WinNt\bin on Windows and under ...../ondemand/bin on the Unix platforms. The command that will be used to do the unload is arsadmin unload. Let's look at the parameters for this command.

Usage: arsadmin unload [options]
Version: 8.4.0.0
unload Unload a LoadId from OnDemand
-g Application Group Name
-h OnDemand Hostname
-p OnDemand User Login Password
-u OnDemand User Login Name
-L LoadId to delete from OnDemand
-N Skip looking up the LoadId in System Log
-Q Continue if unable to find LoadId in System Log

For most unloads, the first 5 options are all that is needed. The hostname is not supposed to be required but I believe that, at least on Windows servers, it still is needed to get this to work. So the format for the unload is:

arsadmin unload -h localhost -u admin -p password -g AppGroupName -L 5011-1-0-2FAA-0-0

So all of that is pretty straight forward until you hit the load id. Where does that part come from? Well, that is an ID assigned to each report stream as it is added to the system. Not each viewable report but the report in the format it was in before loading. The load id is in the system log, but if you have been loading a lot of reports into this application group, finding it may be very difficult and could be a hit or miss option to know which one to remove.

But there is another much more accurate way to find it. Use the arsdoc query command to look up the report information based on the same criteria as is used to search for a report in the OnDemand client. And that will be the subject of the next post.