cancel
Showing results for 
Search instead for 
Did you mean: 

Validation req no.2

Former Member
0 Kudos

Hi,

I want to write a validation on Identification no.

The format is like first 3 are numer from 0 to 9 and then there are alphabets any from a to Z.

Help!!

Brad

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi ,

U can write in the following ways:

1) If there is not a space b/w nos and alphabets

HAS_ALL_CHARS( MID(‪Id no.‬,1,3),"0","9") AND HAS_ALL_CHARS( MID(Id no.‬,3),"a","Z")

2)If space is there and no of alphabets are not constant:

HAS_ALL_CHARS(MID(‪Id no,1,3),"0","9") AND HAS_ALL_CHARS( MID(‪Id no‬,FIND(‪Id no‬," ")),"a","Z")

Hope this may help u .

I have not run this expression.Kindly check them if they are working

Rgds

Ankit

Former Member
0 Kudos

Hi,

The length of the field is 8 and there is a - b/w numbers and alphabets .

Brad

Former Member
0 Kudos

Hi,

In this case u can write as

LEN(‪Id no.‬)= 😎 AND HAS_ALL_CHARS( MID(‪Id no.‬,1,3),0,9) AND HAS_ALL_CHARS( MID(Id no.‬,5),"a","Z") AND (MID(Id no.,4,1) = "-")

Hope this may help u.

Ankit

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi Braddy,

IF(LEN(Identification no)=8, HAS_ALL_CHARS( LEFT(Identification no,3),0,9) AND (MID(Id no.,4,1) = "-") AND HAS_ALL_CHARS( RIGHT(Identification no,4),"a","Z"),FALSE)

Please award accordingly

Thanks,

Mandeep Saini

Former Member
0 Kudos

Hi,

It must work.

IF(LEN(Identification no)=8, HAS_ALL_CHARS( LEFT(Identification no,3),0,9) AND (MID(Id no.,4,1) = "-") AND HAS_ALL_CHARS( RIGHT(Identification no,4),"a","Z")

REWARDS IF USEFUL.....

THANKS,

MANDEEP SAINI

Edited by: Mandeep Saini on Jul 23, 2008 12:30 PM

Former Member
0 Kudos

Hi Brad,

U can use the HAS ALLCharacters and MID or Find property of MDM data manager.They are given on page no. 240-245.

I will try top wrie and then give the expression.Just u also try to write.

Rgds

Ankit