DB bug fix

totlen & maxlen not intialized in Open_DB