English Español Deutsch Italiano Polski Nederlands Português Français 中文 日本語 हिन्दी اللغة العربية Русский Українська עִברִית
Log In
English

Log In

 

Subform (field type)

A subform is a form that is inserted in another form

When you are working with relational database, you often need to view multiple tables or fill out several tables using one form.

Subforms on QuintaDB service are a convenient tool for doing this.

Another words, the Sub-form is a form that is inserted in another form.

They are generally used when you need to show data from tables with a one-to-many relationship.

For example, let’s take the “Contracts” table, which contains all current contracts with the company.

The task is to relate customer with his contracts. In this case, one customer may have many contracts.

I’m creating a new form called "Сustomers". I have already created contact input fields.

Now I need to create a Subform field. You can find it in the "Advanced" section.

Select the “Сontracts” table from the drop-down list.

 

This is how Subform looks on the main form:

The "Customers" table:

 

Subform settings

On the Subform field editing page you can:

  • Set the minimum entries number.
  • Set the default entries number (the number of open subform entries when the main form loading).
  • A limit on the maximum entries number.
  • Choose the subform's data order in the table and the data sorting method.

In the Subform settings tab you can:

  • Choose how to show subform's data in table: as a column or a table.
  • Show or hide some subform fields on the main form.
  • Select option delete or not all dependent records in subform, when main form's record deleted.
  • Show or hide the "Add new" link and change the text of this link.
  • Show or hide "Delete" icon.

Formula and Linked Column


If there you have a Subform in your table, then you can use their columns as operands for the Formula and also show the Linked column.

For example, let's back to the "Customers" table. The task is to show the total amount of all contracts for a particular customer.

To do this, add the Linked column field and select the "Amount $" column.

As a result, you get a "Total" column in which shows the total amount of all contracts:


Please, login to QuintaDB to be able to post comments

ian@betoli.com

Can you have a main form with a subform shown as a table?


Igor Petrushenko

Hi, Ian!

Of course, as you can see on several screenshots in this post. Also please watch a video, you can easily change the view in subform settings.

Share the discussion in the social networks: