allocation now answers back to the database and runs perfectly