× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Use the General Email Regex (RFC 5322 Official Standard)

Example:
dcl-s myEMail varchar(50) inz('mailme@xxxxxxxxxx');
dcl-s myCount int(5) inz;
dcl-c myRegex

'(?:[a-z0-9!#$%&?*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&?*+/=?^_`+

{|}~-]+)*|?(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21\x23-\x5b\x5d+

-\x7f]|\\[\x01-\x09\x0b\x0c\x0e-\x7f])*?)@(?:(?:[a-z0-9](?:+

[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?|\+
[(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}(?:25+

[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?|[a-z0-9-]*[a-z0-9]:(?:+

[\x01-\x08\x0b\x0c\x0e-\x1f\x21-\x5a\x53-\x7f]|\\[\x01-\x09+
\x0b\x0c\x0e-\x7f])+)\])';

exec sql
set :myCount = regexp_count( :myEmail, :myRegex);

If myCount = 1;
dsply 'ok';
else;
dsply 'false';
endif;

-----Ursprüngliche Nachricht-----
Von: RPG400-L [mailto:rpg400-l-bounces@xxxxxxxxxxxxxxxxxx] Im Auftrag von
Timothy Feldmeier
Gesendet: Freitag, 4. Dezember 2020 16:21
An: 'RPG400-L@xxxxxxxxxxxxxxxxxx'
Betreff: Does anyone know of an API to validate an email address?

I have a screen for the user to enter email addresses. Sometimes they enter
a typo. It would be nice to have an API, instead of writing code for the
validation of an email address.


Thank You

Tim Felmeier
Programmer Analyst For Coyote System
Roadrunner Transportation Systems
1431 Opus Place, Suite 530
Downers Grove, IL 60515
Phone# (331)-2337921
Timothy.Feldmeier@xxxxxxxx

[RRTS_transportation SYSTEMS]


The information transmitted is intended only for the person or entity to
which it is addressed and may contain proprietary, business-confidential
and/or privileged material. If you are not the intended recipient of this
message you are hereby notified that any use, review, retransmission,
dissemination, distribution, reproduction or any action taken in reliance
upon this message is prohibited. If you received this in error, please
contact the sender and delete the material from any computer.

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.