in reply to Not Able to fetch file from ftp server using net::SFTP

Net::SFTP's manual states this:

$local is optional. If not provided, the contents of the remote file $remote will be either discarded, if get is called in void context, or returned from get if called in a non-void context. Presumably, in the former case, you will use the callback function \&callback to "do something" with the contents of $remote.

you need to specify a local filename to save remote file to. (and make sure destination dirs exist before saving)

bw, bliako

  • Comment on Re: Not Able to fetch file from ftp server using net::SFTP

Replies are listed 'Best First'.
Re^2: Not Able to fetch file from ftp server using net::SFTP
by sachin raj aryan (Sexton) on Dec 13, 2019 at 07:32 UTC

    thanks a lot for such a good explaination ...Issue resolved !!!<\p>