Scenario:
Assign a new_customer_id to each existing customer of our three business. A master lookup table (M) was given to me with pre-populated (SEQ_NOs), (NEW_CUSTIDs), and NULL in (OLD_CUSTIDS). My duty is to
(1) Fill the M.OLD_CUSTID column with existing customer ids from T1, T2, T3 (uniquely).
(2) Once the master lookup table is filled, add (SEQ_NO), and (NEW_CUSTID) column to the 3 existing customer tables to hold the new information.
(3) At the end of the project, remove the existing customer ids from the T1, T2, T3.
Question
Since there are no associations (keys) between the master table and the existing customer tables. The M.OLD_CUSTID and T1.NEW_CUSTID are NULL at this stage, I don't know how to complete the following code:
update M
set OLD_CUSTID= (select OLD_CUSTID from T1 where M.??=T1.??)
Can someone help me ASAP? Thanks in Advance.
-ORACLE Newbi
Assign a new_customer_id to each existing customer of our three business. A master lookup table (M) was given to me with pre-populated (SEQ_NOs), (NEW_CUSTIDs), and NULL in (OLD_CUSTIDS). My duty is to
(1) Fill the M.OLD_CUSTID column with existing customer ids from T1, T2, T3 (uniquely).
(2) Once the master lookup table is filled, add (SEQ_NO), and (NEW_CUSTID) column to the 3 existing customer tables to hold the new information.
(3) At the end of the project, remove the existing customer ids from the T1, T2, T3.
Question
Since there are no associations (keys) between the master table and the existing customer tables. The M.OLD_CUSTID and T1.NEW_CUSTID are NULL at this stage, I don't know how to complete the following code:
update M
set OLD_CUSTID= (select OLD_CUSTID from T1 where M.??=T1.??)
Can someone help me ASAP? Thanks in Advance.
-ORACLE Newbi
Comment