I need to be able to generate run a query that will return the next value of ID on the following table:
CREATE TABLE animals ( id MEDIUMINT NOT NULL AUT
You could add your own MySQL function - as demonstrated at http://www.microshell.com/database/mysql/emulating-nextval-function-to-get-sequence-in-mysql/ - allowing you to do something like this:
SELECT nextval('sq_my_sequence') as next_sequence;