Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Aloha batch file to automatically export hourly reports to CSV

Status
Not open for further replies.

mrgoodfellow

Programmer
Nov 9, 2011
3
thread693-1239547

I am attempting to create a batch file for Aloha that will download my daily Hourly report and save it out in a CSV file.

I saw this thread on batch file report printing but I'm not sure what commands I need to set the save as directory and file type.
I would also like this to be relative to today's date so I endup with reports looking like this:

20110101.csv
20110102.csv
20110103.csv...

and so on.

Thanks in advance for the help.
 
I found this forum with the batch file solution to getting today's date:


FOR /F “TOKENS=1* DELIMS= ” %%A IN (‘DATE/T’) DO SET CDATE=%%B
FOR /F “TOKENS=1,2 eol=/ DELIMS=/ ” %%A IN (‘DATE/T’) DO SET mm=%%B
FOR /F “TOKENS=1,2 DELIMS=/ eol=/” %%A IN (‘echo %CDATE%’) DO SET dd=%%B
FOR /F “TOKENS=2,3 DELIMS=/ ” %%A IN (‘echo %CDATE%’) DO SET yyyy=%%B
SET date=%yyyy%%mm%%dd%

so what I have so far is:

D:\Aloha\BIN\rpt.exe /date %date /RH
 
Since you are into scripting...
This is one of the best sources for scripting on the net. batch vbs... you name it, there is something for everyone here

Lots of nice little helper exe's to streamline your work


I'm going to take the following I got from your link and tinker with it a bit to see about getting a csv output somehow. You should be able to parse it in excel but I know your looking for a single solution. The following is just so I can keep up with the syntax.


%IBERDIR%\BIN\RPT.EXE /DATE 20000107 /XC /LOAD "DEFAULT.SLS.SET
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top