26
Views
4
Comments
Default Values for Multi tenant solutions
Question
what is the recomended way to have default values for non-static entities in a multi tenant application ?

Should I run a timer that checks if certain tables are empty and fills them with the default values if they are ?

With best regards,

Tomas
2017-07-05 18-13-21
Tiago Neves
Tomas,
You define default values of entities attributes the same way, being multi-tenant or not.
Setting an Entity as Multi-tenant constrains their data per tenant. Aggregates and SQL are performed with automatic data isolation: only data belonging to the correct tenant is returned. Have a look in the Help: https://www.outsystems.com/help/servicestudio/9.0/default.htm#Multi-tenant_eSpaces/About_Multi-Tenancy.htm
You want different default values per tenant? If that's your scenario I don't know what is the recommended way, if there's any.
2016-08-12 11-09-39
Tomas Kjartansson
Default values was not what i meant, sorry about that. What i meant was default data.

Lets say every tenant can customize his own table headers but I want to offer certain default headers that he can then customize or add to. How would i go about filling the default data into the entity where the headers are read from ?
2012-03-16 12-21-09
João Rosado
Staff
Hi Tomas,

The normal would be to have a multitenant timer running "on publish" to do the bootstrap of the entities.

Regards
João Rosado
2016-08-12 11-09-39
Tomas Kjartansson
Thank you :)
Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.