Refactored DatabaseAdapters for simplicity and smaller methods.