Main file for database input system