Source
Querying Semi-structured Data
This topic explains how to use special operators and functions to query complex hierarchical data stored in a VARIANT.
A query using a correlated column inside a window function fails with internal error 300010:391167117
CAUSE: Using a correlated column inside window function components (such as PARTITION BY or ORDER BY is not supported. In this query, the column completed_on is correlated with the lateral view f.