Shift years in training data files (CSV + XLSX) by +N years — both filenames and content. Use when updating training data for a new year, "เลื่อนปี", "shift year", "update year in training data", "เปลี่ยนปีใน data", or when preparing Power BI / Excel training files for next year's course.
Shift year references in training data files (CSV, XLSX) by a specified amount. Designed for annual updates to course training data — handles filenames, CSV content (Order Numbers, dates), and XLSX year columns.
Run the bundled script which handles everything:
python "<skill-path>/scripts/shift_year.py" "<folder-path>" [--shift N]
folder-path: Directory containing the data files (CSV + XLSX)--shift N: How many years to shift (default: 1). Use negative values to shift backwards."202401011CS952" → "202501011CS952") and dates in DD/MM/YYYY format (e.g., "01/01/2024" → "01/01/2025")contoso-online-2024.csv → contoso-online-2025.csv)XLSX files:
TargetReport.xlsx)_backup/) before modifying files — the backup is placed inside the target folderUser: เลื่อนปีใน training data ไป 1 ปี folder C:\...\Contoso
Step 1: List files in the folder
Step 2: Confirm with user
Step 3: Run script
python "<skill-path>/scripts/shift_year.py" "C:\...\Contoso"
Step 4: Spot-check a few rows from each file
/xlsx-thepexcel — Read/edit XLSX files directly; use when year-shifted data needs further spreadsheet manipulation