Hello Team! We set up Growthbook a while ago and ...
# ask-questions
h
Hello Team! We set up Growthbook a while ago and the feature flagging and experiment creation are working fine but we have problems with the experiment results shown in GB. Would be great if we could find the bug here together 🙂 I will provide more details in the Thread.
The problem is that the figures I get in GA4 are different from the figures I receive in GB. • In GA4 I see 3.698 total users who have seen the experiment. In GB 2.809. I always get less users in GB as in GA4 ◦ in the health tab it says "15 multiple exposures detected, but that is below your threshold of 1 %" so I think this can not be the reason. • Because of that the numbers for my metrics in the experiment results are not correct (also much less than in GA4) ◦ if I check the numbers that are returned in the metric creation view for daily sum, they are the same as in GA4.
This is our Experiment Assignment Query:
Copy code
SELECT
  user_pseudo_id as id,
  TIMESTAMP_MICROS(event_timestamp) as timestamp,
  experiment_id_param.value.string_value AS experiment_id,
  variation_id_param.value.int_value AS variation_id,
  account_type_propertie.value.string_value AS account_type,
  geo.country as country,
  device.category as device,
  device.web_info.browser as browser
FROM
  `growthbook-ga4-396012`.`analytics_308238632`.`events_*`,
  UNNEST(event_params) AS experiment_id_param,
  UNNEST(event_params) AS variation_id_param,
  UNNEST(user_properties) AS account_type_propertie
WHERE
  event_name="experiment_viewed"
  AND experiment_id_param.key="experimentID" 
  AND variation_id_param.key="experiment_variation"
  AND account_type_propertie.key="account_type"
Please let me know what other information you need.
f
Hi Janina, could it be the date ranges?
you could try running that query manually
and seeing if you remove the WHERE statements you can get it down to the right count value
h
Hi Graham, if I let this query run in BQ I get 2.949 data rows.
Copy code
SELECT
  user_pseudo_id as id,
  TIMESTAMP_MICROS(event_timestamp) as timestamp,
  experiment_id_param.value.string_value AS experiment_id,
  variation_id_param.value.int_value AS variation_id,
  account_type_propertie.value.string_value AS account_type,
  geo.country as country,
  device.category as device,
  device.web_info.browser as browser
FROM
  `growthbook-ga4-396012`.`analytics_308238632`.`events_*`,
  UNNEST(event_params) AS experiment_id_param,
  UNNEST(event_params) AS variation_id_param,
  UNNEST(user_properties) AS account_type_propertie
WHERE
  event_name="experiment_viewed"
  AND experiment_id_param.key="experimentID" 
  AND variation_id_param.key="experiment_variation"
  AND account_type_propertie.key="account_type"
  AND TIMESTAMP_MICROS(event_timestamp)>= "2024-04-25"
  AND TIMESTAMP_MICROS(event_timestamp)<= "2024-04-29"
For this I get 3.093 rows
Copy code
SELECT
  user_pseudo_id as id,
  TIMESTAMP_MICROS(event_timestamp) as timestamp,
  geo.country as country,
  device.category as device,
  device.web_info.browser as browser
FROM
  `growthbook-ga4-396012`.`analytics_308238632`.`events_*`
WHERE
  event_name="experiment_viewed"
  AND TIMESTAMP_MICROS(event_timestamp)>= "2024-04-25"
  AND TIMESTAMP_MICROS(event_timestamp)<= "2024-04-29"