Should field names be unique within a given table?


You can create multiple fields of the same name within a table. Is that by design?

Should field names be restricted to be unique within a given table? Of course, a field of the same name would still be allowed in other tables, including subtables in the same hierarchy.


Follow-up question: Should system property names be unique?

You can also have multiple system properties of the same name currently.

Note that with system properties, there is also an API to look them up by name, and the documentation says

You can retrieve information about that Property using a GET request and
specifying name of that Property. For example, to find the Property
named “height”, include the parameter name=height in the URL

At the moment, that query might return more than one “height” property.


Hi @thiloplanz,

At the moment you can create multiple fields of the same name within the table. This might be changed in the future.

The property lookup API endpoint would only return 1 or no results and property names should not be reused. Each property is linked to a type and a unit of measurement, both of which uniquely identify a single type and a single unit of measurement and preferably names will be sufficiently descriptive to reflect that.

Please note that property management API are not to intended to be used by application developers – applications are meant to choose from properties, types and units of measurement provided for them to encourage consistency across the HAT ecosystem.

I have noticed an issue with property lookup endpoints are only enabled for the owner account and will report that to the team.