Generic Splitter
The Generic splitter is a legacy task which is kept for backwards compatibility purpose. In previous versions of PlanetPress Workflow, it was the only splitter available. While this splitter seems to have more options than the other ones, this is only because it contains combined features from these other splitters.
The Generic splitter, while seemingly more feature-rich, is slower than the other splitters by an order of magnitude. Whenever encountering the Generic splitter, it is always recommended to replace it with a more appropriate splitter instead.
Input
Any data file.
Processing
The file is separated into multiple chunks according to the rules set in the task's properties.
Output
Multiple data files, sent one after the other to the rest of the tasks in the process. Metadata, job infos and user variables are not modified by this task.
Generic Splitter action task properties are as follows:
General Tab
- Split data file on: Use this box to choose the item on which top split the file. The options available depend on whether or not the Use emulation box is checked (see below).
- Use emulation: Check to emulate the data before splitting the file. This lets you split the file on a word, a word change, a page number, a database field value or a database field change. When this option is not checked, you can only split the file on a form feed, a specific number of lines, or a chain of characters. See below for detailed information on any of these splitting methods.
- A word : If you choose “A word” in the Split data file on list box (the Use emulation option must be selected), the following boxes are displayed.
- Word: Enter the string of characters to search for as the splitting criteria. In this variable property box, you may enter static characters, variables, job information elements or any combination of these.
- Get: Click to get a static string of characters from the sample data file. If you use this button, the coordinates of the data you will select will be added to the Word is between lines and Word is between columns groups below.
- Word is between lines group
- From and To: Enter a vertical search region defined as starting from a given line and ending at a given line. If you enter 1 in the From box and 1 in the To box, the Generic Splitter will search for the string of characters entered above only in the first line of every page. If you enter 1 in the From box and 10 in the To box, the Generic Splitter will search in the ten first lines of every page. Note that the actual search region is a combination of the vertical and horizontal search regions.
- Word is between columns group
- From and To: Enter a horizontal search region defined as starting from a given column and ending at a given column. If you enter 1 in the From box and 5 in the To box, the Generic Splitter will search for the string of characters only in the first five column (five first characters of every line selected above).
- Consider case: Select to force the Generic Splitter to match the character casing of the string of characters entered above with the characters found in the file. If this option is selected, “DAY” and “Day” will not be considered as matching the search string “day”.
- Where to split group
- Pages: Enter exactly where to split the file. Enter 1 to split the file 1 page before or after the string, 2 to split the file 2 pages before or after the string, or 0 to split the file immediately before or after the string.
- Before or after: In the previous box, you entered exactly where you wanted to split the file, here is where you specify whether you want the split before or after.
- Split when word found: You may not want to split the file every time the string of characters entered above is found, but only every other time, or every third time. If so, enter the number of times in this box.
- A Word change: If you choose “A word change” in the Split data file on list box (the Use emulation option must be selected), the following boxes are displayed.
- Get: Click to select a search region. The coordinates of the selected region will be added to the Word is in line box and the Word is between columns group below. The Generic Splitter will look for changes in the string of characters appearing in that region.
- Word is in line: Enter the line on which to search for the word change. If you enter 1, the Generic Splitter will consider only in the first line of every page. Note that the actual search region is a combination of the vertical and horizontal search regions.
- Word is between columns group
- From and To: Enter a horizontal search region defined as starting from a given column and ending at a given column. If you enter 1 in the From box and 1 in the To box, the Generic Splitter will search for the string of characters entered above only in the first column of the line selected above. If you enter 1 in the From box and 10 in the To box, the Generic Splitter will search in the ten first columns of the line selected above.
- Consider case: Select to force the Generic Splitter to consider a change in character casing as a word change. If this option is selected, “DAY” will be considered as different from “day”.
- Trim selection: Select to force the Generic Splitter to trim empty characters at the beginning and end of the data found in the search region. If this option is not selected, “DAY” will be considered as different from “DAY”.
- Where to split group
- Pages: Enter exactly where to split the file. Enter 1 to split the file 1 page before or after the string, 2 to split the file 2 pages before or after the string, or 0 to split the file immediately before or after the string.
- Before or after: In the previous box, you entered exactly where you wanted to split the file, here is where you specify whether you want the split before or after.
- Split when word changed: You may not want to split the file every time the string of characters entered above changes, but only every other time, or every third time. If so, enter the number of times in this box.
A Page Number: If you choose “A page number” in the Split data file on list box (the Use emulation option must be selected), the following boxes are displayed.
- Pages per output file: Enter a number of pages after which to split the file. If you enter 3, for example, the Generic Splitter will split the file every time it has counted three pages. A 10 page file would be split in 4 files, the first three being three pages long and the last one only 1 page long.
- View data file: Click to view the sample data file and to cycle through the pages.
A Database Field Value: If you choose “A database value” in the Split data file on list box (the Use emulation option must be selected), the following box is displayed.
- Field: Enter the name of the field that the Generic Splitter must check (only alphanumeric fields can be used—selecting a binary field, for instance, will cause the job to fail). If you enter “ID”, for example, the Generic Splitter will only look in the field named “ID” for the value entered below. In this variable property box, you may enter static characters, variables, job information elements or any combination of these.
- Operator: Select the appropriate comparison operator. If you select Equals, the Generic Splitter will only consider that the condition is met when it finds a perfect match (“day“ and “day“, for example). If you select Contains, the Generic Splitter will consider that the condition is met whenever it finds the string of characters entered in the Value box, even if the database field contains additional characters (“day“ and “days“, for example, would be considered a match).
- Value: Enter the string of characters to search for as the splitting criteria. Like the Field box, this is also a variable property box.
- Consider case: Select to force the Generic Splitter to match the character casing of the string of characters entered in the Value box with the characters found in the file. If this option is selected, “DAY” and “Day” will not be considered as matching the search string “day”.
- Where to split group
- Pages or records: Enter exactly where to split the file. Enter 1 to split the file 1 page or record before or after the string, 2 to split the file 2 pages or records before or after the string, or 0 to split the file immediately before or after the string.
- Before or after: In the previous box, you entered where you wanted to split the file. Here is where you specify whether you want the Generic Splitter to split the file X number of pages or records before or after the string. Choose 5 in the Pages or records box and “Records after” in this box, for example, to split the file 5 records after the record that matches the condition.
- Split when condition found: You may not want to split the file every time the string of characters entered in the Value box is found, but only every other time, or every third time. If so, enter the number of times in this box.
A Database Field Change: If you choose “A database field change” in the Split data file on list box (the Use emulation option must be selected), the following box is displayed.
- Field name: Enter the name of the field that the Generic Splitter must check. If you enter “ID”, for example, the Generic Splitter will only look in the field named “ID” for the value entered below. In this variable property box, you may enter static characters, variables, job information elements or any combination of these.
- Consider case: Select to force the Generic Splitter to match the character casing of the string of the values appearing in the selected database field. If this option is selected, “DAY” and “Day” will not be considered as matching the search string “day”.
- Where to split group
- Pages or records: Enter exactly where to split the file. Enter 1 to split the file 1 page or record before or after the string, 2 to split the file 2 pages or records before or after the string, or 0 to split the file immediately before or after the string.
- Before or after: In the previous box, you entered where you wanted to split the file. Here is where you specify whether you want the Generic Splitter to split the file X number of pages or records before or after the string. Choose 5 in the Pages or records box and “Records after” in this box, for example, to split the file 5 records after the record that matches the condition.
- Split when condition found: You may not want to split the file every time the string of characters changes, but only every other time, or every third time. If so, enter the number of times in this box.
On Error Tab
By default, any action task, branch, splitter or condition that generates an error will simply be ignored, and the task just under it (not within a branch) will be given control of the job file without any modification. Any initial input task that generates an error will stop the process from running as a whole, and output tasks will not generate output. The On Error tab can be used to overwrite the default behaviors.
- Send to Process: Check this option to send the job file to an error management process.
- Error Process drop-down: Enabled only when the Send to Process option is checked. Lists any process of which the initial input task is the Input Error Bin task.
- Action Group: This group is disabled in the initial input tasks and defaults to Stop Process. In all other tasks where the On Error tab is present, the following options are available:
- Ignore: The task is ignored as if it did not exist, and the job file is passed on to the next task in the process.
- Stop Branch: If the task is in a branch of the process, the branch is stopped and the job file is returned to the process after the branch. The branch will not produce any output.
- Stop Process: The process is stopped and no more processing is done. No further output is produced.
- Log Message: Check this option to enable logging a custom error message in the PlanetPress Suite Workflow Tools' log file.
- Message: Enabled only when the Log Message option is checked. Enter a message that will be logged in the PlanetPress Suite Workflow Tools' log file. You can use any variables available in PlanetPress Workflow to customize the message.
- Store the message in variable: Select in which jobinfo, local or global variable you want to store the message content.
- ID: Enter an error ID. This ID will be visible in the Windows Event Viewer. However, the ID is not visible in the PlanetPress Suite Workflow Tools' log file.
- Store the ID in variable: Select in which jobinfo, local or global variable you want to store the error ID.
- Reset to defaults: Resets all options in this tab to their default values.
If storing the message or ID, if they are store in a jobinfo they will be available in any error handling process where errors are being forwarded. In all cases, if your process continues after the error, the contents of the variables selected in this window will be available for the rest of your process, or whenever they are overwritten.
Common Errors
Though some error messages are specific to a task in particular, others may apply to any and all tasks because they are related more to the system than to PlanetPress itself. Some examples would be W3813, W3830, W3991, W4005. These correspond to issues such as not having any space to write files, permission errors on folders or files, etc.
Comments Tab
The Comments tab, added in PlanetPress Suite 7.5, is common to all tasks. It contains a single text area (Task comments) that lets you write comments about the task. These comments are saved when the dialog is closed with the OK button, and are displayed in The Task Comments Pane.