Moving forums to the trash 

Use administrative commands to move one or more forums to the Trash view.

Before you begin

To run administrative commands, use the wsadmin client. See Starting the wsadmin client for details.


  1. From the dmgr host:

      cd $DMGR_PROFILE/bin
      ./ -jython

      If prompted to specify a service to connect to, type 1 to pick the first node in the list. Most commands can run on any node. If the command writes or reads information to or from a file using a local file path, pick the node where the file is stored.

  2. To move forums to the trash, first generate a variable containing the forums that you want to delete, and then delete the forums associated with that variable as follows.

    1. Create a variable that contains the forum or forums that you want to delete.

        You can get a list of forums in hash table format using one of the fetchForums() commands. See Getting a list of forums for more information about the commands.

        For example:

        variable=ForumsService.fetchForumsByName(java.lang.String forumName)

    2. Enter the following command to delete the forum or forums:

        ForumsService.deleteForums(java.util.Vector forums)

        where you specify the forum or forums that you want to delete as the forums parameter. This parameter maps to the variable that you created in the previous step.

        For example, if a person leaves the organization and you want to delete a forum owned by them, you use the following commands to generate a variable containing the forum and then delete the forum associated with that variable.

        obsoleteForum=ForumsService.fetchForumsByName("Joes Forum")

Parent topic

Manage forum trash

Related tasks

Getting a list of forums
Purging forum trash on a schedule
Purging specific forum content from the trash
Restore deleted forum content