Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
171 views
in Technique[技术] by (71.8m points)

google bigquery - How to create a report in Biquery with param.key value “action” & “label” in two different columns

Queried param.key “action” with string values via through big query by using below query and fetch the report

select event_name, param.value.string_value as action,count(*) as eventcoun From <table>, UNNEST (event_params) as param where event_name = 'BotNav' and param.key='action' group by 1,2 order by eventcount desc

Output received through bigquery

event_name action eventount

BotNav Home 3575

BotNav App 1468

Queried param.key “label” with string values via through big query by using below query and fetch the report

select event_name, param.value.string_value as action,count(*) as eventcoun From <table>, UNNEST (event_params) as param where event_name = 'BotNav' and param.key='label' group by 1,2 order by eventcount desc

output received through bigquery event_name label eventount

BotNav click 2341

BotNav submit 1234

BotNav click 1234 BotNav submit 234

How to create a report with event.param .key “action” & “label” in two different columns. I need to out in Bigquery like this. Pls. find below the expected output in bigquery

Expected Output

event_name action label eventount

BotNav Home click 2341

BotNav Home submit 1234

BotNav App click 1234

BotNav App submit 234

Pls Help to get the action & label string value in two different columns.

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)
Waitting for answers

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...