implementation of feature request #1363

improved query profiler