简体   繁体   English

使用BigQuery的Firebase

[英]Firebase with BigQuery

I have a really hard time understanding how to register custom event and then visualize them in BigQuery. 我很难理解如何注册自定义事件,然后在BigQuery中可视化它们。 Since the Google IO conference, I can't find anything detailed about the process other than those conference video that are really basic and broad... 自谷歌IO会议以来,除了那些非常基本和广泛的会议视频之外,我找不到任何有关该流程的详细信息......

How can I register a custom data in a Firebase Event and then see it in BigQuery? 如何在Firebase事件中注册自定义数据,然后在BigQuery中查看?

    Bundle bundle2 = new Bundle();
    bundle2.putString(FirebaseAnalytics.Param.ITEM_CATEGORY, "tab_open");
    bundle2.putString(FirebaseAnalytics.Param.ITEM_NAME, "profil");
    mFirebaseAnalytics.logEvent(FirebaseAnalytics.Event.SELECT_CONTENT, bundle2);

Or another example: 或者另一个例子:

Bundle params = new Bundle();
params.putString("email", email);
params.putString("name", name);
mFirebaseAnalytics.logEvent("profil", params);

How to access those value inside firebase? 如何在firebase中访问这些值? Also, I did a lot of bad test which flood my Firebase with wrong data, can I erase an event type ? 另外,我做了很多不好的测试,我的Firebase充斥着错误的数据,我可以删除一个事件类型吗?

You're logging the events correctly, but it takes about 5 hours for events to show up in your Firebase Dashboard from the time they occur (more details from the Firebase Analytics PM in this answer: Firebase Analytics upload delay ) 您正在正确记录事件,但事件发生时Firesen仪表板中显示的事件大约需要5个小时(此答案中Firebase Analytics PM的更多详细信息: Firebase Analytics上传延迟

Here's an example query to find the number of times each custom event has occurred: 以下是查找每个自定义事件发生次数的示例查询:

SELECT event_dim.name, COUNT(event_dim.name) as event_count FROM [your_dataset.your_table]
GROUP BY event_dim.name
ORDER BY event_count DESC

You can't delete rows from a BigQuery table, but since a new table is created every day, you can just stop logging an event and filter your results starting from a specific date. 您无法从BigQuery表中删除行,但由于每天都会创建一个新表,因此您可以停止记录事件并从特定日期开始过滤结果。 Alternatively, you could reprocess the tables and remove the old events. 或者,您可以重新处理表并删除旧事件。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM