support functions in select-list on queries that do pk lookups

Also made the ESGetTask standalone so it doesn't require an additional
MergeTask.

In addition the plan for insert from query has changed so that it will always
use QueryAndFetch to avoid handler round-trips.
sry, misread that.