Creating a custom column using two separate source columns

I have a table that I successfully create based off a .csv upload. It has three columns:

"Company Name", "Licenses Used (%)", "Conversion Rate (%)". I want to add a custom column that takes the average of every row's Licenses Used and Conversion Rate columns. What do I put in the 'value' field of the Average column in order to achieve this?

Not sure why this is difficult, as it is a simple task, but here we are.

Thanks!

Hello @ajjjjTuz, Welcome to the Retool Community :wave:,

To calculate the average of the "Licenses Used (%)" and "Conversion Rate (%)" columns for each row in your table, you can use a simple formula in the 'value' field of the custom column. Assuming both columns contain numeric values (without the % symbol), here's what you can put:
{{ (currentSourceRow.LicensesUsed(%) + currentSourceRow.ConversionRate(%)) / 2 }}

Feel free to ask if you need further assistance or have additional questions. We're here to help!

4 Likes

Thanks for the response. I ended up getting help. Your formula was almost there. The correct one was:

{{ currentSourceRow["LicensesUsed("%"]... }}