I have a CSV file that contains employee names in column A and targets in column B. I have the script to import the data into a google sheet each day. However, I only want to import column B when the trigger runs so that the sheet populates a new column with the daily updated values without adding column A.
function importCSVFromGoogleDrive() {
var ss = SpreadsheetApp.getActiveSpreadsheet();
var file = DriveApp.getFilesByName("Employee Targets.csv").next();
var csvData = Utilities.parseCsv(file.getBlob().getDataAsString().split('\r').splice(1)) ;
var sheet = SpreadsheetApp.getActive().getSheetByName("Daily Tracker");
var lastcol = sheet.getLastColumn();
sheet.getRange(1, lastcol + 1, csvData.length, csvData[0].length).setValues(csvData);
sheet.getRange(1,sheet.getLastColumn()).setValue(Utilities.formatDate(new Date(), "your_timezone", "dd-MM-yy"));
}