LPS-32143 fix SQL not compatible with Oracle