Writing a Conversion Rule
You can add a conversion rule to a template for importing or exporting information.
- Open the Add Template Field page or the Edit Template Field page.
- Make sure the template
includes the fields that you will be using in the rule.
Note: When you are exporting, if you have a field in a rule, that field must exist in the template. When you are importing, if you have a field in a rule, that field must exist in the Sage HRMS file you have selected.
- Create the conversion rule using one of the following methods:
- Type an expression or function in the Conversion Rule text box.
- Click the Expression Builderarrow to build a more complex rule. Click OK when done.
- Click to save the changes to the template.
Writing a Conversion Rule Example
Sage HRMS requires each employee to have an employee number. However, you may want to import data from a system that uses Social Security numbers for tracking. You can create an expression that converts the Social Security numbers into employee ID numbers.
- Include both the employee ID and Social Security number fields in your template. Sage HRMS must have these fields to convert the and import the ID number correctly.
- Click the Expression Builder arrow.
- In the Expression Builder dialog box, use the fields to build the rule in the Conversion Rule text box.
- Use STRTRAN() to extract the numbers from the data.
- Use
the following format for this function.
STRTRAN( field name, string to search for)
Example: If the data were in the field p_ssn, you would enter the following in the rule area.
STRTRAN(p_ssn,"-") - When done, click to close Expression Builder.
- Click to save the changes to the template.