Looking for up-to-date Help documentation? Documentation for the latest releases of Totara is now available at totara.help!

Visit the new Help site

On this page


This will import historical completion records from a CSV file and enrol users into the specified courses.

All completions imported that relate to courses that currently exist on the system will be added as Record of Prior Learning (RPL Completions). This will be indicated in reports which include these imported completions.

Evidence can optionally be created for any courses in the import which do not exist in the system.

When uploading a course completion record for a pre-existing course and where a user is not already enrolled, the system will create a manual enrolment for this user in to the course.

Upload completion records

  1. To access the upload area, go to Quick-access menu > Courses and categories > Upload completion records > Upload course records / Upload certification records.
  2. The CSV import file is created outside of Totara and imported. The date format, delimiter and encoding type will be selected before importing. The CSV file should contain the following columns in the first line of the file:
    • username: The username from the Learner’s profile.
    • courseshortname: The course short name found on the Course settings page.
    • courseidnumber: The course ID number found on the Course settings page.
    • completiondate: The date the Learner completed the course. The date format can be specified in the upload settings.
    • grade: The grade the Learner received in the course.
  3. You can drag and drop the file onto the page or click the Choose a file button to select the CSV file.
    • Create evidence: If you check this box then any courses/certifications that aren't found in the system will be recorded as evidence in the Record of Learning.
    • CSV Date format: Select the format dates will use.
    • CSV Grade format: Select the grade format used (see more detail below).
    • CSV Values separated by: Select the delimiter used in the file. Comma, semi-colon, colon or tabs can be used.
    • CSV Text Delimited with: Select the delimiter used for text values. Single quote, double quote or no delimiter can be used.
    • CSV file encoding: Select the type of encoding used for the file.
    • Override current course completions: Select if you want the uploaded course completions to replace the existing course completion records all the time, never, or only if more recent. Find out more about this setting below.
    • Case insensitive shortnames: When enabled, course short names will be matched case insensitively.

      We strongly advise any case issues be corrected in the uploaded file as this will cause performance issues.

  4. Click the Upload button.

After you have uploaded the file the import will be processed on the next cron run. To view more detail about the import, click the Course import report link. You can also access imported records by navigating to Quick-access menu > Courses > Upload completion records > Course import report.

Note that you can also create evidence items when uploading completions. If you are creating evidence using a non-default evidence type, the CSV file can also contain custom field data mapped to the fields defined in the chosen evidence type.

Evidence types must first be created in the system (Quick-access menu > Evidence) and the Available for completion import setting must be enabled.

You can then select the evidence type on the course completions upload page, and any custom fields will appear underneath as 'customfield_shortname'. You can only upload evidence using a single evidence type at a time.

Course record upload results.

A sample of the file is shown below.

Example course completions file.

You can alternatively upload CSV files via a directory on the server, see more below.

CSV grade format

Select the grade format used in the CSV file:

  • Real: Grade as points
  • Percentage: Grade as a percentage

Take an example of a course with three activities, so the maximum grade for the course is 300, and upload a course completion CSV file with a grade of 60. The system reports the grade as follows, depending on how the grade column is handled in a report:

  • Real: 60 points or 20.0%
  • Percentage: 180 points or 60.0%

Note that both current learning and previous completions in the Record of Learning page display a grade as percentage.

Override current course completions

When uploading a course completion CSV file, the system looks up an existing completion record and compares its completion date against the incoming completion date.

OverrideBefore existing completiondateAfter existing completiondateIdentical to existing completiondateNo previous completionsIn Totara 12
NeverHistoricalHistoricalDo nothingInsert currentUnticked
AlwaysOverride currentOverride currentOverride currentInsert currentN/A
If more recentHistoricalOverride currentDo nothingInsert currentTicked

Using a directory on the server

If you'd like users to be able import completion data form a file already uploaded to the server. They can follow the link Alternatively upload CSV files via a directory on the server at the bottom of the Upload Completion Records page. The user will need to know the full path to the file to be imported. Be aware that this file will be deleted after import.

In order to use this functionality, you will need to add a value for $CFG->completionimportdir to the config.php file. This should be set to the beginning of the path to the uploaded files. The path that the user enters in the form must begin with this value. Be aware that the user would also be able to enter the path to any file that begins with the value given in the config setting and that file would subsequently be deleted.

Reset report data

From time to time it may be useful to clean up the course and certification upload logs, especially if you are having problems with uploading new records. You can clean up your records by going to Courses > Upload Completion Records > Reset Report data from the Administration block. Use the check boxes to select Reset course report data and/or Reset certification report data.

You can also set up a scheduled task for clearing out the course/certification report data from the Administration menu by going to Server > Scheduled tasks.

Archiving completion records

Once a record of prior completion has been uploaded for a user they will need to have this record archived before they can attempt the course again, just as with any completion record. You can find more information about this on the Course completions Help page. 

Totara Academy

The Totara Academy has a whole course dedicated to using Courses and categories in Totara Learn. 

Provide feedback about this page using the link in the bottom right of this page. 

 Still have questions? 

Why not post them in the forums on the Totara Community?

  • No labels