I am trying to loop through some directories to read a single file. Each directory will have the same file available in it, 'trip_end_details.csv'. I've found a few posts on how to do it, but none of them work
Where n is a number from 0 - 9, My load scripts is below:
SET NWS_base_folder = 'lib://some_path/NetworkSim/';
For each vSubDir in DirList('$(NWS_base_folder)') For sim_no = 0 to 9 LOAD * FROM [$(NWS_base_folder)/$(vSubDir)/($sim_no)/trip_end_details.csv] (txt, codepage is 28591, embedded labels, delimiter is ',', msq); Next Next
My problem is, No data is being loaded. I have tried the load script for each subfolder, and this loads the data.
I've tried setting the base_folder to the full path on the drive, ie 'C:\Users\.....\NetworkSim\'