two places you can do it.
first, and much recommended is to use the SUBSTR function of mysql. this way you only get the data you need, nothing more.
examples from the manual.
mysql> SELECT SUBSTRING('Quadratically',5);
-> 'ratically'
mysql> SELECT SUBSTRING('foobarbar' FROM 4);
-> 'barbar'
mysql> SELECT SUBSTRING('Quadratically',5,6);
-> 'ratica'
mysql> SELECT SUBSTRING('Sakila', -3);
-> 'ila'
mysql> SELECT SUBSTRING('Sakila', -5, 3);
-> 'aki'
mysql> SELECT SUBSTRING('Sakila' FROM -4 FOR 2);
-> 'ki'
the other would be to use php's [man]substr/man function. works much the same way, but your throwing away memory compared to only getting what you need from your query.