bcgov / entity

ServiceBC Registry Team working on Legal Entities
Apache License 2.0
23 stars 58 forks source link

ULC/CCC/BC pipeline - data mapping analysis for Change of Directors #23110

Open davemck513 opened 1 month ago

davemck513 commented 1 month ago

This ticket is used to analyze whether we have the required tables and data in the COLIN db extract(postgres) and LEAR db to start updating the corps data pipeline to bring over Change of Directors for corps.

eason-pan-bc commented 1 week ago

The tables in COLIN db (DEV) related to Filing Type NOCDR (change of directors)

There are other tables also been modified which are not directly connected by EVENT_ID, but by other keys like MAILING_ADDR_ID

Tool Sharing

Created a helper tool to find out non-null columns in tables related to a particular filing type in COLIN. https://github.com/eason-pan-bc/data_mapping_analysis_tool

eason-pan-bc commented 4 days ago

Analysis Summary

1- May need work for data mapping

They are already in COLIN extract, but haven't been mapped to LEAR db COLIN Table COLIN Columns
EVENT EVENT_TYP_CD
CORP_PARTY PREV_PARTY_ID
LEDGER_TEXT LEDGER_TEXT_DTS
LEDGER_TEXT USER_ID

2 - Need further discussion

NOTIFICATION table: 99% sure that we can ignore, double check with Dylan again FURNISH_REPORT table: Dylan is having discussions on this

3 - May need to figure out for LEAR CoD filing

There are several columns in some tables DO NOT have been mapped out, but related to CoD filing in LEAR. Table Column Notes
parties email EMAIL_ADDRESS in COPR_PARTY are all null
addresses delivery_instructions not converting
addresses address_type MAILING_ADDR_ID, DELIVERY_ADDR_ID in CORP_PARTY
party_roles party_id
transaction issued_at e.g. 30.07.2019 19:43:20 947
business last_cod_date
filings id
filings filing_json not exist in COLIN, since they were not using JSON
filings payment_id
filings submitter_id
filings payment_completion_date
filings completion_date
filings source if mapped from COLIN then it's "COLIN"
filings parent_filing_id
filings payment_status_code
filings meta_data not exist in COLIN, since they were not using JSON

Detailed Mapping Information

In this Google Sheet file, you will find 2 spreadsheets,

vikas-gov commented 4 days ago

@argush3 @chenhongjing to review

eason-pan-bc commented 3 days ago

Dummy company created in COLIN Tst

Company Number: BC1144712 Name of Company: 1144712 B.C. LTD. Company Email Address: eason.pan@gov.bc.ca You have the following company password for the above company. Company Password: test123456 BN_9: 985439009 BN_15: 985439009BC0001

CoD filing (NOCDR)

Event_id (CoD/NOCDR)

9321796,9321798,9321802,9321816,9321817,9321818

eason-pan-bc commented 3 days ago

Tables referencing to EVENT table

REFERENCING_TABLE REFERENCING_COLUMN (-> EVENT.EVENT_ID)
CORP_PARTY START_EVENT_ID
CORP_PARTY END_EVENT_ID
FILING EVENT_ID
LEDGER_TEXT EVENT_ID
NOTIFICATION EVENT_ID
PAYMENT EVENT_ID
FILING_USER EVENT_ID
FURNISH_REPORT EVENT_ID
MRAS_MESSAGE_OUTBOUND STG_ID
OFFICE END_EVENT_ID
OFFICE START_EVENT_ID
PAYMENT_STATE EVENT_ID

Tables referencing to the related tables listed above

Main Table Column in main table Connected Table column in connected table
CORP_PARTY MAILING_ADDR_ID ADDRESS ADDR_ID
CORP_PARTY DELIVERY_ADDR_ID ADDRESS ADDR_ID
FURNISH_REPORT BATCH_ID BATCH_REPORT_LOG BATCH_ID
NOTIFICATION MAILING_ADDR_ID ADDRESS ADDR_ID
argush3 commented 1 day ago

great work @eason-pan-bc ! the CoD filing data mapping analysis spreadsheet, tool you created and notes were all very helpful. I think there are definitely some things I'll need to follow up with Dylan on before we get to the implementation of this filing.

I'm going to move this to done in the meantime.