Commit 985bcd08 authored by đinh thị đầm's avatar đinh thị đầm

edit searchIndividualCustomer

parent b8bd8545
...@@ -1585,16 +1585,18 @@ public class CustomerServiceImpl implements CustomerService { ...@@ -1585,16 +1585,18 @@ public class CustomerServiceImpl implements CustomerService {
sb.append("with cusPhone as ("); sb.append("with cusPhone as (");
sb.append(" select customer_id cusId,"); sb.append(" select customer_id cusId,");
sb.append(" contact phone"); sb.append(" listagg(contact, ',') within group (order by create_date desc) phone");
sb.append(" from customer_contact cc"); sb.append(" from customer_contact cc");
sb.append(" where cc.contact_type = 5"); sb.append(" where cc.contact_type = 5");
sb.append(" and status = 1"); sb.append(" and status = 1 ");
sb.append(" group by customer_id");
sb.append(" ), cusEmail as ("); sb.append(" ), cusEmail as (");
sb.append(" select customer_id cusId,"); sb.append(" select customer_id cusId,");
sb.append(" contact email"); sb.append(" listagg(contact , ',') within group(order by create_date desc) email");
sb.append(" from customer_contact cc"); sb.append(" from customer_contact cc");
sb.append(" where cc.contact_type = 2"); sb.append(" where cc.contact_type = 2");
sb.append(" and status = 1"); sb.append(" and status = 1 ");
sb.append(" group by customer_id");
sb.append(" )," + sb.append(" )," +
"cusInCampaign as (" + "cusInCampaign as (" +
"select * from campaign_customer " + "select * from campaign_customer " +
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment