Finacle Scripting Syntax -
var intAmt = calculateInterest(50000, 8.5, 30) print "Interest: " + intAmt Functions are — can be assigned to variables or passed as arguments (limited support). 7. File I/O & External Calls # Read file var lines = readFile("/data/input.txt") Write file writeFile("/data/output.txt", "Process completed") Call external REST API (Finacle 10+) var response = callAPI("GET", "https://api.example.com/rate", {}) 8. Error Handling try var bal = getAccountBalance("INVALID_ACCT") catch (err) print "Error code: " + err.code print "Message: " + err.message exit 1
# interest_post.fin include "common_functions.fin" var acctList = ["SAV001", "SAV002", "SAV003"] var rate = 4.5 finacle scripting syntax
for each acct in accounts print "Processing: " + acct var intAmt = calculateInterest(50000, 8
While loop var count = 1 while (count <= 5) print "Iteration: " + count count = count + 1 var intAmt = calculateInterest(50000