KNOWLEDGE BASE
Log In    |    Knowledge Base    |    4D Home
Tech Tip: Tip for Creating Table Relations
PRODUCT: 4D | VERSION: 13.4 | PLATFORM: Mac & Win
Published On: August 25, 2014

When working on a large database structure with numerous tables it may become difficult to create many to one relationships between tables using the click and drag method. There is another fairly simple technique that can be used to create a relationship between tables that makes traversing numberous tables and fields less difficult.

To create a many to one relationship using this method:
1) Click on the field that will become the Many and make sure it gets highlighted
2) While holding down the Ctrl Key (Windows) or the Command Key (Mac) click on the field to become the One and make sure it gets highlighted.


On Macs the second field's highlight color is a shade of grey as shown above, Field 1 is the first selection and Field 2 is also selected with an off shade of grey

3) Click the + icon on the upper left of the window and select Relation. The relationship is created with the graphical representation also generated.


The highlighted fields will remain highlighted as long as the Table Manipulation area is not click in.

If Relation is Greyed out and unselectable a mistake was made and two feilds were not selected.




This method is very useful in large structures with numerous tables. After selecting the Many field it is possible to traverse the structure using the scroll bars or mouse wheel and even zooming in and out. It is also possible to use the search bar at the upper right of the window which will jump to the closest match placing it in view of the window.