Create History record with outcome [ ] sub code [ ]

Command

CREATEHISTORYRECORD

Image
Group Database
Section Create

Description

Creates a record on rHistory_Detail with the specified outcome and sub-code information.

Note: It will not stamp any timing information and is designed to be used mainly on non-Infinity based databases to provide basic reporting on calls.

Parameter 1

The outcome for the call

Parameter 2

The sub code for the call

 

Use: Continue a call ensuring a history record is created

At the end of a script you may wish to continue the call with another contact. In order to do this you will need to ensure all data for the current contact has been saved and when required a history record is created.

Provide the user with a Save and Continue button which will be used to save the data, clear down any necessary fields and return the user to the correct point in the workflow so they can process the next contact record.

This example assumes you will be auto coding the history record with a pre-determined call outcome and sub-code. If you need the agent to select a call outcome you will need to produce a simple modal pop-up form that will allow them to select an outcome for use in the save routine.

This example script contains the following functions:

  • 1st line: It is used to commit any changes to the main contact record (pContacts and pContactsExtra tables) to the database. If you have used any custom tables, you will need to save and remove them from memory here.
  • 2nd line: It creates a Call History record (rHistory_Detail) record using the provided Outcome code. The timing details will be limited to the Talk time only.
  • 3rd line: It creates a new contact record, and SysID ready for use in the workflow. Alternatively, you could load another existing record or remove the current contact record and return the agent to a Search/Add New screen. How you do this depends on how the workflow is designed to work.
  • 4th and 5th lines: They are examples of clearing down any workflow variables that may have been trigged through the workflow for the previous contact record.
  • Last line: It navigates the agent back to the start screen ready to process the next contact record.