5.2. Creating the traffic violations DMN custom data types


DMN data types determine the structure of the data that you use within a table, column, or field in a DMN boxed expression for defining decision logic. You can use default DMN data types (such as string, number, or boolean) or you can create custom data types to specify additional fields and constraints that you want to implement for the boxed expression values. Use the DMN designer’s Data Types tab in Business Central to define the custom data types for the traffic violations project.

図5.4 The custom data types tab

dmn custom datatypes tab

The following tables list the tDriver, tViolation, and tFine custom data types that you will create for this project.

Expand
表5.1 tDriver custom data type
NameType

tDriver

Structure

Name

string

Age

number

State

string

City

string

Points

number

Expand
表5.2 tViolation custom data type
NameType

tViolation

Structure

Code

string

Date

date

Type

string

Speed Limit

number

Actual Speed

number

Expand
表5.3 tFine custom data type
NameType

tFine

Structure

Amount

number

Points

number

Prerequisites

  • You created the traffic violations DMN decision requirements diagram (DRDs) in Business Central.

Procedure

  1. To create the tDriver custom data type, click Add a custom Data Type on the Data Types tab, enter tDriver in the Name field, and select Structure from the Type list.
  2. Click the check mark to the right of the new data type to save your changes.

    図5.5 The tDriver custom data type

    dmn tDriver custom datatype
  3. Add each of the following nested data types to the tDriver structured data type by clicking the plus sign next to tDriver for each new nested data type. Click the check mark to the right of each new data type to save your changes.

    • Name (string)
    • Age (number)
    • State (string)
    • City (string)
    • Points (number)
  4. To create the tViolation custom data type, click New Data Type, enter tViolation in the Name field, and select Structure from the Type list.
  5. Click the check mark to the right of the new data type to save your changes.

    図5.6 The tViolation custom data type

    dmn tViolation custom datatype
  6. Add each of the following nested data types to the tViolation structured data type by clicking the plus sign next to tViolation for each new nested data type. Click the check mark to the right of each new data type to save your changes.

    • Code (string)
    • Date (date)
    • Type (string)
    • Speed Limit (number)
    • Actual Speed (number)
  7. To add the following constraints to the Type nested data type, click the edit icon, click Add Constraints, and select Enumeration from the Select constraint type drop-down menu.

    • speed
    • parking
    • driving under the influence
  8. Click OK, then click the check mark to the right of the Type data type to save your changes.
  9. To create the tFine custom data type, click New Data Type, enter tFine in the Name field, select Structure from the Type list, and click Save.

    図5.7 The tFine custom data type

    dmn tFine custom datatype
  10. Add each of the following nested data types to the tFine structured data type by clicking the plus sign next to tFine for each new nested data type. Click the check mark to the right of each new data type to save your changes.

    • Amount (number)
    • Points (number)
  11. Click Save.
Red Hat logoGithubredditYoutubeTwitter

詳細情報

試用、購入および販売

コミュニティー

会社概要

Red Hat は、企業がコアとなるデータセンターからネットワークエッジに至るまで、各種プラットフォームや環境全体で作業を簡素化できるように、強化されたソリューションを提供しています。

多様性を受け入れるオープンソースの強化

Red Hat では、コード、ドキュメント、Web プロパティーにおける配慮に欠ける用語の置き換えに取り組んでいます。このような変更は、段階的に実施される予定です。詳細情報: Red Hat ブログ.

Red Hat ドキュメントについて

Legal Notice

Theme

© 2026 Red Hat
トップに戻る