Sorry , i think this kind of sorting is pointless as when we go to groups more than 2, like for ex 111,222,333 and there’s a common values in each group. It is impossible to sort the way i want.
For ex:
| GN | JMBWN | Name |
|---|---|---|
| 1 | BBBB | Arun |
| 1 | BBBB | Ashwin |
| 1 | CCCC | Vishwa |
| 2 | DDDD | John |
| 2 | BBBB | Sam |
| 2 | DDDD | Jain |
| 3 | FFFF | Maria |
| 3 | BBBB | Santhosh |
| 3 | FFFF | Jaison |
In this table it is impossible to group BBBB together while maintaining the order in the first column.
Sorry to waste your time regarding this.