DB Search bug fix

Signed-off-by: Sampath Liyanage <plbsam@gmail.com>