fixed bug in dB-hash and BS search