troubleshooting Question

How do I redirect output from psftp command

Avatar of Rita Byrne
Rita ByrneFlag for Ireland asked on
Microsoft SQL ServerSSH / Telnet SoftwareMicrosoft SQL Server 2005
4 Comments1 Solution3042 ViewsLast Modified:
I created a file (contents below) via tsql stored procedure and ran it via ftp -s:

open server_ip
cd /itadmin/PostIngres/Billpay/
verbose off
ls EUWCC* D:\Integra\BILLPAY\WORKING\ftp_file_list.dat

I need to do the same except using sftp so I downloaded putty sftp (called via psftp on command line) - however I can't redirect the out to a file on the server like in ftp  "ls EUWCC* D:\Integra\BILLPAY\WORKING\ftp_file_list.dat" and when I use ls or dir in psftp I get

drwxr-x--- 2 ftpadmin ftpadmin        0 May 17 13:31 .
drwxr-x--- 2 ftpadmin ftpadmin        0 May 15 10:11 ..
-rwxr-x--- 1 ftpadmin ftpadmin    21018 May 17 13:31 EUCO213110501.DAT
-rwxr-x--- 1 ftpadmin ftpadmin    11779 May 17 13:21 EUWEX.DAT
-rwxr-x--- 1 ftpadmin ftpadmin        0 May 15 11:43 This is wexccuser

instead of just the file names?

Our community of experts have been thoroughly vetted for their expertise and industry experience.

Join our community to see this answer!
Unlock 1 Answer and 4 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 4 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros