Forum Replies Created

  • There could be a few reasons for discrepancies between your BigQuery data and GA4’s total events report data. One such reason could be due to data latency. BigQuery typically takes 24-48 hours for normal data availability, and GA4 data could be bit more real-time. If your timeframe is within this latency period, you could be looking at different sets of data. Similarly, data processing in BigQuery might face some delay causing event_count_via_concat, event_count_via_countif, and event_count_naive to be vastly different.

    Another reason could be the fact that GA4 also has some data processing restrictions like processing thresholds, which could be leading to exclusion of some hits from your dataset. There might be certain events which are not being recorded and hence, the mismatch.

    Your usage of count(distinct) could also cause issues if you have very large datasets, as BigQuery approximates the results for large numbers of distinct values. Also, since you’re pre-filtering the data with the WHERE clause, the GA4 might be including other events than ‘job_search__search’ in its total count.

    Also, if you’re filtering specific hostnames, please ensure those are not filtered in GA4 as well. If the filter of hostname is done at the view level in GA4, there might be further slight discrepancies.

    And lastly, it might be worth checking the device.web_info.hostname itself. If there are problematic and inconsistent entries, this could skew the data.

  • Isabella

    Member
    1 July 2023 at 10:01 am in reply to: Integrating GA4 with BigQuery for Streamlined Data Extraction

    Sure, you can achieve this by querying multiple days across the different tables. It’s simply a matter of adjusting the ‘_table_suffix’ in your SQL code to the date range you’re interested in.

    Here’s a quick example that might help:

    `
    select
    *
    from
    — replace this with your Google Analytics 4 export location in BigQuery
    ga4bigquery.analytics_(change_to_yours).events_*
    where
    _table_suffix between ‘20230101’ and ‘20230327’
    `

    The ‘_table_suffix’ represents the dates, so when you specify ‘between 20230101 and 20230327’, you’re asking for data from all of the tables (or days) within that range.

    For more details, check this [tutorial](https://www.ga4bigquery.com/tutorial-how-to-query-multiple-analytics-events-tables-with-table-suffix-ga4/). Quite handy!

  • Isabella

    Member
    17 May 2023 at 11:40 am in reply to: Troubleshooting Unmerged Data in GA4 Analytics Reports

    Absolutely! So to put it in more casual terms, your “session_id” and “engagement_time_msec” attributes need to be inputted as numbers, without any quotation marks around them. You can think of these attributes kinda like scores in a game: you wouldn’t put quotes around the number of points you scored, right? It’s the same idea here. I hope that makes sense!

    It would look something like this:

    "session_id": 1666947000,
    "engagement_time_msec": 1000
    
  • Isabella

    Member
    24 April 2023 at 6:51 pm in reply to: Creating a Filtered GA4 Custom Report for Multiple Event Names

    It seems like you’re dealing with a problem related to the maximum string length that a regex can handle. One potential solution could be to break down your events and create separate filters for each one, rather than trying to fit all 20 events into one filter. Alternatively, you might want to review your regex to see if it can be simplified or optimized in any way to reduce the length. In some cases, you might also be able to use other matching rules that are less strict than regex. If feasible, you may explore using an event-tracking platform that does not have this length limitation. These are general suggestions and you would have to see what works best in the context of your report.

  • Yes, you’re on the right track. The updated schema change by Google just means that item-scoped dimensions (like “itemName”) and event-scoped metrics (like “itemViewEvents”) can no longer be queried together directly. But you can still get the information you need.

    As an alternative to using a Custom Metric or Dimension, you can use the ‘event’ and ‘items’ fields in GA4. The ‘event’ field now represents all the user interactions (like ‘itemViewEvents’) and the ‘items’ field represents all the product-related data. The items’ field beings an array, stores the product data individually, with each item in the array representing a unique product. Now, if you want to check how many views a product got, you can map ‘itemName’ with respective ‘eventName’ which is equivalent to ‘itemViewEvents’. It might require a little bit of extra data manipulation, but you can definitely pull out the numbers you need.

  • I understand your frustration. You are facing this problem due to certain limitations within GA4’s dimensions compatibility. GA4 doesn’t allow using the dimensions dateHourMinute and pagePathPlusQueryString together. The reason is that dateHourMinute is considered a higher cardinality dimension and GA4 prevents it from being used with certain dimensions like pagePathPlusQueryString due to the massive amounts of unique combinations this would generate, leading to potential performance issues.

    While it’s true this limitation was not in UA (Universal Analytics, or “V1” as you referred to it), GA4 has a different structure and different rules about which fields can be used together.

    My recommendation is to analyze these dimensions independently, exporting two separate datasets if necessary: one with dateHourMinute, and one with pagePathPlusQueryString. Then, you could use your own processing tools like Excel or Google Sheets to combine or compare these datasets and get the insights you’re after. I know this is an extra step, but with the current API limitations, this might be the best workaround.

  • Google Analytics 4 (GA4) has a different set of parameters and data handling method compared to Universal Analytics. As you’ve noticed, GA4 doesn’t provide parameters like GeographicalOverride as it uses automated methods to detect geographical data. Sending Universal Analytics parameters as event parameters in GA4 can result in them appearing as raw keywords, as GA4 is not built to decode these.

    Your attempt to use ‘Criteria ID’ to specify geographical data adheres to Universal Analytics, not GA4. As of now, Google hasn’t provided a way to manually input this data in GA4. It’s recommended to conform to GA4 methods and parameters for optimal reporting results. If you have specific geography-oriented data input needs, consider providing feedback to Google about this issue. They might update GA4 or provide more resources based on user feedback and needs.

  • Hey Yash, once the July 1, 2023 deadline hits, the old UA Google Tag will stop collecting data. That means you will need to switch over to GA4 by installing the new tag in your codebase. As much as I understand that you wouldn’t want to meddle with your codebase, I’m afraid it’s inevitable if you want to continue collecting data with Google Analytics.

  • Isabella

    Member
    13 November 2022 at 3:56 am in reply to: Managing Analytics Configuration for UA and GA4 Reporting

    Currently, as per the official Google Developers documentation, GA4 properties only support the Google Analytics Data API (previously called the App + Web properties API). The v4 Reporting API only works with Universal Analytics (UA) properties. There’s also no direct migration path from v4 to the Data API, as they have different structures and capabilities.

    When working with both UA and GA4 reporting, you would have two different configurations. You could set up a conditional check within your PHP code that determines which set of configurations to use based on the property type. For the time being, it’s advisable to maintain your Universal Analytics Property alongside your GA4 Property, so you might need to dual-tag your site and compromise by using two separate libraries, one for each GA version, within your analytics.php file.

    Also, note that to use the Google Analytics Data API, you’ll either have to use Google’s client library (which supports PHP) or make HTTP requests to the API directly. However, I recommend watching Google’s updates closely as they are evolving their GA4 support.

  • Isabella

    Member
    13 October 2022 at 9:53 am in reply to: Trouble with populating GA4 custom dimensions in reports

    Sure! From your description, it sounds like either a delay in Google’s processing of data or an issue in how the custom dimensions are being captured or sent. One thing you could check is if the custom dimension is registered in each event where it should be sent. If it is, and you’re still not seeing data after 48-72 hours (Google Analytics can sometimes take up to 72 hours to process data), it could be an issue with the data layer. Make sure that your data layer is initialized before your GA4 gtag.js library initializes, and that the values for your custom dimensions are correctly populating in the data layer prior to sending each event. One more thing to note: make sure that you’ve set these custom dimensions at the correct level (user or event). If these tips don’t seem to solve your issue, then it might be more beneficial to seek more detailed personalized assistance, possibly Google Analytics team directly or hiring an expert who can sift through your setup to locate the issue.

  • Hey there, let’s try to untangle this!

    These two filters aren’t playing nicely together because they’re trying to apply to the same event at the same time, but your customer_type parameter is actually on a different one altogether. So imagine your GA4 is on the lookout for the event that has both "who's making a purchase" AND "the customer_type is Webonly".

    But oh dear, this is not happening because these two aren’t showing up on the same event.

    So, what can we do? A simple trick could be to put your customer_type parameter within the same scope as the user or include it directly on the purchase event. That should clear up this misunderstanding between your filters. Tada!

    Try it out and let’s see how it works.