Hey Everyone, I am facing an issue. I have a folder named new files which contains multiple xml files of clinical trial data (10,000files.)Initially i download a zipped file of it and later i unzipped it. At first i tried using macro for importing zipped xml files in the folder but was unable to do so. I used the code available on sas community site. The code didn't display any result despite of no errors. so, i thought of unzipping the folder and importing it as multiple files instead of zipped folder, but has no success. Can anyone plz suggest me ho how to deal with this. Below is my code that i used- filename inzip ZIP "/folders/myfolders/xml ct.zip"; data folder_contents; length memname $200 isFolder 8; fid=dopen("inzip"); if fid=0 then stop; memcount=dnum(fid); do i=1 to memcount; /*Scans and gives only the name of the xml file*/ memname=scan(dread(fid, i), 2, '\'); /*check for trailing / in folder name */ output; end; rc=dclose(fid); run; title "Files in the ZIP XML file"; proc print data=folder_contents noobs N; run; filename SXLEMAP "/folders/myfolders/search1.map"; libname myxml XMLV2 "%sysfunc(getoption(work))/searchResultsct.xm" xmlmap = SXLEMAP;libname out "/folders/myfolders"; data out.xml_contents; set myxml.contents ; run;
... View more