Filter earlier in OPAL scripts
Problem
A query using filtering in OPAL is taking a long time or using a lot of query credits.
Solution
Move filtering verbs (such as filter, ever, or exists) as early as possible in your OPAL script.
Explanation
These verbs reduce the data volume and make downstream operations faster. Our optimizer strives to automatically perform this optimization, but it is still a good practice to do it manually.
Instead of:
make_col kvs:parse_kvs(log)
make_col cid:string(kvs.customer_id)
filter stream="stderr"
Use:
filter stream="stderr"
make_col kvs:parse_kvs(log)
make_col cid:string(kvs.customer_id)
Updated 25 days ago