grade/import/smart/index
Supported File Types
The LSU Smart File Importer accepts many file types of varying extension (.csv, .txt, or no extension at all) and auto detects between the various supported file types.
Below you will find a quick description of each file type followed by a more detailed description.
At LSU, we call idnumber LSUID and username PAWSid. Please substitute accordingly.
If you want to change any of the following formats for use outside of LSU (most are useful as is), please edit classes.php.
Fixed Width Formats
Fixed Width
89XXXXXXX 100.00 89XXXXXXX 090.00
MEC (Measurement and Evaluation Center)
XXX89XXXXXXX 100.00 XXX89XXXXXXX 090.00
The fixed width file formats are generally .txt files or files without an extension (coming from alternate sources) and use spaces as a method of creating the appearance of columns.
Comma Separated idnumber File Formats
Anonymous Number
XXXX, 100.00 XXXX, 90.00
Comma seperated grade file keyed with idnumber that contains extra information
89XXXXXXX, F, L, M, shortname, data, time, XX, XX, 100.00 89XXXXXXX, F, L, M, shortname, data, time, XX, XX, 90.00
Comma seperated grade file keyed with idnumber that contains random extra information
89XXXXXXX, {any number of fields}, 100.00 89XXXXXXX, {any number of fields}, 90.00
Grade file with comma-separated values keyed with idnumber
89XXXXXXX, 100.00 89XXXXXXX, 90.00
Grade file from the Maple software package
Irrelevant line<br /> Irrelevant line<br /> Name, 89XXXXXXX, Grade %, Grade, Weighted %, Blank Field<br /> Name, 89XXXXXXX, Grade %, Grade, Weighted %, Blank Field<br /> Irrelevant line<br /> Irrelevant line
The CSV idnumber files generally come with .csv but the extension is not important with this importer.
Comma Separated username File Formats
Comma seperated grade file keyed with username that contains extra information
username, F, L, M, shortname, data, time, XX, XX, 100.00 username, F, L, M, shortname, data, time, XX, XX, 90.00
Comma seperated grade file keyed with username that contains random extra information
username, {any number of fields}, 100.00 username, {any number of fields}, 90.00
Grade file with comma-separated values keyed with username
username, 100.00 username, 90.00
The CSV username files generally come with .csv but the extension is not important with this importer.
Tab-delimited idnumber File Formats
Tab-delimited grade file keyed with idnumber
89XXXXXXX 100.00 89XXXXXXX 90.00
Tab-delimited grade file keyed with idnumber that contains extra information
89XXXXXXX F, L M shortname data time XX XX 100.00 89XXXXXXX F, L M shortname data time XX XX 90.00
The Tab-delimited idnumber files generally come with .txt but the extension is not important with this importer.
Tab-delimited username File Formats
Tab-delimited grade file keyed with username
username 100.00 username 90.00
Tab-delimited grade file keyed with username that contains extra information
username F, L M shortname data time XX XX 100.00 username F, L M shortname data time XX XX 90.00
The Tab-delimited username files generally come with .txt but the extension is not important with this importer.
Import Instructions
- Using the file upload dialog, choose a grade file from your filesystem.
- Click the "Validate File(s)" button.
- The importer will attempt to validate that file and find which format it is.
- If your file does not validate, you must fix any formatting errors in it.
- Once your file is validated, fix any idnumber errors that exist by using the interface that will pop up using the idnumber mapping system.
- Using the "Grade Item Mapping" select box, choose a grade item to map the soon the be imported grades to.
- You may add new files using the green "+" and red "-" buttons.
- Once all of your files are validated and you have selected grade item mappings for them, click the "Upload validated file(s) button.
- On the next screen, you will most likely be shown a success message.
- Any errors that occurred during the import will be reported as well.
Installation
- Copy the smart folder into your moodle_root/grade/import/ folder
- Copy the lang/en_utf8/gradeimport_smart.php file to your appropriate language folder
- Set permissions accordingly
- Enjoy!