Advanced techniques
This section illustrates some advanced techniques you can use to extend the functionality of combined queries.
Time-proximity search
When building combined queries, you can use the proximity
parameter to extend the lower and upper boundaries of each subquery. This parameter is expressed in seconds.
Note that the proximity
parameter can only be used when your combined query is composed of two or more subqueries.
The following example code uses the and
operator and the proximity
parameter to find all car accidents that happened within 30 seconds before someone wins a race:
The following output was truncated for brevity:
Specify the order of the matching video clips
The example code below uses the then
operator to find the moments in your videos where the following occur in the specified order:
- A player makes a long pass.
- A player dribbles past a defender.
The following example output was truncated for brevity:
The example code below combines the then
and or
operators to find all the moments in your videos where the following occur in the specified order:
- A player makes a long pass or the words “amazing pass” are mentioned in the conversation
- A player dribbles past a defender.
The following example output was truncated for brevity: