Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik GA: Multivariate Time Series in Qlik Predict: Get Details
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Standed Email Formate

Hi All,
How to find the given email_address is valid or in valid in talend
Is there any function to follow the standed email formate ?

Thanks
Aishu
Labels (2)
4 Replies
Anonymous
Not applicable
Author

Write a customm routine to check if email address is valid. Use the following code in the routine
String email = ?test@test.com?;
Pattern p = Pattern.compile(?.+@.+\\.+?);
Matcher m = p.matcher(email);
boolean matchFound = m.matches();
if(matchFound){
System.out.println(?EMAIL OK?);
}else{
System.out.println(?EMAIL ERROR?);
}

Tweak the code according to your needs.
Call this function/routine in more than one jobs to check if ail is valid.
Let me know if you face any issues.
Anonymous
Not applicable
Author

Forgot to mention that you will also have to import java.util.regex.* class in the routine.
Anonymous
Not applicable
Author

Hi vikram thanks for your reply .
Table contains 2 laksh records and field name is email_address.
if record contain valid email_address i want to process to target table
and also in-valid email_address i want to process target table and updating with some flag=0,

how it is possible in talend?
Thanks
Aishu
Anonymous
Not applicable
Author

Hi Aishu,
Based on your description, your job is now simple... it contains just simple insert.
Use code given by Vikram to set the flag status to 0 or 1 in context variable before tMap component
Use tMap to add flag column
Hope this is what you are looking for.
Thanks
Vaibhav