Conversation
|
| Check | Result | Details |
|---|---|---|
| SQL Quality | 3 issues in 1 files |
⚠️ 3 warnings
| # | File | Line | Issue | Fix |
|---|---|---|---|---|
| 1 | models/marts/dim_products.sql |
11 | SELECT * detected — explicitly list columns for clarity and performance | Replace SELECT * with an explicit column list, e.g. SELECT id, name, status FROM ... |
| 2 | models/marts/dim_products.sql |
56 | SELECT * detected — explicitly list columns for clarity and performance | Replace SELECT * with an explicit column list, e.g. SELECT id, name, status FROM ... |
| 3 | models/marts/dim_products.sql |
59 | Possible correlated subquery in WHERE clause — consider rewriting as a JOIN for better performance | Rewrite the correlated subquery as a JOIN or use a CTE to materialize the subquery result |
🔍 Altimate Code v0.3.0 · Configure · Feedback
|
|
||
| with products as ( | ||
|
|
||
| select * from {{ ref('stg_products') }} |
There was a problem hiding this comment.
💡 Suggestion: Replace SELECT * with an explicit column list, e.g. SELECT id, name, status FROM ...
| @@ -46,3 +54,7 @@ final as ( | |||
| ) | |||
|
|
|||
| select * from final | |||
There was a problem hiding this comment.
💡 Suggestion: Replace SELECT * with an explicit column list, e.g. SELECT id, name, status FROM ...
| select * from final | ||
|
|
||
| {% if is_incremental() %} | ||
| where revenue_date > (select max(revenue_date) from {{ this }}) |
There was a problem hiding this comment.
💡 Suggestion: Rewrite the correlated subquery as a JOIN or use a CTE to materialize the subquery result
Converted
dim_products.sqlto incremental materialization using merge strategy onrevenue_date.This is a simulated PR for testing altimate-code-actions.