sql - How to summarize two tables in teradata -
i have following 2 tables
i need create table summarize points each date
how can . have updraded teradata 14 . , not quite familiar new functions
if table1 few rows don't need fancy query.
assuming table1.caseid byteint result in product join:
select t2.datex, t2.caseid, sum(t1.points) table1 t1 join table2 t2 on position(trim(t1.caseid) in t2.caseid) > 0 group 1,2
of course if normalized table simple use t1.caseid = t2.caseid join instead.
Comments
Post a Comment