The Cube Supervisor is an SVS worker reacting to changes to cell values. Inside the function “InitCubeWorker” of the file sep.inc.on_cell_change.php, you can define several areas of sets/slices of cells for every cube and link each of these “hot areas” to its own callback PHP function that will be executed if the user changes the value of a cell inside the set.
Note: The areas defined in a cube must not overlap structurally. For example, if you define one worker for an area including Qtr. 1 and another one for Jan, the two areas overlap because Qtr. 1 is a the parent of Jan.
The splashing parameters of a user’s input are also passed to the Supervision Server in the “InitCubeWorker” event so that they can be handled in the callback function for “WatchCubeArea”.
If the instruction “use cube-workers” appears in the palo.ini, or if the option “Y” is passed from the command level, then the Jedox OLAP server starts a Cube Supervisor for each cube. Therefore several Supervision Server processes may appear in the Task Manager of Windows.
Custom error messages
In some cases, such as an SVS “cube worker” script that supervises changes made in specific cubes or cube areas, the script may refuse the change based on some custom logic in the script. You can enable custom error messages using a sep_error function.
The function sep_error takes two arguments: a message header and a message body. If the message header has a certain content, you can control the look of the message popup in the Excel Add-in or Web. The function must looks as follows:
single digit code + : + custom string
Indicates if a warning, info or error message is shown. The following values are possible:
The text of the popup message.
sep_error("0 : Custom Info Message", "No one is allowed to modify Turnover values")
sep_error("1 : Custom Warning Message", "No one is allowed to modify Turnover values")
sep_error("2 : Custom Error Message", "No one is allowed to modify Turnover values")
If the value of the first argument is, for example, “Warning”, a Warning message using the same argument as text is shown.
For all the other values of the first arguments of sep_error, the normal writeback error popup message is displayed. The value of the second argument is shown in the detailed error message of the popup.
Note: If you make an actual writeback mistake, such as omitting the # character on an aggregated cell, the SVS script is not reached and the regular writeback popup message is displayed.