Tuesday, 20 December 2022

Sort through an array of duplicates

The following Google Apps Script is designed to go through an array of values that contains duplicates and create a new array of only the unique ones, arranged alphabetically. I needed this code when looping through files in a Google Drive folder where tutors and their groups formed part of the filename that I needed to extract for the end file that was created.

Remove array duplicates
Remove array duplicates

Tuesday, 6 December 2022

Bulk combine CSV files into a single Google Sheet

The following Google Apps Script is designed to take a number of CSV files (structured in an identical way) stored in a Google Drive folder and combine them all into a single Google Sheet file. It maps the data within the CSV file to specific cells in the Google Sheet, along with creating a tab for each of the CSV files to separate them out.

This blog post is a development of my previous one on importing CSV data into (multiple) Google Sheet files.

Bulk combine CSV files into a single Google Sheet
Bulk combine CSV files into a single Google Sheet