Your suggestion accounts for the query string, but not the parameters that must accompany it. Perhaps, I could push a hash reference onto the queue, with the hash containing 1) the SQL statement, and 2) an array of parameters.
I would tack on another level to the hash which would contain the connection the query was supposed to go out on - else you will have to handle multiple queues if you have multiple connections.