Dear All,
I need some help re a scenario:
So the issue is like this:
1. There are users in SQL (with short name e.g. sas, asd, dsa) these are 3 letter names or some are 2 letters, but never more than 3.
2. In the form there are 2 fields : First Name & Last Name
3. Based on the First & Last Name the short name is to be generated or suggested
4. The suggestion should be checked with existing short names & if exist then based on the rule (as below 5 rules) should suggest the new short name.
Rules for short name creation:
Example: Max Muster
Rule 1: 1st letter of the first name, 1st + 2nd. Letter of surname: mmu
If short-name already exists, the following rules come into effect:
Rule 2: 1. + 2. Letter of first name, 1st letter of surname: mam
Rule 3: 1. + 2. + 3. Letter of surname: mus
Rule 4: 1st letter of the first name, 1st + last letter of the last name: mmr
Rule 5: 1. + last letter of first name, 1st letter of last name: mxm
The new suggested name should be populated in the short name field so the user can actually see it.
Thanks in advance for your help!!!
Regards,
Sahil