Open topic with navigation

TIBCO iProcess® Engine 11.10.0

# SW_SET_MBOX

The `SW_SET_MBOX` procedure tells the current SSOLite session to use a different Mbox set from the default one.

## Syntax

    SW_SET_MBOX (
     mbox_set_id	integer)

where:

| • | `mbox_set_id` is a unique identifier for the Mbox set you want to use.

## Notes

This procedure is useful to partition messages for the purpose of performance or service levels. The procedure can be used in many ways, including separating out bulk operations, such as purging or starting cases. Other sessions will still use the default Mbox set for operations such as delayed releases.

Use the SW_UNSET_MBOX procedure to restores using the default Mbox set for all operations.

## Example

The following example shows how to set another Mbox set `BGMBSETB` for bulk operations. You must create the `sw_db_bgqueue_3` and `sw_db_bgqueue_4` physical queues and `bgmboxtable4` tables, and the `bgmboxqueue3` and `bgmboxqueue4` AQ first. For more information about queue processing and Mbox set creation, see Processing Queues.

    # Step 1. Add two new message queues.
    #
    swadm add_queue BGMBOX3 Local 0003:swpro.sw_db_bgqueue_3
    swadm add_queue BGMBOX4 Local 0003:swpro.sw_db_bgqueue_4

    # Step 2. Add a new Mbox set.
    #
    swadm add_mboxset BGMGSETB Local

    # Step 3. View Mbox and queue IDs.
    #
    swadm show_mboxsets v
    swadm show_queues

    # Step 4. Add the BGMBOX3 and BGMBOX4 message queues to the BGMGSETB Mbox set (
    6 is the Mboxset ID of the BGMGSETB Mbox set,
    8 is the queue ID of the BGMBOX3 message queue, and
    9 is the queue ID of the BGMBOX4 message queue.)
    #
    swadm add_queue_to_mboxset 6 8
    swadm add_queue_to_mboxset 6 9

    # Step 5. Set the BGMGSETB Mbox set for bulk case starts.
    #
    CALL swpro.SW_SET_MBOX(6)/

    # Step 6. Start the bulk cases.
    #
    CALL swpro.SW_ADD_PACK_DATA ('CustName', 'Allsop, J.A')/
    CALL swpro.SW_ADD_PACK_DATA ('CustID', '478163')/
    CALL swpro.SW_CASESTART ('CUSTREQ', -1, -1, 'Refund request', 'user35', '', ?, ?)/

    # Step 7. Restore using the default Mbox set.
    #
    CALL swpro.SW_UNSET_MBOX()/

Did you find this helpful?

Yes No
Great!
Thanks for taking the time to give us some feedback.
Sorry about that

Why wasn't this helpful? (check all that apply)

Could not find what I was looking for
Instructions confusing or unclear
Instructions did not work

Want to tell us more?

Please select at least one option or provide details about the issue!!

Error occurred while submitting feedback.

Error2 occurred while submitting feedback.

TIBCO iProcess® Engine