Thank you all for responding. You have given me some great information.
I am currently working on a project with a co-worker and acourse me being new to the unix scripting world. Would someone be able to advise on the following.
1. List1: Extract the legal name of each emplyee from the HR list using these guidlines:
a. Skip middle initials, and titles such as Jr. or III, etc.
b. Convert 'firstname lastname' to lowercase only.
c. Sort the list
d. Check for duplicate name (may be different employees with same first & last names).
2. List2: Extract the user names of every mailbox on usx011:
a. Modify scripts in /root/scripts/sunshine96 (fb2sys and mb2name) to extract a listing of every 'firstname lastname' of the mailboxes on usx011.
b. Convert to 'firstname lastname in lowercase only.
c. Sort the list
3. Use a looping to compare these two lists.
a. Loop1 with a read command to save the first employee name in List1 to Variable1.
b. While still in Loop1, start loop2 to read in the EACH employee name in List2 to Variable2, until a match is found.
c. Compare Variable1 to Variable2.
1. If same, put in Report1 --> The employee's legal name is the same as the mailbox name.
2. If different, put in Report2 --> The employee name spelling is in the HR dtabase, but may be spelled fifferently in OpenMail.
d. Once the first name has been compared and put in either Report1 or Report2, the Loop1 should read the next name record (Step 3.a) and compare it to EACH record in List2 (Step 3.b), continuing until every name is List1 has been compared to every name in List2.
4. After completing and falling out of the loops above, create a loop that compares one name at a time from List2 to EACH name in List1, using similar steps as for above.
a. Only when a name exists in List2, but NOT in List1, put it in Report3 --> These are mailbox names that do not match a legal name of any employee.
b. Determine which names from Report3 are generic accounts.
c. Determine which names from Report3 are contractor accounts.
d. Determine which names from Report3 are active employees who use a different mailbox name thatn the legal name provided by the HR database.
5. Extract, in similar fashion as step 1, the names of employees by Site by Site to be migrated off of USX011.
Your help would be greatly appreciated.
Reg,
Sunshine96