In the documentation you can insert data inside a table with the following syntax:
(insert table-name id {"parameter":parameterValue})
But here, in this example i have extra values in parameters before the brackets.
(insert loans-inventory (inventory-key loanId entityName) {"balance":loanAmount})
What (inventorty-key loanId and entintynName) syntax mean? (inventory-key) is a function.
inventory-key function
(defun inventory-key (loanId:string owner:string)
(format "{}:{}" [loanId owner]))