I have a flat file that contains a list of people's name. I need to split the last name into a new column when executing sql loader.
Here's the tricky part. I need to split out the surename if it's uppercase base on the following scenarios.
| Original Name | Surename split |
|---|---|
| THOMAS Young | THOMAS |
| SMITH Lucas (A.K.A Luca SMITH) | SMITH |
| Dan bin Islam bin Al-BALUSHI | BALUSHI |
| James GORDON-LOPEZ | GORDON-LOPEZ |