Is there any restrictions on using a Foreign key in the data layer across modules?

Is there any restrictions on using a Foreign key in the data layer across modules?

  

Hi, as I am learning Outsystems, so a newbie.


As I plan out the modular design of the application and the data structure. Historically in other technologies I have kept the data structure of an application together in one 'core' module. Any other data not in the 'core' module has been consumed from other applications through a service. 

When it comes to Outsystems Architecture planning, is it best practice to keep the data module to an application in the one core module. If you didn't and shared the data module over many core modules are there any restrictions or considerations I need to be aware in consideration to Entity Diagrams and Foreign Keys?

Regards

Hamish

Hello Hamish

Hamish Price wrote:

...

When it comes to Outsystems Architecture planning, is it best practice to keep the data module to an application in the one core module. 

...

This is not true.

The recomendation is that you DON'T put everything in a single Core module. Instead, you should keep related concepts together (including core entities), and not related concepts separated (including core entities). One reference that you probably will use everywhere is the User Identifier. And it is separated of everything else, in the System.

Said that, the thing you must be aware when using a FK to an entity in a different module is: Am I doing cyclic reference? Am I doiong an Upward reference? Am I doing a lateral reference in the End User and Orchestration module?

And fix it accordingly.

Cheers,
Eduardo Jauch

Thanks Eduardo for the reply.

Hamish