<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: [resolved] Using tSCPPut component in Talend Studio</title>
    <link>https://community.qlik.com/t5/Talend-Studio/resolved-Using-tSCPPut-component/m-p/2328330#M97620</link>
    <description>Thank you very much, this helps a lot!&lt;BR /&gt;Another question I had was, say in this case, if I want to create "new_dir/tmp/folder1" directory, where "tmp" directory doesn't exist, then even "folder1" directory won't get created right?&lt;BR /&gt;So I will need to follow the hierarchy and create directories as I go along, and then copy the files?</description>
    <pubDate>Wed, 15 May 2013 13:42:09 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2013-05-15T13:42:09Z</dc:date>
    <item>
      <title>[resolved] Using tSCPPut component</title>
      <link>https://community.qlik.com/t5/Talend-Studio/resolved-Using-tSCPPut-component/m-p/2328328#M97618</link>
      <description>Hi, 
&lt;BR /&gt;I have a list of files with a certain extension (say .abc) under my local system in the directory (C:\tmp\folder1\one.abc, c:\tmp\folder2\two.abc) and so on.. 
&lt;BR /&gt;I want to transfer each such folder into a remote machine using the SCP components (tSCPPut to be precise). What I have observed is that if I have a folder called "/root/temp/" as the Remote Directory that exists inside the remote machine, only the files are put one after another (I am fetching list of files through tFileLIst). 
&lt;BR /&gt;However if I need to put them into a non-existent directory, say "/root/temp/output/", I am unable to do so, and the error "Caused by: java.io.IOException: Remote scp terminated with error (scp: /root/temp/output/: No such file or directory)." pops up. 
&lt;BR /&gt;This means that a non existent directory is not created automatically during copying of the files. 
&lt;BR /&gt;Can anyone guide me to an alternative to this? How can I make use of the tJava component to remotely create a directory and then copy the files? 
&lt;BR /&gt;I am looking to copy the files into remote locations "/root/temp/output/folder1/one.abc", "/root/temp/output/folder2/two.abc" and so on. 
&lt;BR /&gt; 
&lt;IMG src="https://community.qlik.com/" /&gt;</description>
      <pubDate>Tue, 14 May 2013 14:00:23 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/resolved-Using-tSCPPut-component/m-p/2328328#M97618</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2013-05-14T14:00:23Z</dc:date>
    </item>
    <item>
      <title>Re: [resolved] Using tSCPPut component</title>
      <link>https://community.qlik.com/t5/Talend-Studio/resolved-Using-tSCPPut-component/m-p/2328329#M97619</link>
      <description>Indeed this option to create a remote directory is highly missing. As long as we have that, you could check if the remote directory exists with tSCPFileExists. 
&lt;BR /&gt;Use the run if connector and set as condition: 
&lt;BR /&gt;"File exists.".equals((String)globalMap.get("tSCPFileExists_1_STATUS")) == false 
&lt;BR /&gt;Yes I know, this looks silly, but unfortunately this component is not very well designed. 
&lt;BR /&gt;This small job shows checks if the directory "new_dir" under the user home exists and if not it will be created. 
&lt;BR /&gt; 
&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009MEVT.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/129368i4F7E2A50F2347ABC/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009MEVT.png" alt="0683p000009MEVT.png" /&gt;&lt;/span&gt; 
&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009MEVY.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/143022i557D04F1EA5709A3/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009MEVY.png" alt="0683p000009MEVY.png" /&gt;&lt;/span&gt;</description>
      <pubDate>Tue, 14 May 2013 21:16:30 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/resolved-Using-tSCPPut-component/m-p/2328329#M97619</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2013-05-14T21:16:30Z</dc:date>
    </item>
    <item>
      <title>Re: [resolved] Using tSCPPut component</title>
      <link>https://community.qlik.com/t5/Talend-Studio/resolved-Using-tSCPPut-component/m-p/2328330#M97620</link>
      <description>Thank you very much, this helps a lot!&lt;BR /&gt;Another question I had was, say in this case, if I want to create "new_dir/tmp/folder1" directory, where "tmp" directory doesn't exist, then even "folder1" directory won't get created right?&lt;BR /&gt;So I will need to follow the hierarchy and create directories as I go along, and then copy the files?</description>
      <pubDate>Wed, 15 May 2013 13:42:09 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/resolved-Using-tSCPPut-component/m-p/2328330#M97620</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2013-05-15T13:42:09Z</dc:date>
    </item>
    <item>
      <title>Re: [resolved] Using tSCPPut component</title>
      <link>https://community.qlik.com/t5/Talend-Studio/resolved-Using-tSCPPut-component/m-p/2328331#M97621</link>
      <description>Unfortunately your are right. You have to follow from the root to the leaf. Typically I build that in a component and I think it would be a great idea to add this function into the tSCPPut component.&lt;BR /&gt;Hint: I would start wit a check if your target structure exists and go back to the root. It is often the situation, that only one or two of the last directories are missing.</description>
      <pubDate>Wed, 15 May 2013 21:33:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/resolved-Using-tSCPPut-component/m-p/2328331#M97621</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2013-05-15T21:33:29Z</dc:date>
    </item>
    <item>
      <title>Re: [resolved] Using tSCPPut component</title>
      <link>https://community.qlik.com/t5/Talend-Studio/resolved-Using-tSCPPut-component/m-p/2328332#M97622</link>
      <description>Yes, you're correct, it usually is for creating one or two leaf directories.
&lt;BR /&gt;I found a command to create such directories that do not exist. We can use "mkdir -p root/temp/new_dir/folder1". What this will do is, create folder1, new_dir and temp folders, if it doesn't already exist.
&lt;BR /&gt;Thanks again for your prompt reply and help!</description>
      <pubDate>Thu, 16 May 2013 09:36:06 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/resolved-Using-tSCPPut-component/m-p/2328332#M97622</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2013-05-16T09:36:06Z</dc:date>
    </item>
    <item>
      <title>Re: [resolved] Using tSCPPut component</title>
      <link>https://community.qlik.com/t5/Talend-Studio/resolved-Using-tSCPPut-component/m-p/2328333#M97623</link>
      <description>Thanks a lot, I will use your hint about the mkdir option.</description>
      <pubDate>Thu, 16 May 2013 20:18:20 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/resolved-Using-tSCPPut-component/m-p/2328333#M97623</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2013-05-16T20:18:20Z</dc:date>
    </item>
    <item>
      <title>Re: [resolved] Using tSCPPut component</title>
      <link>https://community.qlik.com/t5/Talend-Studio/resolved-Using-tSCPPut-component/m-p/2328334#M97624</link>
      <description>You can call "mkdir -p" and all the subdirectories will automatically be made.</description>
      <pubDate>Wed, 17 Sep 2014 21:38:13 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/resolved-Using-tSCPPut-component/m-p/2328334#M97624</guid>
      <dc:creator>_AnonymousUser</dc:creator>
      <dc:date>2014-09-17T21:38:13Z</dc:date>
    </item>
  </channel>
</rss>

