https://www.growthbook.io/ logo
#ask-questions
Title
# ask-questions
c

crooked-telephone-14504

01/02/2024, 11:35 AM
Hi there team 👋 potentially new growthbook user here, i’m trying to setup a test experiment but i’m a bit lost in how growthbook generates the result reports… i’m probably doing something wrong but can’t quite figure out what it is on my own, i’ll add more infos on the query metrics and db structure in the thread but the main thing is: • we setup growthbook java sdk and completed the connection steps, we are able to successfully get feature flag values out of growthbook • we setup a test experiment with 2 variant (3 with control) • our experiment is a simple conversion test, we setup a binomial metric to track users that have seen a specific page, then we want to track how many of those users convert, based on the specific variant of the page that was served • we track the conversion with a second binomial metric as can be seen in the screenshot, we get users assigned to the variants but growthbook never “detects” a conversion, hope someone is able to help me understand how to configure the metrics properly
As datasource we are using a redshift db, that currently only stores data for this test experiment we have 2 tables: • sessions - this table stores the user sessions that have seen the page we want to track, and also stores which variant was served • conversions - this table stores successful conversions, together with a session_id which is the same one we have in the sessions table sessions table create statement:
Copy code
CREATE TABLE sessions (
    session_id INT PRIMARY KEY,
    user_id INT,
    timestamp TIMESTAMP,
    page_name VARCHAR(255),
    experiment_variant VARCHAR(50)
);
user_id
is an optional field only populated with logged in users, but we also support conversion for “guest” users in which case it would be null conversions table create statement:
Copy code
CREATE TABLE conversions (
    conversion_id INT PRIMARY KEY,
    user_id INT,
    session_id INT,
    timestamp TIMESTAMP
);
based on these 2 tables we have also setup 2 key metrics: _*page_sessions*_ which uses the following query:
Copy code
SELECT
  session_id as user_id,
  timestamp as timestamp
FROM
  sessions
conversions which uses the following query:
Copy code
SELECT
  session_id as user_id,
  timestamp as timestamp
FROM
  conversions
f

fresh-football-47124

01/04/2024, 2:30 AM
Hi Davide, What have you set for your trackingCallback in java?
oh, looks like its tracking correctly
(if you're only testing it with 7 users)
it seems like you're really close
I would suggest you view the query used and see if there is something off there
I wonder if its the conversion window
c

crooked-telephone-14504

01/04/2024, 8:07 AM
hi @fresh-football-47124 thanks for the response, we are actually now starting to see conversions, we did a couple changes and used timestamps over multiple days and now it’s working… not sure exactly what fixed it but it’s looking good now
we saw in a previous thread some other users also add variant_id to their queries so we did that too, it’s not a required column when setting up the metric but maybe that helped too
this is how it currently looks like, also showing a breakdown by dimension…. we will keep playing with it for a bit and add more questions if they come up
f

fresh-football-47124

01/04/2024, 2:27 PM
👍
4 Views