So are you getting different results for the data from the db2 prompt vs DBI? Your example and question are missing key points that allow anyone to answer. What output are you looking for, what output are you getting? are you asking how to take the output and decrypt it? if so what encryption are you using (as it would matter). Please describe your problem a little better.