ripe-farmer-22631
01/18/2024, 2:00 PMrhythmic-agent-34208
01/18/2024, 6:17 PMrhythmic-agent-34208
01/18/2024, 6:18 PMearly-france-54892
01/18/2024, 7:10 PMintraday
in our BigQuery but we are not using it in our assignment query.early-france-54892
01/18/2024, 7:11 PMWITH
__rawExperiment AS (
SELECT
user_pseudo_id as anonymous_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,
geo.country as country,
traffic_source.source as source,
traffic_source.medium as medium,
device.category as device,
device.web_info.browser as browser,
device.operating_system as os
FROM
`weezietowelsdaton`.`analytics_279996039`.`events_*`,
UNNEST (event_params) AS experiment_id_param,
UNNEST (event_params) AS variation_id_param
WHERE
(
(_TABLE_SUFFIX BETWEEN '20231130' AND '20240118')
OR (
_TABLE_SUFFIX BETWEEN 'intraday_20231130' AND 'intraday_20240118'
)
)
AND event_name = 'experiment_viewed'
AND experiment_id_param.key = 'experiment_id'
AND variation_id_param.key = 'variation_id'
AND user_pseudo_id is not null
),
__experimentExposures AS (
-- Viewed Experiment
SELECT
e.anonymous_id as anonymous_id,
cast(e.variation_id as string) as variation,
CAST(e.timestamp as DATETIME) as timestamp
FROM
__rawExperiment e
WHERE
e.experiment_id = 'ab-quiz-test'
AND e.timestamp >= '2023-11-30 15:57:00'
AND e.timestamp <= '2024-01-18 19:02:14'
),
__experimentUnits AS (
-- One row per user
SELECT
e.anonymous_id AS anonymous_id,
(
CASE
WHEN count(distinct e.variation) > 1 THEN '__multiple__'
ELSE max(e.variation)
END
) AS variation,
MIN(e.timestamp) AS first_exposure_timestamp
FROM
__experimentExposures e
GROUP BY
e.anonymous_id
),
__distinctUsers AS (
SELECT
anonymous_id,
cast('All' as string) AS dimension,
variation,
first_exposure_timestamp AS timestamp,
date_trunc(first_exposure_timestamp, DAY) AS first_exposure_date
FROM
__experimentUnits
),
__metric as ( -- Metric ([Octane AI] Quiz ROUND ONE - Question Wh)
SELECT
anonymous_id as anonymous_id,
1 as value,
CAST(m.timestamp as DATETIME) as timestamp
FROM
(
SELECT
user_pseudo_id as anonymous_id,
TIMESTAMP_MICROS(event_timestamp) as timestamp
FROM
`weezietowelsdaton.analytics_279996039.events_*`
WHERE
(
(_TABLE_SUFFIX BETWEEN '20231130' AND '20240121')
OR (
_TABLE_SUFFIX BETWEEN 'intraday_20231130' AND 'intraday_20240121'
)
)
AND event_name = '[Octane AI] Quiz ROUND ONE - Question Wh'
) m
WHERE
m.timestamp >= '2023-11-30 15:57:00'
AND m.timestamp <= '2024-01-21 19:02:14'
),
__userMetricJoin as (
SELECT
d.variation AS variation,
d.dimension AS dimension,
d.anonymous_id AS anonymous_id,
(
CASE
WHEN m.timestamp >= d.timestamp
AND m.timestamp <= DATETIME_ADD(d.timestamp, INTERVAL 72 HOUR) THEN m.value
ELSE NULL
END
) as value
FROM
__distinctUsers d
LEFT JOIN __metric m ON (m.anonymous_id = d.anonymous_id)
),
__userMetricAgg as (
-- Add in the aggregate metric value for each user
SELECT
variation,
dimension,
anonymous_id,
MAX(COALESCE(value, 0)) as value
FROM
__userMetricJoin
GROUP BY
variation,
dimension,
anonymous_id
)
-- One row per variation/dimension with aggregations
SELECT
m.variation AS variation,
m.dimension AS dimension,
COUNT(*) AS users,
SUM(COALESCE(m.value, 0)) AS main_sum,
SUM(POWER(COALESCE(m.value, 0), 2)) AS main_sum_squares
FROM
__userMetricAgg m
GROUP BY
m.variation,
m.dimension
early-france-54892
01/18/2024, 7:29 PMevent_name = 'experiment_viewed'
AND experiment_id_param.key = 'experiment_id'
AND variation_id_param.key = 'variation_id'
It should be noted that there is no occurrence of an event_name equal to 'experimat_viewed'. Is the query intended to be executed in its current state?brief-honey-45610
01/18/2024, 8:53 PMevent_name
column in your data source and for the value therein to be "experiment_viewed". What do you have configured instead?early-france-54892
01/18/2024, 9:01 PMevent_name
column in the data source, but there is no value that matches "experiment_viewed."early-france-54892
01/18/2024, 9:02 PMbrief-honey-45610
01/19/2024, 5:05 PMexperiment_viewed
events are not being tracked or sent to the data source. To resolve this issue, ensure that the experiment_viewed
event is being sent with the correct event name.
1. Verify that your application code is correctly configured to send the experiment_viewed
event. This event should be sent whenever a user is exposed to an experiment.
2. If the event is not being sent, update the tracking code to include the experiment_viewed
event. Here's an example of how you might send this event using a trackingCallback:
trackingCallback: function (experiment, result) {
dataLayer.push({
'event': 'experiment_viewed',
'event_category': 'experiment',
'experiment_id': experiment.key,
'variation_id': result.variationId
});
}
ripe-farmer-22631
02/06/2024, 5:53 PMripe-farmer-22631
02/09/2024, 6:35 PMripe-farmer-22631
02/12/2024, 8:30 PMripe-farmer-22631
02/15/2024, 1:44 PM