Production Ticket(ST) #11675
OROMEO - import the assigned merchandiser to Datanory
1) Verify the data from excel file provided by client.
2) Create query to patch all the data.
Root cause: Client request.
None
Description
Hi Kamal,
Update done, seek for your assistance to import the assigned merchandiser to Datanory system.
Btw, no merchandiser assign for EM outlet.
History
#1 Updated by Rashdan Hussin 5 months ago
- Status changed from Assigned To to Support In Progress
#2 Updated by Rashdan Hussin 5 months ago
- Status changed from Support In Progress to Pending Client Verification
- % Done changed from 0 to 90
- Actual Initial Response set to 10/05/2024
- Resolution updated (diff)
--create table #TempTableCustUser (
-- customer_code varchar(50),
-- user_code varchar(50)
--)
select * from #TempTableCustUser
select * from #TempTableCustUser where customer_code not in (select customer_code from customer where org_id = 'oromeo')
select * from #TempTableCustUser where user_code not in (select member_cd from member where org_id = 'oromeo')
select * from #TempTableCustUser a
inner join customer b on b.customer_code = a.customer_code and b.org_id = 'oromeo'
inner join member c on c.member_cd = a.user_code and c.org_id = 'oromeo'
where not exists(select 1 from customer_to_user_relation r where r.org_id = 'oromeo' and b.customer_id = r.customer_id and c.member_id = r.user_id)
--select * into DMS_Ecosystem_Backup_Table.dbo._customer_to_user_relation_20240512
--from DMS_EcoSystem.dbo.customer_to_user_relation
--insert into customer_to_user_relation
--(customer_to_user_relation_id, customer_id, user_id, created_date, created_by, updated_date, updated_by, org_id, tenant_id, start_date, end_date)
--select newid(), b.customer_id, c.member_id, getdate(), 'Support', getdate(), 'Support', 'OROMEO', 'OROMEO', '2024-01-01 00:00:00.000', '2099-12-31 00:00:00.000'
--from #TempTableCustUser a
--inner join customer b on b.customer_code = a.customer_code and b.org_id = 'oromeo'
--inner join member c on c.member_cd = a.user_code and c.org_id = 'oromeo'
--where not exists(select 1 from customer_to_user_relation r where r.org_id = 'oromeo' and b.customer_id = r.customer_id and c.member_id = r.user_id)
select b.customer_code, a.customer_id, user_id, start_date, end_date, count(1) from customer_to_user_relation a
inner join customer b on b.customer_id = a.customer_id
where a.org_id = 'oromeo'
group by b.customer_code, a.customer_id, user_id, start_date, end_date
having count(1)>1
order by b.customer_code
#3 Updated by Rashdan Hussin 4 months ago
- Status changed from Pending Client Verification to Ticket Resolved
- % Done changed from 90 to 100