SQL notebook has to contain only one return select.
<aside>
💡 The expected schema is only the entity ID column. The columns to be exported are defined in config.yaml
.
</aside>
Basic segment definition
select
customer_id
from
hive_metastore.odap_features.customer
where
transactions_sum_amount_in_last_30d >= 50000 and
investice_web_visits_count_in_last_90d > 0
Segment definition with custom source
select
c.customer_id
from
hive_metastore.odap_features.customer as c
join
loans as l
on
c.customer_id = l.customer_id
where
c.transactions_sum_amount_in_last_30d >= 50000 and
c.investice_web_visits_count_in_last_90d > 0