Modified DB

few logical bugs removed from the old db