[1.7.x] Fixed an Oracle test failure introduced by 1e404180c1.

Backport of e98c5513cb from master