1

support linked fields in the Summarize option Display of Query fields

Right now in the UI when you a create a Query field, you can only specify fields that live directly on the Entity type you're querying to Summarize in the Display options.  I need the ability to summarize fields on entities *linked* to the queried entity.  You can do this in the API readily.

For example, let's say I have a bunch of Versions.  Each Version has a numeric frame_count on it.  Some of those Versions are entered in a single-entity field on some Shots, the field being named sg_hero_animation.  Let's say I want to have a Query field on another entity, let's say a Sequence, that sums up the frame counts for all the Hero Animation Versions on the Shots in the Sequence.

In the API, I could just do:

sg.summarize(
    'Shot',
    filters=[], # some Shot selection filters here...
    summary_fields=[{'field': 'sg_hero_animation.Version.frame_count', 'type': 'sum'}],
   grouping=[{'field': 'sg_sequence', 'type': 'exact', 'direction': 'asc'}])

Boom, I get a dict with a 'groups' key with the frame_count summaries per-Sequence (plus a handy top-level 'summaries' key with a grand total).

But the UI for a Query field doesn't let me do the Linked Fields equivalent of that dot-syntax.  Sad!

 

0 comments

Please sign in to leave a comment.