bug fixes

fixed bug in database creator and updateAA