Automated teller machine with a database