Hi,
No advanced coding needed
I would recommend: creating two attributes of the material code object.
1. For first letters
2. For rest of letters
Load them with data using formulas in transformation.
(for example an ABAP Left function for choosing two letters looks like this : LEFT( 2, GL_ACCOUNT) )
Regards, Leszek