DataImporter - Import Incidents / SR Activities

SHOW ALL CONTENT

Table of contents

Introduction

This import type allows to import the activities related to requests.

During the original Incident - SR import, only the resolution activity is imported. Use this import type if activities from another system need to be kept. 


References

 

What you need to know:

The reference template files (.xlsx et .xml) to prepare imports are included in the Incidents-SR_EN.zip file.

Required Fields

  • Number - Whole number
    • Represents the number of the request (incident or SR) associated to the activity
    • The number used can be the one from Octopus or the one from the source system, if requests were imported from another system
    • For more details, refer to the Request identification method
  • Date – Date and Time
    • Represents the activity date. The date must be greater than or equal to the opening date and less than or equal to the resolution date
    • The date format must be compatible with the server settings; YYYY-MM-DD
  • User
    • Octopus assignee who entered the activity
    • The Octopus user must already exist in Octopus. 
    • The only identification method for the Octopus user is the Windows Username. 

Optional Fields

  • ID - Whole number
    • Will be mandatory if the identification method of the request is ByImportedIncidentID
    • Must contain the number of the request previously imported.

    • The number is the one prefixed to the subject of the request.

  • Type
    • Represents the activity type already defined in Octopus
    • The activity type is configurable from the Tools > Reference data management > General > Activity types menu
    • If this field is mandatory in Octopus, it will be mandatory during import
  • WorkBreakdown - Text (5000)
    • Represents the description of the work done
    • If this field is mandatory in Octopus, it will be mandatory during import
What you need to know
  • Multiple activities can be added at a time by placing them on separate lines.
  • Each new line with the same request number will be a new activity.
  • Effort
    • Represents the effort of the work done for each activity
    • Format HH:MM:SS (in Excel the column must be in text format).
    • The activity effort must be between 00:01 and 99:59
    • For example, for one and a half hour, write 01:30 in the column.
    • A day value is converted into hours. For example, 1 = 24 hours, so 24:00.
    • When the minutes exceed 59, they are converted into hours. For example, 0:75 = 1:15.
    • If there are seconds added, they are ignored. For example, 1:10:25 = 1:10.
    • This field is required if it is mandatory in the Octopus options.
  • OnSiteVisit - Boolean
    • Check box type field to specify if the technician had to go on site to execute the activity
    • Accepted values are: 1 or 0, True or False, Yes or No
    • If non specified, the default value is no.
  • Supplier Text (100)
    • To add an External labour activity. 
    • Indicates the name of the supplier who did the work. 
    • If Octopus finds the name of the supplier, it will associate the activity with the supplier found. 
    • Otherwise, it will create a new supplier. 
  • Cost - Decimal
    • The value must be between 0 and 9 999 999.99.
    • Example: 1234567.89.

 

 

Content of the Configuration File (IncidentActivity.xml)

The declaration of the source is done by indicating the IncidentActivity value in the <Content> tag.

NOTE: The XML file used as this example is for an import done from Excel 2007 or 2010.
<?xml version="1.0" encoding="utf-8" ?> 
<Sources> 
     <Source Name="IncidentsSRActivities"> 

<ConnectionString>Provider=Microsoft.ACE.OLEDB.12.0;Data Source=c:\Import\Incidents-SR_EN.xlsx;Extended Properties="Excel 12.0 Xml;HDR=YES";</ConnectionString>
     <ViewName>[Import Activities$]</ViewName> 
     <Content>IncidentActivity</Content> 

     <!-- Additional tags -->    
<IncidentIdentificationMethod>ByImportedIncidentID</IncidentIdentificationMethod>
   </Source> 
</Sources>

Refer to the XML Configuration File article that explains how to program references to the data sources.

What you need to know:

The additional tags are case sensitive.

If the value is not written exactly the way it is documented, Octopus will ignore the tag and use to the default value. 

Additional Tags to Import Incident & SR Activities

To import incident and SR activities, the XML file can contain one additional tag. This tag is not mandatory and if it's not specified, the default value will be used. 

Request Identification Method

In the XML file to import request activities, it is possible to specify how the request will be found, either by the incident/SR number or by the imported request number.

Permitted values for the IncidentIdentificationMethod tag:

  • ByIncidentID: Octopus incident/SR number
  • ByImportedIncidentID (Default value): Imported source request number.

So, if you import requests from an external source and after you import activities, the system can use the number from the external system.

To use this tag, add the following line to the XML file:

<IncidentIdentificationMethod>VALEUR</IncidentIdentificationMethod>
X
Help us improve our articles