Select Statement with RegEx Replace - DB2 9.7
You could use the the 


  replace


function like this:

select replace('Text   with  random      spaces', '  ', ' ') 
  from yourtable


The second argument shows two spaces and the third is a single blank.

EDIT:

For multiple blanks this sould work - natively:

SELECT c1, length(c1), xmlquery('fn:replace($c,"[ ]+", " ")'  PASSING c1 AS "c") 
  FROM test1