The Staffing 01 is used to automate a regular feed from an external source to import staffing records (work code records). The Staffing 01 is mainly used to import accrual balances, time granted, or earned time from an external source so that the application can enforce leave against these balances.
Import Directory Formats are typically created by vendor partners. The format provided below is required if you intend to automate a regular feed from an external source.
Staffing 01 Sample:
<Data>
<Header> <ImportDirective>STAFFING01</ImportDirective>
<Methods> <CallLog>False</CallLog> <InsertNew>True</InsertNew>
<UpdateExisting>True</UpdateExisting> </Methods> </Header>
<Rows> <Row> <PayrollID>000102</PayrollID> <LNameMatch>SALA</LNameMatch> <StartDate>2011-01-01</StartDate>
<StartTime>07:00:00</StartTime> <Duration>6.67</Duration> <WorkCode>VA</WorkCode>
<Shift>2011-02-02</Shift> </Row> <Row Action="Update"
Optional="True"> <PayrollID>200141</PayrollID> <StartDate>2011-01-01</StartDate> <StartTime>07:00:00</StartTime>
<Duration>5.0</Duration> <WorkCode>VA</WorkCode> <Shift>2011-02-02</Shift>
</Row> </Rows> </Data>
Optional - Sample code block to supply Since Date noted below. This code block updates the Since Date field to 02/05/2015 for this work code instance of Vacation (V), and this instance of the work code, Overtime (SOD).
<SinceDateList>
<SinceDate> <Date>2014-02-05</Date> <Code>V</Code> <Code>SOD</Code>
</SinceDate> </SinceDateList>
Optional - Sample code block to supply shift and position details. Available in version 6.5.1.2+, and 6.6.1+
<Data> <Header> <ImportDirective>STAFFING01</ImportDirective>
<Methods> <AllOrNone VarType="11">False</AllOrNone> <UpdateToMatchAssignment>True</UpdateToMatchAssignment> </Methods>
</Header> <Rows> <Row action="Update"> <StaffingNoIn>22913</StaffingNoIn> <StartDate>2018-7-19</StartDate>
<StartTime>00:00:00</StartTime> <Duration>24</Duration> <WorkCode>V</WorkCode>
</Row> </Rows> </Data>
Optional - Sample code block when supplying only the Staffing_No_In. Available in version 6.5.1.2.
<Data> <Header> <ImportDirective>STAFFING01</ImportDirective>
<Methods> <AllorNone VarType=”11”>False</AllOrNone> <UpdateToMatchAssignment VarType=”11”>True</UpdateToMatchAssignment>
</Methods> </Header> <Rows> <Row> <StaffingNoIn>178</StaffingNoIn>
</Row> </Rows> </Data>
Optional - Sample code block when supplying the Staffing_No_In and additional attributes. Available in version 6.5.1.2.
<Data> <Header>
<ImportDirective>STAFFING01</ImportDirective> <Methods>
<AllorNone VarType=”11”>False</AllOrNone>>True</UpdateToMatchAssignment>
</Methods> </Header> <Rows> <Row> <StaffingNoIn>178</StaffingNoIn>
<StartDate>2018-10-08</StartDate> <StartTime>06:00:00</StartTime>
<Duration>8</Duration> <WorkCode>V</Workcode> </Row>
</Rows> </Data>
DATA
HEADER
ImportDirective
The header field is required. It identifies the import format within the <Data> section. The Ongoing Import will reject an illegal ImportDirective value. Legal values are the names of the variations found in the sample files.
VERSION
The version field is optional. It is used to ensure that a given import file only works against that specific version of the application. Simply put, if you want the import to fail when a major upgrade occurs, set the version number. If irrelevant because these interfaces are maintained across versions, then omit this section.
Methods
The methods section is optional if the default values below are as desired. If not, include the method that you want to override.
Field Name | Format | Description |
---|---|---|
Import Key | One of...
|
A tag with the same name as this selection must exist as in the supplied XML file for each <Row>. PayrollID is assumed if the method is not supplied. |
AllorNone | True (default) or False | If TRUE, any failure to insert/update a record within the application will rollback all changes made prior to the failure and exit the program. If FALSE, insert or update failures will be logged but successful inserts or updates will be saved. |
UpdateExisting | True (default) or False | If TRUE, it is okay to update existing records within the application. |
InsertNew | True (default) or False | If TRUE, it is okay to insert new records into
the application.
|
UpdateToMatchAssignment | True or False (default) | Available in application version 6.5.1.2+ and
6.6.1+. If TRUE this will update the location of the staffing record. To
update the location of a staffing record (position/shift/physical
unit), the following must be supplied:
|
TargetActive | True (default) or False | If True, the record to be inserted will be assigned to the Active profile for the target person on the Target date. If False, the minimum ordinal profile will be used instead. |
CallLog | True or False (default) | If True, a contact log (a.k.a. call log tbl) will be created in addition to inserting/updating a staffing record. You may need to create a call log record to keep the logging totals (i.e. logging buckets) accurate when logging is initiated by the use of a List -- sometimes necessary for legacy imports (True) by usually not for accrual balance imports (False). |
InsertStaffingOnAccept | True (default) or False | If False, you can achieve an update of the contact log (a.k.a. call log tbl) without inserting a staffing record. |
WorkCodeIsPayrollCode | True or False (default) | If True, the <WorkCode> field below is assumed to contain a payroll code (versus as work code abbreviation). |
IgnoreList | True (default) or False | If False, the name appearing in the <List> field will be used as matching criterion when searching for the existence of a staffing record. |
InstitutionFocus | An Institution's Abbreviation max 10 characters | An Institution focused database allows the selection of a time zone for each Institution. The database stores all information in a single time zone called system time. This option allows you to import times using an institution's time zone, identified here by entering the institutions abbreviation, rather than having to import using the system time. |
Update to Match Existing Behavior
Update to Match Existing is a method available in application version 6.5.1.2 and 6.6.1+ that changes the way the application returns a user’s assignment when performing InsertNew or UpdateExisting. The previous and default logic returns the target person’s Shift and up to the Region level of the Organization, then the application would <Off-Roster> the remaining organizational levels. If UpdateToMatchExisting=TRUE this will allow InsertNew and UpdateExisting to return the target person’s entire assignment. When the Shift or Region are supplied in the XML file, the import will attempt to match the criteria provided to that person’s assignment. If the person does not have an assignment that matches the passed in criteria it will <Off-Roster> the person to the Shift or Region provided; essentially, reverting to the previous logic.
If the UpdateToMatchExisting flag is set to True, for any update where the staffing gray number was provided, the system will find the matching assignment. The user’s assignment will override any passed in values for shift or region. The import will update the staffing record, modifying the record to match the user’s assignment. To update the location of a staffing record (position/shift/physical unit), the following must be:
The user’s assignment must be found and returned (the system will always find an assignment, even if they do not have one running that day. The only way the system will not be able to find an assignment is if the user doesn’t have one. If the above criteria is not met, the update will fall back to the previous logic and the organizational structure or Shift criteria of the staffing record will not be updated.
Rows
Lay term | Format | DB Column Name | Field Name |
---|---|---|---|
Employee identifier | max 30 characters, or numbers (RscMasterNoIn & RscNoIn) | One of these and based on ImportKey method
selection:
|
One of these and based on ImportKey method
selection:
|
Start date | yyyy-mm-dd | Staffing_Calendar_Da | StartDate |
Start time | hh:mm:ss | Staffing_Start_Dt (calculated from StartDate) | StartTime |
Duration | 0.0### (1-4 decimal places) | Staffing_End_Dt (calcuation from StartDate and StartTime) | Duration |
Shift abbreviation | max 10 characters | Shift_Abrv_Ch | Shift |
Work code abbreviation | max 10 characters | Wstat_Abrv_Ch | WorkCode |
Region abbreviation | max 10 characters | Region_Abrv_Ch | Region |
List name | max 40 characters | Strategy_Name_Ch | List |
Since Date | yyyy-mm-dd | Wstat_AccrualSince_Da | Since Date (If supplied, sets the accrual since date for that work code. If blank, it is set to the current date (today at midnight).This is a date field that determines when a balance should start. The application will only consider hours that are granted after this date. |
Outcome | enumeration (1=accepted, 10 rejected, 18=Skipped, etc...) | Cq_Status_No_In | Outcome |
Timestamp | yyyy-mm-dd hh:mm:ss | Staffing_Timestamp | Timestamp |
Staffing record gray number (Internal ID) | number | Staffing_No_In | StaffingNoIn
Matching behavior order for Note: In
lay terms, the application checks for the best assignment match
in order to update the staffing record, meaning when I move this
staffing record, such as Vacation which assignment do I use to return
the best Shift (start/end datetime) and Position for this record being
moved.
|
Row Attributes
The following optional attributes can be supplied with the <Row> tag to override the default behavior of the import process. For example, you can ensure that only an update is performed on a given row and that a failure will not stop the process by starting the row section with: <Row Action=”Update” Optional=”True”>.
Name | Format | Description |
---|---|---|
Action | One of...
|
The default behavior seeks to update and insert
if an existing record is not found. This attribute allows you to specify
how this individual row is treated. Action Update targets and updates the following data:
|
Optional | True or False (default) | If TRUE, then match failures will be overlooked. For example, a record designated with <Row Auction=”Update” Optional=”True”> indicates that you want to update if a match is found but that you don’t want to fail if a match is not found. |