Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello
I am trying to load a csv that have email server log, this file have several fields, the receiver field have severeal email address separated by ";". I want to geneate a new record with each receiver email addres, for example i have the next line in the file:
date | sender | recipient | server | subjet |
01/05/2016 | usr1@pp.com | usr2@pp.com;usr3@pp.com;usr4@pp.com; | host1 | xxx |
i need to generate a 3 records one for each recipient, all the fields have the same value but the field recipiend have only one recipient.
for example the result of the above line will be:
date | sender | recipient | server | subjet |
01/05/2016 | usr1@pp.com | usr2@pp.com | host1 | xxx |
01/05/2016 | usr1@pp.com | usr3@pp.com | host1 | xxx |
01/05/2016 | usr1@pp.com | usr4@pp.com; | host1 | xxx |
anybody know how i can split one field in three new records
thanks in advance for your help
best regards
dcd
Hello,
Trust that you are doing well!
Please refer below given sample script:
Data:
LOAD date, sender, SubField(recipient, ';') AS recipient, server, subject;
LOAD * INLINE [
date, sender, recipient, server, subject
01/05/2016, usr1@pp.com, usr2@pp.com;usr3@pp.com;usr4@pp.com, host1, xxx
];
Also refer the application file attached herewith.
Regards!
Rahul
Hello,
Trust that you are doing well!
Please refer below given sample script:
Data:
LOAD date, sender, SubField(recipient, ';') AS recipient, server, subject;
LOAD * INLINE [
date, sender, recipient, server, subject
01/05/2016, usr1@pp.com, usr2@pp.com;usr3@pp.com;usr4@pp.com, host1, xxx
];
Also refer the application file attached herewith.
Regards!
Rahul
Subfield(recipient,';') as recipient
it works fine, thanks for your quickly answer.
best regards
dcd
It Works fine
Thanks very much for your Answer
Best Regards
dcd