Ravindra BagaleCourses & study guides मराठी Track your progress

9. Get Data from Folder: Monthly Bank Statements Walkthrough

Friends, in an office a new file arrives every month – Jan.xlsx, Feb.xlsx... Copy-paste every month? Not at all! In this module we combine monthly bank statements from one folder, and set it up so that a new file comes in automatically with a refresh.

What you will learn in this module

  • Combining many files with the same structure from one folder
  • What the helper queries (Parameter, Sample File, Transform Sample File, Transform File) do
  • Cleaning bank-statement quirks: header rows, opening/closing lines, Dr/Cr, amounts with commas
  • Getting the month from Source.Name, skipping hidden/temporary files
  • Handling a file with an extra column or different headers
  • Automatic refresh when next month's file is dropped in (local folder and SharePoint folder)

Live story: Twelve bank statements in one folder

Suppose we help a small Pune shop owner who sells on Swiggy and Blinkit. Every month the bank sends one CSV statement. After a year there are 12 files. We want one table of all 12 months, and next month's file should join by itself. This chapter uses Get Data from Folder to combine files once and refresh forever.

All numbers in this story are fictional practice data.

Every month, Ravindra Bagale downloads his savings-account statement as an Excel file: Jan.xlsx, Feb.xlsx, Mar.xlsx … He wants one Power BI table with all transactions to track spending on Blinkit and Amazon Now, UPI transfers, ATM withdrawals and salary credits. The same technique works for monthly Blinkit order exports (Module 7.20).

Fictional data

The bank ("Example Bank"), account number, narrations, reference numbers and amounts below are invented for practice.

Concepts in this chapter

  1. 9.1The Files and Their Layout
  2. 9.2Connect to the Folder
  3. 9.3Filter Out Hidden, Temporary and Unwanted Files
  4. 9.4Combine Files and the Helper Queries
  5. 9.5Clean One File in Transform Sample File
  6. 9.6Add Month from Source.Name and Categorise Transactions
  7. 9.7A File with an Extra Column or Different Headers
  8. 9.8Automatic Refresh When a New Month Arrives

Review and practice

  1. ★Practice and Answer Key: Combine Files from a Folder

The chapter recap is at the end of the last concept page.

Ravi Sir's Cards: 10 revision, interview and comparison cards for this chapter · मराठी cards