Jump to content
Server Maintenance This Week. ×

Separation Model: duplicate relationships?


This topic is 5718 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Hi,

I'm creating my first separation model solution with two files, myDB and myDBData.

My question: do I create the relationships in the base data myDBData file as well as the interface/business logic file myDB?

At first glance it would seem redundant to do so, but I'm creating several many-to-many relationships in this solution so I wonder if I shouldn't have the relationships in the data file too.

TIA for any help,

Pat

Link to comment
Share on other sites

Relationships in the data file may be needed when a related field is needed in a field definition's calculation, or auto-enter by calculation, or for a Lookup. But not so much for portals, filters, navigation, etc., because those are more about presentation of the data rather than the data itself. Presentation requires a layout with an attachment to a table occurrence of the interface file anyway.

The general rule I think would be: Don't create a relationship in the data file unless you have to. You will generally know that when defining fields.

Link to comment
Share on other sites

some other caveats...

Custom functions if used may need replication in both files.

Variables don't work across files. - I had fields using $variables to auto enter data on a field when the record is created but they didn't work when the script is initiated in the interface file. I had to resort to globals and pass the values thru a relationship.

Using "SELF" function in a calculation didn't work when evaluated thru the relationship in the data entry screen of the interface file. - I had to use the actual field instead of Self.

Link to comment
Share on other sites

This topic is 5718 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.