Use trim() , que vem em 3 sabores:
select trim(leading CHAR(0x00) from data)
ou
select trim(trailing CHAR(0x00) from data)
ou
select trim(both CHAR(0x00) from data)
select trim(leading CHAR(0x00) from data)
select trim(trailing CHAR(0x00) from data)
select trim(both CHAR(0x00) from data)