removed sprintf from query