Add transaction and make create_db_con private