Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
aytacbas
Contributor III
Contributor III

New customer grouping

Hi All;

I've a table  and it has 3 values customer_id, Order_id and Order_date ;

I want to find  new customers rate daily


How can I do that?

2 Replies
ramoncova06
Specialist III
Specialist III

you can use peek for this

load

if(customer_id = peek('customer_id'), 0, 1) as NewCustomerFlag,

customer_id,

Order_id,

Order_date

order by customer_id,Order_date;



load

customer_id,

Order_id,

Order_date

from your source;


buzzy996
Master II
Master II

u can use Ramon script and use that flag in ur chart object with NewCustomerFlag='0' and do the rest of calculations.