Fri Dec 03, 2021 1:36 pm
Login Register Lost Password? Contact Us


How to spray multiple delimited files using DFU command?

Topics specific to the use of the ECL IDE

Thu Apr 09, 2015 7:12 am Change Time Zone

Hi,

Can anyone please tell me how to spray multiple delimited files from the Landing Zone to the THOR Cluster using DFU command from DFU Plus or ECL IDE if possible. This should spray all the files with same spray delimited options together in one shot. A reply would help.


Thanks,
Abhishek.
Abhishek_M04
 
Posts: 13
Joined: Thu Apr 09, 2015 7:02 am

Thu Apr 09, 2015 12:02 pm Change Time Zone

Hi Abishek,

In the ECL IDE, you can call the SprayVariable function successively to spray multiple times:
Code: Select all
IMPORT STD;
SrcIP    := '10.252.65.200';
SrcPath  := '//10.252.65.200/var/lib/HPCCSystems/mydropzone/snap-d126c9ba/';
Initials := 'RT';
STD.File.SprayVariable(SrcIP,SrcPath + 'embeddedxmltimezones',,'','\\>','','mythor',
                           '~CLASS::' + Initials + '::IN::EmbeddedXMLtimezones',,,,true,true);   
                           
STD.File.SprayVariable(SrcIP,SrcPath + 'imdb_movies',,'',,'','mythor',
                           '~CLASS::' + Initials + '::IN::imdb_movies',,,,true,true);   


I'm pretty sure with DFUPlus that you can spray multiple files by setting up your parameters in an INI file. Check out the associated documentation for more details.

Regards,

Bob
bforeman
Community Advisory Board Member
Community Advisory Board Member
 
Posts: 1005
Joined: Wed Jun 29, 2011 7:13 pm

Thu Apr 09, 2015 5:21 pm Change Time Zone

You can use DFU Plus to spray multiple files (using either wildcards or a comma-delimited list). But, this sprays to a single destination file. To spray many to many, you need one DFUPlus command for each file.

You can easily write a bash script or bat file to do this.

HTH,

Jim
JimD
 
Posts: 157
Joined: Wed May 18, 2011 1:35 pm

Fri Apr 10, 2015 9:59 am Change Time Zone

Thanks Bob and Jim. Yes , it worked.
Abhishek_M04
 
Posts: 13
Joined: Thu Apr 09, 2015 7:02 am


Return to ECL IDE

Who is online

Users browsing this forum: No registered users and 1 guest

cron