Check for Dummy data (String comparison)

Database
Enthusiast

Check for Dummy data (String comparison)

I have a table 'RAW_AML_ACCOUNT_JUN' which has 'ACCT_FIRST_NAME' field. I would like to check if there is any dummy data in the first name. for example:

#,$,@,&,!,?,:-

Or if there are digits in the name (0 to 9)

Or if there are strange name like: zzzzzzzjohn

I want to see all results whether the comarison string = the whole value of the first name of partial. can someone help?

Tags (1)
2 REPLIES
Enthusiast

Re: Check for Dummy data (String comparison)

You could use the following to return records that contain ONLY alpha characters:

SELECT * FROM RAW_AML_ACCOUNT_JUN WHERE REGEXP_INSTR(RAW_AML_ACCOUNT_JUN.ACCT_FIRST_NAME, '^[a-zA-Z]+$') <> 1

As for you `zzzzzzzzjohn` example... Without a rule for identifying strange first names, I can't imagine there is anything you can do here. 

Enthusiast

Re: Check for Dummy data (String comparison)

Fair enough, that works fine, i also used

thank you for your help