Back

Assign a subtemplate to a normal template

Creation of templates in Global Master Data Sync
Video 8/9
Play
Close
  • Helpful
  • Not helpful
  • Needs update
  • Technical error
An advanced video is for the experts, and it requires detailed knowledge about the specific area of Business Central. Advanced Watch "the details", if you need detailed knowledge about a specific topic. These videos are only relevant for particular users. The Details This video includes functionality from the app "Global Master Data Sync" which is available at Microsoft AppSource. Click to visit AppSource. Global Master Data Sync

Playlists  Manage

Log in to create a playlist or see your existing playlists.

Presenter: Dennis Schumacher, Sr. Business Central Cons.

In Microsoft Dynamics 365 Business Central, you can link a subtemplate to a normal data template so that any filter applied to the normal template automatically carries over to the subtemplate. This article shows how to connect a template for the chart of accounts with a template for the default dimensions on the chart of accounts.

To attach a subtemplate, you first set the subtemplate to the “Subtemplate” type and set the normal template to “Under Development” status. You then use the Subordinate Data Templates setup to look up and add the subtemplate to the normal template.

When you connect the two templates, the setup relations between them fill in automatically if a relation already exists. For a multi-relation table such as default dimensions, you should verify the filter setup, for example that table 15 (G/L Account) is correctly filtered and that the relevant field IDs are matched and linked.

Once you set the template back to “Released” and the records update, the two templates are connected. From that point, every filter you apply to the normal template for the chart of accounts also applies to the default dimension template.

What the setup achieves in a master company

Working from a master company, the goal is to create a data template that acts as a subtemplate and then assign it to a normal template. The point of doing this is straightforward: any filter you apply to the normal template is also reflected in the subtemplate. That keeps the two consistent without you having to maintain filters in two places.

In this example, there are two templates: one for the chart of accounts and one for the default dimensions on the chart of accounts. The aim is to connect them so that the default dimension template follows whatever happens on the chart of accounts template.

Preparing the subtemplate

Start with the template for the default dimensions on the chart of accounts. On the template card, set the type to “Subtemplate”. At this stage it will typically be “Under Development”, and you then put it on “Released”.

Because this is a subtemplate, nothing visible happens at this point. It has no relation to anything else yet, so there is no data to react to until you connect it to a normal template.

Setting the normal template to Under Development

Go back to the role center and find the template for the chart of accounts. To connect a subtemplate to a normal template, the normal template must be in “Under Development” status. Once it is, you are ready to attach the subtemplate.

Attaching the subtemplate to the normal template

From the chart of accounts template, open Setup and then Subordinate Data Templates. Use the lookup to find the subtemplate you want to add. In this case, that is the default dimensions of the chart of accounts. Press OK to add it.

If a relation already exists between the normal template and the subtemplate, the setup relation fills in automatically. It is still a good idea to go in and check that the filters are correct.

Checking the filter setup for a multi-relation table

The default dimension is a multi-relation table, so the filter setup has more than one line to review.

  • In the first row, field ID 1 has a filter set so that it filters for table 15, which is the G/L Account.
  • In the second row, the field ID number and field ID 1 in the G/L account are matched and linked to each other.

The result is that the account number and the G/L account flow into the default dimension. This is what ties the two templates together at the field level.

Releasing and confirming the connection

Set the chart of accounts template back to “Released”. As soon as the record update finishes, the two templates are connected.

To confirm it worked, open the default dimension template and look at the record data. You should now see a primary key for 15, and each account will have a default dimension.

With the two tables connected, every filter you apply to the normal template for the chart of accounts is also added to the default dimension. The subtemplate now follows the normal template automatically.

Q&A

What does linking a subtemplate to a normal template do in Business Central?

It makes the subtemplate follow the normal template. Any filter you apply to the normal template is automatically reflected in the connected subtemplate, so you do not have to maintain the same filters in two places.

What status must the normal template have before you can attach a subtemplate?

The normal template must be set to “Under Development” before you can connect a subtemplate to it. After attaching the subtemplate and checking the filters, you set it back to “Released”.

Where do you attach a subtemplate to a normal template?

Open the normal template, go to Setup, then Subordinate Data Templates. Use the lookup to find and add the subtemplate you want to connect.

What should you check when connecting a multi-relation table like default dimensions?

Verify the filter setup. For default dimensions, confirm that field ID 1 filters for table 15 (G/L Account) and that the field ID number and field ID 1 are matched and linked, so the account number and G/L account flow correctly into the default dimension.

How do you confirm the two templates are connected?

After releasing the template and letting the records update, open the default dimension template and check the record data. You should see a primary key for 15, and each account should have a default dimension.

662229848-iLH9aKglHfs-ENG21110808