Add mongodb connection and preliminary querying