Dear Statlisters,
I have a folder that containf 40 csv files (OAEX1 to OAEX40). the first cilucolumnm is the same for all of them but the second column is different. the columns are not named. i have tried the code and other codes i found but in vain. your help is much appreciated
Code:
 cd "/Users/aarredouani/Documents/csv"
clear
tempfile building
save `building', emptyok

local myfilelist : dir . files"*.csv"
foreach file of local myfilelist {
drop _all
insheet using `"`file'"'
local building = subinstr("`file'",".csv","",.)
merge using "`building'"
save `building', replace
}
Macrpo stat 15.1