如何在Firebase Analytics事件中报告参数 [英] How to report parameters in Firebase Analytics Events

查看:512
本文介绍了如何在Firebase Analytics事件中报告参数的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我曾经在FabriciOS中使用过FabriciOS,在这样的情况下,在同一分析事件中如此容易地报告自定义参数是这样的:

I've used Fabric with iOS before where it was so easy to report custom parameters in the same analytics event in like this:

Answers.logCustomEvent(withName: "saved_border", customAttributes: ["image_index":"\(index)"])

现在我正在尝试对Firebase Events做同样的事情,但是我只能在控制台中看到事件名称(没有自定义参数) 这是我的代码:

Now I'm trying to do the same with Firebase Events but I see only event names in console (without custom parameters) Here my code:

Analytics.logEvent("saved_border",parameters: ["saved_image": index])

除了将索引附加到事件名称之外,是否可以用Firebase创建相同内容?

Is there any way creating same with Firebase except appending index to event name?

推荐答案

TL; DR

您必须告诉 Firebase 开始在控制台中跟踪特定事件的特定参数.

You have to tell Firebase to start tracking that specific param for that specific event in the console.

用于Firebase的Google Analytics(分析)中,每个事件可以添加的参数总数以及总数限制. 到今天为止,此限制在全球范围内最多可包含100个参数(50个数字和50个文本).

In Google Analytics for Firebase there exists a limit on how many parameters you can add per event, and in total. As of today, this limit is up to 100 parameters globally (50 numeric and 50 text).

也就是说,由于存在限制, Firebase 会强制您指定要跟踪的参数,因此,如果您发送的参数超过100个,您仍然可以跟踪这些参数您决定,但排除其他人. 只有您明确指定要跟踪的参数才会显示在 Firebase 控制台中,因此,为了开始查看这些参数,您必须执行以下操作:

That being said, because of having a limit, Firebase forces you to specify which parameters you want to be tracked, so in case you send more that 100 different parameters, you can still track the ones you decide, while excluding the others. Only the parameters you explicitly specify to track are going to be shown in the Firebase console, so in order to start seeing that parameters, you will have to do the following:

  1. 转到 Firebase 控制台
  2. 转到事件部分
  3. 确定您的活动(在您的情况下为saved_border)
  4. 单击该参数的3点图标
  5. 点击修改参数报告
  6. 最后添加您的参数名称saved_image
  1. Go to Firebase console
  2. Go to Events section
  3. Identify your event (saved_borderin your case)
  4. Click on the 3 dots icon for that parameter
  5. Click on Edit parameter reporting
  6. Finally add your parameter name saved_image

完成后, Firebase 将开始显示该事件的参数.

Once done, Firebase will start showing up that parameter for that event.

有关此信息以及事件中自定义参数的其余限制的更多信息, Google 在此处进行了说明:

For more information about this, as well as the rest of the limitations regarding to custom params in events, Google explains it here: https://support.google.com/firebase/answer/7397304?hl=en

我认为此限制仅影响 Firebase 控制台,而不影响 BigQuery .因此,尽管您超出了参数限制,但您不会在控制台中看到它们,但我认为您仍然可以通过 BigQuery 访问所有那些缺少"的事件和参数,前提是您正在使用它并且它是否已与 Firebase

I think that this limitation only affects to the Firebase console, but not to BigQuery. So, although if you exceed the parameters limit, you will not see them in the console, I think that you could still access all those "missing" events and parameters via BigQuery, if you were using it and had it already linked with Firebase

这篇关于如何在Firebase Analytics事件中报告参数的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆