an automated select query viewer