Is there a cut off number of how many values can be added to an Enum type column? If I have, letโs say, more than 150 different types of surgeries to be included in an Enum type column where the user can simply search for one and then select it and proceed to fill the rest of the form, is it possible to add that many number of values to the Enum type column? I have currently added 124 different types of surgeries, but I feel I have more than 150, probably close to 200 by the time I finish this App Iโm making. Any idea whether AppSheet would allow that many entries?
The second question is, when we type an expression for the AppFormula or ValidIf section, is there a maximum number of words that can be accommodated? Because Iโve seen that when I keep including a lot of expressions in to the same AppFormula (under a single working expression of course, ie: IFS([column name],CONCATENATE([Column name],โtextโ,[Column name],โetc.โ),etc.) in which I can keep on writing expressions as long as I want), at some point after about 50 lines of expressions, the codes stop working. So is there a cut off limit for the length of the expression too?
Thank you.
In answer to your first question.
When I have a lot of enum values I prefer to store them in a table.
SurgeryEnumValues[Surgeries]
For more information see topic โA List of Values from a Column in Another Tableโ in this article help.appsheet.com - Dropdown from Valid_If
Dropdown from Valid_If help.appsheet.com
@Philip_Garrett_Appsh Thank you very much. Any idea about the second question I asked? Would greatly value your input.
@Malaka_Jayawardene I donโt know the answer to your second question, but you should carefully consider your approach. An expression that long is going to be very difficult to maintain over time or if someone else has to maintain it.
Hi Malaka, what you need is a dependent dropdown. This will make your life much easier. https://help.appsheet.com/ux/dropdowns-in-forms/dependent-dropdown
@praveen is the expert on expressions. He may be able to help you.
@praveen Lovely! I will make a new table with 150+ surgery names and related sub options and then couple those column names with a ValidIf expression. Seems itโs way easier to manage if newer additions are required. Thank you very much for your guidance!
Hi @Malaka_Jayawardene yes there is a limit on expression length. Have you considered using SWITCH() instead of a lot of IFS ? If it is applicable, it can be a lot more compact.
@praveen the reason for the lengthy expressions is because of the IFS expression that I had to use, so yes, itโd be great if it can be reduced in length. In the app that Iโm trying to make, there is an Enum column called [Surgery], which has over >150 values of surgical titles. If the user selects one, then a new Enum column appears with related values to the surgical title. For example, if surgery title is Splenectomy, the [Further specify] enum column appears with โEmergencyโ, โElectiveโ options. So, like wise for most of the surgical titles, the [Further specify] enum column opens up with related options, so I had to write a ValidIf expression using the IFS - IFS([Surgery]=โSplenectomyโ,{Elective,Emergency},[Surgery]=โSkin Graftโ,{Full thickness,Split thickness},etc, etc,โฆ), and the expression keeps on growing, as I keep on adding surgical titles, so I was wondering whether itโll stop working at some point. Itโd be great if you could shed some light as to how SWITCH() can be helpful there. Thank you very much!
User | Count |
---|---|
40 | |
36 | |
32 | |
23 | |
16 |