More functions and db creation.