Question & Answer
Question
How to create a custom column in the Taskmaster Web Job Monitor.
Cause
It is possible to add custom columns to the Job Monitor. These custom columns can then be sorted and filtered on if desired.
Answer
To Add a Column
Direct queries to the database, such as with SmartSQL, cannot be used, as the entry will be overwritten when the task completes.
- In the tmBatch table in the engine database, add a column, giving it the desired name preceded with pb_ (ex: pb_MyColumn).
- Save the table.
- Update the JMView and JobMonitor views.
- For SQL, also do the following:
- Open the JMView view for design.
- Delete each item appearing in the 'Alias' column.
- Press the ! (exclamation mark) icon.
- Save the view.
- Open the JobMonitor view for design.
- Delete each item appearing in the 'Alias' column.
- Press the ! (exclamation mark) icon.
- Save the view.
- For Oracle:
- Use an Oracle database tool to add the newly created column (e.g. pb_MyColumn) into the JMView and JobMonitor views.
- Execute the changes.
- Save the views.
- For DB2
- Use a DB2 Administrative tool to add the newly created column (e.g. pb_MyColumn) into the JMView and JobMonitor views.
- Save the views.
- For SQL, also do the following:
- Restart Taskmaster Server.
To Populate the Column with Custom Actions
- If using a Batch Pilot form, the following command is used.
pilot.XtraBatchFieldValue("pb_MyColumn") = "my value" - If using a Rulerunner action, the pilot.XtraBatchFieldValue parameter must be upper-case. For example:
sValue = pilot.XtraBatchFieldValue("PB_MYCOLUMN") - The value passed to the property must be valid for the database field. That is, it cannot exceed the maximum number of characters that can be held in the database field or contain characters not valid for that field type.
Direct queries to the database, such as with SmartSQL, cannot be used, as the entry will be overwritten when the task completes.
Using Batch Pilot to update Custom Columns in the Datacap Navigator Scan task
When StartPanel is enabled, the Scan task enables Batch Pilot to modify and update custom fields as long as:
- Scan task is attached to the task profile
- Custom fields are configured in StartPanel
Adding a custom field in StartPanel
- Drag the custom field to the StartPanel (Scan Task) window.
- Once the custom field has been added to the StartPanel (Scan task) window, there is an option to allow these fields to be hidden or displayed in StartPanel.
If fields are not available in StartPanel, Navigator considers the custom fields to be read only and does not modify the columns in the tmbatch table.
Note: In Datacap Navigator, Custom columns of tmbatch table are modified through wTM API "SaveBatchAttribute" method.
[{"Line of Business":{"code":"LOB45","label":"Automation"},"Business Unit":{"code":"BU053","label":"Cloud & Data Platform"},"Product":{"code":"SSZRWV","label":"IBM Datacap"},"ARM Category":[{"code":"a8m0z0000001h36AAA","label":"Technote"}],"Platform":[{"code":"PF033","label":"Windows"}],"Version":"All Version(s)"}]
Was this topic helpful?
Document Information
Modified date:
02 March 2021
UID
swg21500306