Highlighted
Absent Member.
Absent Member.
877 views

Failure at ILASM Phase

Jump to solution

I've got this error when I was trying to build the library, it's at the goback keyword -verb-

       program-id. ExecuteTransaction as "CoreBanking.Transactions.ExecuteTransaction".

       data division.
       working-storage section.
       copy 'Records\TransactionRecord'.
      
       77  operation-code              pic X(10).
       77  result-code                 pic X(50).
       77  debit-account-balance       pic S9(10)V9(03) comp-3.
       88  internal-accounti-id        values 1 thru 7.

       procedure division using by value operation-code, by reference tansaction-record returning result-code.
           copy 'DatabaseConnection'.
          
           if internal-accounti-id then
               perform debit-internal-account
           else
               perform debit-customer-account
           end-if.
          
           evaluate debit-account
               when 1 thru 7
                   perform debit-internal-account
               when other
                   perform debit-customer-account
           end-evaluate.
           goback.
      
       debit-internal-account.
           exec sql
               insert into bank_transaction(DEBIT_ACCOUNT, CREDIT_ACCOUNT, AMOUNT)
                   values(:debit-account, :credit-account, :transaction-amount)
           end-exec.
          
           exec sql
               commit
           end-exec.
          
           move 'Transaction completed' to result-code.
      
       debit-customer-account.
           exec sql
               select balance
               into :debit-account-balance
               from
               (
                  select sum(credit), sum(debit), sum(credit) - sum(debit) as balance from
                  (
                     select transaction_id as voucher,transaction_date, amount as credit, 0 as debit
                     from bank_transaction
                     where credit_account = :credit-account
                     union
                     select transaction_id,transaction_date, 0 as credit, amount as debit
                     from bank_transaction
                     where debit_account = :credit-account
                  )
               )
           end-exec.
          
           if debit-account-balance <= transaction-amount then
               exec sql
                   insert into bank_transaction(DEBIT_ACCOUNT, CREDIT_ACCOUNT, AMOUNT)
                       values(:debit-account, :credit-account, :transaction-amount)
               end-exec
              
               exec sql
                   commit
               end-exec
              
               move 'Transaction Was Successfuly Completed' to result-code
           else
               move 'Insufficient Funds!' to result-code
           end-if.
          
           exec sql
               disconnect current
           end-exec.
      
       sql-error-routine.
           move 'internal error' to result-code.
          
       end program ExecuteTransaction.

0 Likes
1 Solution

Accepted Solutions
Highlighted
Absent Member.
Absent Member.

RE: Failure at ILASM Phase

Jump to solution

It's related Chris, I am sorry for the conceptually duplicate posts.

View solution in original post

0 Likes
2 Replies
Highlighted
Micro Focus Expert
Micro Focus Expert

RE: Failure at ILASM Phase

Jump to solution

Hi Ahmet,

Is this error related to the other posting that you have made about the duplicate names being caused by using the same linkage section parameters on multiple programs when using ilsmartlinkage?

If this is a different problem, then please show me what the content of the two copybooks should look like so I can try to reproduce this here?

Thanks.

0 Likes
Highlighted
Absent Member.
Absent Member.

RE: Failure at ILASM Phase

Jump to solution

It's related Chris, I am sorry for the conceptually duplicate posts.

View solution in original post

0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.