Comments (3)
@stevenconnorg Hi! Thanks for reporting this. There is indeed a way to create a custom version of measure_avg
for Redshift only. Macros that work differently in different databases are called cross-database macros. Under the hood, dbt dispatches macro calls to the database adapter (e.g., redshift) you are using; if there's an adapter specific version of the macro available then that is used but if not, a default implementation for the macro is used. Here's an example: https://docs.getdbt.com/reference/dbt-jinja-functions/dispatch#a-simple-example
So, what we need here is a redshift__measure_avg
macro that customizes the avg logic for Redshift. I'd very much like if you could contribute this yourself and I'll help you out as needed. What do you think? :)
from dbt-profiler.
@stumelius -- thanks for the help! I've linked a PR that will add this functionality. Let me know if you need anything else from me atm!
from dbt-profiler.
@stevenconnorg FYI https://github.com/data-mie/dbt-profiler/releases/tag/0.8.1
from dbt-profiler.
Related Issues (20)
- Include/exclude metrics
- Is this stable? HOT 1
- CTE Query Optimization HOT 4
- Question: running dbt run-operation print_profile_docs prints log info HOT 2
- Question: Are you planning to extend dbt-profiler for dbt-sqlserver adapter? HOT 2
- Using print_profile on dbt sources HOT 4
- Allow user to specify a where clause for the source table
- Question: add TOP x column values and distribution. HOT 3
- Feature request: Handling structs HOT 1
- I have modified some of the macros to work with MySql HOT 1
- Catch-22 with docblock in schema file HOT 4
- Suggestion to modify `sed` to `awk` in update-relation-profile.sh HOT 1
- docblock is not outputted when executing `print_profile_docs` with BigQuery
- Run profiler for all models HOT 2
- Add `print_table` macro that works in dbt Cloud
- Error when profiling a table in Redshift HOT 9
- "Value overflow in a SUM aggregate" with HASH fields HOT 4
- `dbt_profiler.get_profile` doesn't seem to work with views in Redshift HOT 5
- Old version of example output, without median column HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from dbt-profiler.