How to change the values of columns in table

I want to show to table if the package_id is 1 then (Basic), if 2(Starter), 3(Upgraded) how to do that if we have two options to hardcode it and I also have another table in retool database for these packages


For the displayed data in the table you have shared you would want to map the value in the "Mapped value" area of the column setup with something like:

{{currentSourceRow.package_id == 1 ? "Basic" : currentSourceRow.package_id == 2 ? "Starter" : currentSourceRow.package_id == 3 ? "Upgrade" : "Undefined"}}

If you have a separate table, you can reference the data in the same Mapped Value area as the result of a separate query.

2 Likes

thank you, worked