registration and db part