bug #1989081 [profiling] Profiling causes query to be executed again