// replace ~count and ~total in result, if the variables specify their own full_level. This can't be replaced before firing the query.
// replace ~<level>.line.count and ~<level>.line.total in __result__, if the variables specify their own full_level. This can't be replaced before firing the query.
// this is necessary: queries 2,3,.. should not be replaced with content of resultArray but with the most recent values. So delete the entry in resultArray.