Focal Point
Uploading excel files and archiving them with datetimestamp

This topic can be found at:
https://forums.informationbuilders.com/eve/forums/a/tpc/f/1381057331/m/8347035526

October 26, 2012, 06:47 AM
MartijnZ
Uploading excel files and archiving them with datetimestamp
L.S.

We have several excel-files which we receive on a monthly basis.

We have built a flow to upload the data in theses files to a SQL-table in our DWH using DataMigrator.
We have also built a postprocessing procedure to move the uploaded excelfile to an archive-folder
and add a datetime-stamp to the filename.

The postprocessing produre has the following code:
-SET &STAP1= STRIP(19, &DATEHYYMDS, '/', 'A17');
-SET &STAP2= STRIP(17, &STAP1, ':', 'A15');
-SET &STAP3= STRIP(15, &STAP2, ' ', 'A14');
-SET &STEMPEL = &STAP3 || '.';
 
COPY d:\extern\tbl_kostensoort_wf01.xls d:\extern\Backup_WKR\tbl_kostensoort_wf01_&STEMPEL.xls
DEL  d:\extern\tbl_kostensoort_wf01.xls


I wonder:

A. Is there a way using less programmingcode to get the current datetime in an amper variable in a numeric format?

B. Is there a way to move the excelfile without the DOS-codes COPY en DEL?

Kind regards,
Martijn Zwarts


WebFOCUS 7.7
Windows, All Outputs
October 26, 2012, 12:43 PM
dhagen
-SET &T = '_' || &YYMD || '_' || EDIT(HHMMSS('A8'),'99$99$99');
 APP COPYF BASEAPP ATEST EXCEL BASEAPP ATEST&T EXCEL
 APP DELETEF BASEAPP ATSET EXCEL
-RUN  



"There is no limit to what you can achieve ... if you don’t care who gets the credit." Roger Abbott