Correct the script to work in Pentaho CE and EE.