I have a question
Suppose we a model and we have intermediate tables in them, for debugging purpose i want count of rows of those intermediate table formed before the final select statement, how to do this?
Consider the code
with data as (
select * from {{ source(‘db’, ‘lookup’) }}
),
filtered as (
select * from data where forb_ind = ‘N’
),
filter2 as (
select * from filtered where cycle_ind = ‘Y’
)
select * from filter2;
So from here i want to log count of data, filter, filter2 in terminal