TAJO-974: Eliminate unexpected case condition in SubQuery. (Hyoungjun Kim via hyunsik)

Closes #974