Updating Account Information (UPDACC)
The UPDACC program is responsible for updating account information in the database. It is initiated by the BNK1UAC program and follows a specific flow to ensure the account details are correctly updated. The process starts with identifying the account using the SORTCODE, updating the necessary fields, and then ending the program.
The flow starts with the BNK1UAC program calling the UPDACC program. The UPDACC program begins by identifying the account to be updated using the SORTCODE. It then updates the account information in the database, ensuring all fields are valid. Finally, the program ends and returns control to the calling program.
Where is this program used?
This program is used once, in a flow starting from BNK1UAC as represented in the following diagram:
Lets' zoom into the flow:
PREMIERE Section
The PREMIERESORTCODECOMM-SCODEDESIRED-SORT-CODEUPDATE-ACCOUNT-DB2GET-ME-OUT-OF-HERE
PREMIERE SECTION.
A010.
MOVE SORTCODE TO COMM-SCODE.
MOVE SORTCODE TO DESIRED-SORT-CODE.
*
* Update the account information
*
PERFORM UPDATE-ACCOUNT-DB2
*
* The COMMAREA values have now been set so all we need to do
* is finish
*
PERFORM GET-ME-OUT-OF-HERE.
A999.
EXIT.
UPDATE-ACCOUNT-DB2 Section
UPDATE-ACCOUNT-DB2The UPDATE-ACCOUNT-DB2SORTCODEACCOUNT_NUMBER
UPDATE-ACCOUNT-DB2 SECTION.
UAD010.
*
* Position ourself at the matching account record
*
MOVE COMM-ACCNO TO DESIRED-ACC-NO.
MOVE DESIRED-SORT-CODE TO HV-ACCOUNT-SORTCODE.
MOVE DESIRED-ACC-NO TO HV-ACCOUNT-ACC-NO.
EXEC SQL
SELECT ACCOUNT_EYECATCHER,
ACCOUNT_CUSTOMER_NUMBER,
ACCOUNT_SORTCODE,
ACCOUNT_NUMBER,
ACCOUNT_TYPE,
ACCOUNT_INTEREST_RATE,
ACCOUNT_OPENED,
ACCOUNT_OVERDRAFT_LIMIT,
ACCOUNT_LAST_STATEMENT,
GET-ME-OUT-OF-HERE Section
GET-ME-OUT-OF-HEREThe GET-ME-OUT-OF-HERE
GET-ME-OUT-OF-HERE SECTION.
GMOOH010.
EXEC CICS RETURN
END-EXEC.
GMOOH999.
EXIT.
This is an auto-generated document by Swimm 🌊 and has not yet been verified by a human