client side timeout

Is there a way to specify a timeout from the client side if the queryhas been running for a long time?I don’t want to set -T on the server globally for all clients. I onlywant certain clients to time out. I’m thinking that the check shouldbe done on the client side. Anyone know of a way to do this?