onyxtacular
IS-IT--Management
Our company for years have used a text field as a way of adding more information about the customer. There are 3 digits in the code and the depending on the character and the position lets us know some information about the customer. Recently I found a way to add custom fields.
Now I would like to write a query to update those fields based on the 3 digit code..... If the first digit of the code is a space, the customer is inactive:
I have to read from the CUSTOMER_MASTER.CUSTYP_23 and based off the location and character update the Boolean in CUSTOMER_MASTER_EXT.INACTCUS
I was able to hack together this join statement that listed both tables together
SELECT cUSTOMER_MASTER.CUSTID_23, CUSTYP_23, inactcus, [2020], autograph, cabvis, planit
from Customer_Master
inner join Customer_Master_ext
on CUSTOMER_MASTER.CUSTID_23 = CUSTOMER_MASTER_EXT.CUSTID_23
Now I would like to write a query to update those fields based on the 3 digit code..... If the first digit of the code is a space, the customer is inactive:
I have to read from the CUSTOMER_MASTER.CUSTYP_23 and based off the location and character update the Boolean in CUSTOMER_MASTER_EXT.INACTCUS
I was able to hack together this join statement that listed both tables together
SELECT cUSTOMER_MASTER.CUSTID_23, CUSTYP_23, inactcus, [2020], autograph, cabvis, planit
from Customer_Master
inner join Customer_Master_ext
on CUSTOMER_MASTER.CUSTID_23 = CUSTOMER_MASTER_EXT.CUSTID_23