I run this query :
select trim(utl_raw.cast_to_varchar2((nlssort(d.det_entete, 'nls_sort=binary_ai')))) entete,
length(trim(utl\_raw.cast\_to\_varchar2((nlssort(d.det\_entete, 'nls\_sort=binary\_ai'))))) nb
from details\_param\_import d join param\_import\_table p on d.param\_code = p.param\_code;
It gave this result :

So how to remove the trailing space ?