-Added a global counter and added items to the database.