I am trying to determine the character limit of the label field in a question of a Survey123 survey. I believe it is probably 256 characters, but wanted to check and see if anyone knows the exact character limit of this field.
Thanks!
I can't give you an answer for a specific character limit off the top of my head, but I know I've used extremely long blocks of text using HTML to create a table to display in the survey (it was a null field type though, not sure if that would overwrite any kind of character limit?)
I agree with @Katie_Clark , you can make Survey123 question labels really long. Just for fun, today I created a label with 133,000 characters, and it did work fine in both the mobile and web apps. The text is longer anyone would every want to read! 🙂
In practice, what bites you is not the limit on the Survey123 labels, but the limit on the ArcGIS field alias. When you publish a survey, the label of the question is used to populate the field alias. That is where you are going to get errors, while publishing. So here are a few recommendations:
Thanks for elaborating, @IsmaelChivite !
Just clarifying, is that a typo in your second bullet point? It's bind::esriFieldType value to null, correct? 🙂
Maybe I’m misunderstanding, but I don’t think you’all understand the question. The Label is NOT a database field value, but a field name. I realized that the limitation is the length allowed by Esri’s Datastore’s Postgres database configured NAMEDATALEN. Since this is hidden from us, I will assume the length limit is 63 bytes.
Bing Search (ChapGPT)
The search results indicate that the limit of the field name length in a PostgreSQL database is **63 bytes**¹²⁴. This means that identifiers such as table names, column names, constraint names, etc. are limited to a maximum length of 63 bytes. Identifiers longer than 63 bytes can be used, but they will be truncated to the allowed length¹⁴. The limit is determined by the value of **NAMEDATALEN**, which is 64 by default²⁵. NAMEDATALEN can be changed in the source code before building PostgreSQL, but this is not recommended³.
Source: Conversation with Bing, 5/2/2023
(1) https://til.hashrocket.com/posts/8f87c65a0a-postgresqls-max-identifier-length-is-63-bytes#:~:text=In..... https://bing.com/search?q=field+name+length+postgres.
(2) How long can PostgreSQL table names be? - Stack Overflow. https://stackoverflow.com/questions/27865770/how-long-can-postgresql-table-names-be.
(3) PostgreSQL's Max Identifier Length Is 63 Bytes - Today I Learned. https://til.hashrocket.com/posts/8f87c65a0a-postgresqls-max-identifier-length-is-63-bytes.
(4) PostgreSQL: Documentation: 7.0: Names. https://www.postgresql.org/docs/7.0/syntax525.htm.
(5) Increasing Postgres column name length - Stack Overflow. https://stackoverflow.com/questions/63511001/increasing-postgres-column-name-length.
@MichaelBishopp It looks like we got lost in translation. This link may be helpful to you: https://pro.arcgis.com/en/pro-app/latest/help/data/geodatabases/manage-saphana/enterprise-geodatabas...
I realized that the "Label" field is actually creating an alias for this field name (it is shortened automatically by Esri for the actual field name). So the alias field name length max is 255 based on @IsmaelChivite URL share.