Skip to Content
author's profile photo Former Member
Former Member

Mail to File Scenario

Hi Experts,

i am trying out a simple mail to file Scenario. But i am facing some issue. Pls help me to solve the issue.

My Source structure is

<Subject>subject pi</Subject>

<From><ABCD></From>

<To><XYZ></To>

<Content_Type>text/plain; charset="ISO-8859-1"</Content_Type>

<Date>2011-12-08T05:56:13Z</Date>

<Message_ID><CAABb8cU+oXFPYHc-DUaaoQfd_seEMToE=UbqZ-CLOfUw9ei8uQ></Message_ID>

<Content>content pi</Content>

This we have reed the Subject and the content of the mail. When we note the From ID we can see that the mail id is generated inside a tag i.e <ABCD> how can we avoid the tag symbol. here in Forum i am not able give a mail address so thats y i didnt mention the From and to id fully.

Regard's

Preethi.

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

1 Answer

  • Best Answer
    Posted on Dec 08, 2011 at 07:27 AM

    Hi,

    You can remove the tags in mapping using UDF...try this

    From >UDF >target

    UDF:

    int start = input.indexOf('<')') ;
    
    int end = input.lastIndexOf('>');
    
    String result = input.subString(start+1, end-1);
    
    return result;
    

    Regards,

    Priyanka

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.