All pastes #910741 Raw Edit

Something

public text v1 · immutable
·published 2008-02-20 04:14 UTC
rendered paste body
select distinct a.customer_code as stores 
   from sh_transaction 
   where year(a.invoice_date)=2008 and 
       month(a.invoice_date)=1 as a
inner join 
 b. customer_code as b.stores from sh_transaction 
   where year(b.invoice_date) = 2008 and 
      month(b.invoice_date)=2
 as b on a.stores = b.stores