自定义维度无法在Google Analytics中使用

时间:2021-11-27 15:14:53

I have a problem with setting up & showing Google Analytics Custom Dimensions. I have successfully setup a dimension in the web interface called "Client" In code I am sending a view properly like this:

我在设置和显示Google Analytics自定义维度时遇到问题。我已经在Web界面中成功设置了一个名为“Client”的维度。在代码中,我正确地发送一个视图,如下所示:

    [tracker setCustom:1 dimension:@"Client"];
    [tracker sendView:@"my view"];

GAI dispatch says that data has been sent successfully. But when I try to view my data in reporting - Screens tab and apply "Client" dimension. All my data disappear from table saying "There is no data for this view." Also there are some bugs when switching number of rows per page.

GAI dispatch表示数据已成功发送。但是当我尝试在报告中查看我的数据时 - 屏幕选项卡并应用“客户端”维度。我的所有数据都从表中消失,说“此视图没有数据”。每页切换行数时也会有一些错误。

Anyone who has custom dimensions successfully applying, how you do that?

有自定义尺寸成功申请的人,你是怎么做到的?

2 个解决方案

#1


1  

Did you define a segment with a condition that matches your dimension value? It did the trick for me.

您是否定义了条件与维度值匹配的细分市场?它为我做了伎俩。

See this guide for creating segments: https://support.google.com/analytics/answer/3124493?hl=en

有关创建细分的信息,请参阅此指南:https://support.google.com/analytics/answer/3124493?hl = zh-CN

You can select the segment you've created in the reports, and if the dimension was set correctly and GA received data correctly, then your segment should show hits.

您可以选择在报告中创建的细分,如果维度设置正确且GA正确接收数据,则您的细分应显示匹配。

Note that you might see data with a delay of a day or so.

请注意,您可能会看到延迟一天左右的数据。

#2


0  

I just did some Google Analytics development recently, for SDK 3.0, but I was struggling as well with the custom dimensions. One important thing to note is that custom dimensions are set once, and then with all the calls they are automatically passed, so you can set them when you are initializing all the Google Analytics classes.

我最近刚刚为SDK 3.0进行了一些Google Analytics开发,但我在自定义维度方面也遇到了困难。需要注意的一件重要事情是自定义维度设置一次,然后自动传递所有调用,因此您可以在初始化所有Google Analytics类时设置它们。

Is also important to note that in your example you are saying that the Custom Dimension with key 1 will have the value Client. So in your backend you should see for the key "Client" the value "Client", considering that the "Client" key corresponds to the value 1.

同样重要的是要注意,在您的示例中,您说使用键1的自定义维度将具有值Client。因此,在您的后端,您应该看到键“客户端”的值为“客户端”,因为“客户端”键对应于值1。

Have you tried the debugging of google analytics, so you can be sure you are sending the right URL?

您是否尝试过调试google analytics,以确保发送正确的URL?

For more help, can you give us a screenshot of the backend where you defined the custom dimensions? Is just a flag you have to enable, as you can see in this page: https://developers.google.com/analytics/devguides/collection/ios/v2/advanced#testing

有关更多帮助,您能否为我们提供定义自定义尺寸的后端的屏幕截图?只是您必须启用的标记,如此页面所示:https://developers.google.com/analytics/devguides/collection/ios/v2/advanced#testing

#1


1  

Did you define a segment with a condition that matches your dimension value? It did the trick for me.

您是否定义了条件与维度值匹配的细分市场?它为我做了伎俩。

See this guide for creating segments: https://support.google.com/analytics/answer/3124493?hl=en

有关创建细分的信息,请参阅此指南:https://support.google.com/analytics/answer/3124493?hl = zh-CN

You can select the segment you've created in the reports, and if the dimension was set correctly and GA received data correctly, then your segment should show hits.

您可以选择在报告中创建的细分,如果维度设置正确且GA正确接收数据,则您的细分应显示匹配。

Note that you might see data with a delay of a day or so.

请注意,您可能会看到延迟一天左右的数据。

#2


0  

I just did some Google Analytics development recently, for SDK 3.0, but I was struggling as well with the custom dimensions. One important thing to note is that custom dimensions are set once, and then with all the calls they are automatically passed, so you can set them when you are initializing all the Google Analytics classes.

我最近刚刚为SDK 3.0进行了一些Google Analytics开发,但我在自定义维度方面也遇到了困难。需要注意的一件重要事情是自定义维度设置一次,然后自动传递所有调用,因此您可以在初始化所有Google Analytics类时设置它们。

Is also important to note that in your example you are saying that the Custom Dimension with key 1 will have the value Client. So in your backend you should see for the key "Client" the value "Client", considering that the "Client" key corresponds to the value 1.

同样重要的是要注意,在您的示例中,您说使用键1的自定义维度将具有值Client。因此,在您的后端,您应该看到键“客户端”的值为“客户端”,因为“客户端”键对应于值1。

Have you tried the debugging of google analytics, so you can be sure you are sending the right URL?

您是否尝试过调试google analytics,以确保发送正确的URL?

For more help, can you give us a screenshot of the backend where you defined the custom dimensions? Is just a flag you have to enable, as you can see in this page: https://developers.google.com/analytics/devguides/collection/ios/v2/advanced#testing

有关更多帮助,您能否为我们提供定义自定义尺寸的后端的屏幕截图?只是您必须启用的标记,如此页面所示:https://developers.google.com/analytics/devguides/collection/ios/v2/advanced#testing