Merge query - sql extract

Is there a way to extract merge query at the backend. What actually looker does behind the scenes to do a merge. Is there a way one can fetch that query or see what is actually going on there. @Looker 

Solved Solved
0 3 268
1 ACCEPTED SOLUTION

I'm sure it's going to be a left join in all cases, with the base explore on the left side. You can probably verify that experimentally!

View solution in original post

3 REPLIES 3

If you go to the 'History' explore in System Activity, you can see exactly what queries were merged, what fields they were joined on, and so forth. If you substitute your instance name into the URL below, it should return this info for you.

[YOUR_INSTANCE.COM]/explore/system__activity/history?fields=merge_query.formatted_pivots,merge_query.created_date,merge_query.hash,merge_query.id,merge_query.dynamic_fields,result_maker.merge_query_id,result_maker.is_merge_query,merge_query_source_query.id,merge_query_source_query.is_primary_query,merge_query_source_query.merge_fields,merge_query_source_query.name,merge_query_source_query.query_id&sorts=merge_query.formatted_pivots&limit=500&column_limit=50

@GavinW  Really appreciate your reply. Could you also point out which logic is being used by looker "merge query", like is it a left join or right join by definition or a simple merge ?. I am actually looking for actual merge definition.

I'm sure it's going to be a left join in all cases, with the base explore on the left side. You can probably verify that experimentally!

Top Labels in this Space
Top Solution Authors