Territories : Deluge and APIs
I am trying to work out how to filter a deluge query by territory eg
- "SELECT Total_Amount, Stage, Closing_Date, Created_Time, Deal_Name FROM
Deals WHERE Stage in (" + varBaseCriteria + ") AND Territory = 'Territory1'"
The problem being that Territory isn't saved against the Deals table.
I can't seem to find anything that will give me a list of what deals are in what Territory.
I've thought about using a workflow to add the Territory to a text field on the Deals record, but don't seem to be able to access any of the Territory fields that way - then I run in to the same issue which is not being able to return a list of what Deals are in what Territories.
What am I missing ?
Why can't I report on this with Deluge ?