Post a reply

Options
Add an Attachment

If you do not want to add an Attachment to your Post, please leave the Fields blank.

(maximum 10 MB; please compress large files; only common media, archive, text and programming file formats are allowed)

Options

Topic review

martin

That does not seem to the the script, see get vs. put.
Can you please post a matching log and script pair?

Anyway, such script can easily generate group-only XML log. The only command that generates some actual output is get. And that may still generate no output, when there are no files to download.
andrew_an

option echo on
option batch abort
option confirm off
open sftp://*****:*****@******:22
lcd D:\ERPFTP\NOREV\OUTPUT
cd Inbox
get -resume *
exit
martin

Re: Can't get the sub elements like results in the xml log

Can you post your script?
andrew_an

Can't get the sub elements like results in the xml log

I try several times about the XML logging,
every time the log file was generated only with Group elements but without sub elements under the group elements ,normaly there should be other elements like the result of each operation,how can i get this kind of info in the log?
Version:WinSCP 5.1.3
Scirpt :
WinSCP.com /script=D:\ERPFTP\scripts\NOREV\download_script.txt /xmllog=D:\ERPFTP\logs\NOREV\results\download_%date:~5,2%%date:~8,2%%time:~0,2%%time:~3,2%.xml /xmlgroups
XML log:
<?xml version="1.0" encoding="UTF-8"?>
<session xmlns="https://winscp.net/schema/session/1.0" name="MZPB9601@mts2.mpsa.com" start="2013-01-24T02:00:01.428Z">
<group name="sftp://MZPB9601:***@mts2.mpsa.com:22" start="2013-01-24T02:00:11.584Z">
</group>
<group name="lcd D:\ERPFTP\NOREV\INPUT" start="2013-01-24T02:00:11.584Z">
</group>
<group name="cd MZPB9601" start="2013-01-24T02:00:11.584Z">
</group>
<group name="put * " start="2013-01-24T02:00:11.584Z">
</group>
<group name="exit " start="2013-01-24T02:00:11.584Z">
</group>
</session>