Dynamics 365 Business Central Read

In this article

Overview

You can use this Snap to read the user details for a specific entity.

The Business Central Read Snap works as expected when passing values from upstream Snaps for fields such as Entity, Start page number and Max page number, and does not support upstream values for Timeout, Number of retries, and Retry interval fields.

Dynamics 365 Business Central Read__Overview.png

Snap Type

The Dynamics 365 Business Central Read Snap is a Read-type Snap.

Prerequisites

A valid Business Central Access Token or Business Central OAuth2 account.

Support for Ultra Pipelines

Works in Ultra Pipelines. 

Limitations

None.

Known Issues

  • The Company field in the Business Central Read Snap is optional for a few entities, such as Subscriptions, and it is mandatory for the remaining entities. Therefore, if the field is left blank, the Snap displays the following error:

Workaround: Specify the Company name for entities where it is mandatory.

  • When fetching Read related entities for a specific entity with selected output fields, the Snap displays an error if you do not specify all the key fields in the Output fields section.

    Error: Unexpected end-of-input: an expected close marker for an Object.

Workaround: Ensure you provide all the key fields in the Output fields.

  • The Business Central Read Snap does not support the following entities. The Snap displays an error when you configure with these entities.

Entity

Entity

applyVendorEntries, attachments, contactsInformation, dimensionSetLines, pdfDocument, pictures

Error:
Failure: Error when executing the request. Reason: (Application_DialogException) You must specify a parentId in the request body. CorrelationId: 5480ad2c-11b9-4f5e-9079-ac18ba9e13e0. [HTTP/1.1 400 Bad Request], Resolution: Verify the details provided.

Snap Views

Type

Format

Number of Views

Examples of Upstream and Downstream Snaps

Description

Type

Format

Number of Views

Examples of Upstream and Downstream Snaps

Description

Input 

Binary

 

  • Min: 0

  • Max: 1

  • Mapper

  • Head

  • Assert Equals

The entity from which you want to read the objects.

Output

Binary

 

  • Min: 1

  • Max: 1

  • Mapper

  • Head

  • Assert Equals

The output contain records from the specified entity.

Error

Error handling is a generic way to handle errors without losing data or failing the Snap execution. You can handle the errors that the Snap might encounter when running the pipeline by choosing one of the following options from the When errors occur list under the Views tab:

  • Stop Pipeline Execution: Stops the current pipeline execution if the Snap encounters an error.

  • Discard Error Data and Continue: Ignores the error, discards that record, and continues with the remaining records.

  • Route Error Data to Error View: Routes the error data to an error view without stopping the Snap execution.

Learn more about Error handling in Pipelines.

Snap Settings

  • Asterisk ( * ): Indicates a mandatory field.

  • Suggestion icon (): Indicates a list that is dynamically populated based on the configuration.

  • Expression icon ( ): Indicates the value is an expression (if enabled) or a static value (if disabled). Learn more about Using Expressions in SnapLogic.

  • Add icon ( ): Indicates that you can add fields in the field set.

  • Remove icon ( ): Indicates that you can remove fields from the field set.

  • Upload icon ( ): Indicates that you can upload files.

Field Name

Field Type

Description

Field Name

Field Type

Description

Label*

 

Default Value: Dynamics 365 Business Central Read
Example: Business Central Read

String

Specify a unique name for the Snap. You can modify this to be more specific, especially if you have more than one of the same Snap in your pipeline.

Company

Default Value: N/A
Example: My Company

String/Expression/Suggestion

Specify the company registered with the Business Central application.

Entity*

 

Default Value: N/A
Example: employees

String/Expression/Suggestion

Specify the OData entity object from which you want to read the records.

Primary key

Use this field set to specify the primary key that uniqely identifies the rows.

Key

Default Value: N/A
Example: Id

String/Expression/Suggestion

Specify or select the primary key for which you want to read the record.

  • More than one primary key can exist for an Entity.

  • Ensure that you provide key-value pairs for the primary keys, which are associated with a specific entity. If you do not do this, the Snap fails. For example, if you have four Primary keys in an entity, then you must pass the value for every field that you want to delete. If you use only one of the primary keys, the Snap fails.

Value

Default Value: N/A
Example: 2998d72e-fac9-ed11-94cc-000d3a220b2f

String/Expression

Specify the value of the key from which you want to read the record.

Output fields

Use this field set to fetch the fields you want the Snap to display in the output.

Output field

Default Value: N/A
Example: givenName

String/Expression/Suggestion

Specify or select the fields that you want to display in the output.

Read related entities

Use this field set to specify the related entities of the specific entity.

Read related entity

Default Value: N/A
Example: defaultDimensions

String/Expression/Suggestion

Specify or select the numerous related entities that you want to display in the output in addition to the fields in the Output fields.

Error out on no results

Default Value: Deselected

Checkbox

Select this checkbox to display the original document along with the error message No records found in the error view if no records are returned for the selected criteria.

Page size

Default Value: 100
Example: 50

Integer/Expression

Specify the number of records you want to fetch per page for large datasets.

Start page number

Default Value: 1
Example: 10

Integer/Expression

Specify the page number from which the fetching of records should begin till the last record or load until the page number specified in the Max page number field.

Max page number

Default Value: 0
Example: 10

Integer/Expression

Specify the page number after which the Snap should stop reading or fetching.

Timeout (seconds)

 

Default Value: 60
Example: 100

Integer/Expression

Specify the timeout to determine whether the connection is alive and also the timeout when waiting for a response through a socket.

Number of retries

Default Value: 0
Example: 5

Integer/Expression

Specify the maximum number of retry attempts for failures.

Retry interval (seconds)

Default Value: 1
Example: 5

Integer/Expression

Specify the amount of time in seconds between retry attempts.

HTTP header

Use this field set to define custom headers in the form of HTTP key-value pairs to pass to the Business Central instance.

Key

Default Value: N/A
Example: Accept

String/Expression

Specify the key for the HTTP header.

Value

Default Value: N/A
Example: application/json;odata.metadata=full

String/Expression

Specify the value for the HTTP header.

Snap Execution

Default Value: Execute only
Example: Validate & Execute

Dropdown list

Select one of the following three modes in which the Snap executes:

  • Validate & Execute: Performs limited execution of the Snap, and generates a data preview during pipeline validation. Subsequently, performs full execution of the Snap (unlimited records) during pipeline runtime.

  • Execute only: Performs full execution of the Snap during pipeline execution without generating preview data.

  • Disabled: Disables the Snap and all Snaps that are downstream from it.

Troubleshooting

Error

Reason

Resolution

Error

Reason

Resolution

Number of requests exceeded the limit of 6000 over the time window of 300 seconds

Requests exceeded the limit of 6000 over the time window of 300 seconds.

Decrease the batch size and retry. Learn more about the error messages: Service protection API limits.

Too many Requests - 429.

There are too many requests sent to Business Central endpoint.

The Microsoft Business Central related Snaps, include retry-after with <number of seconds> in the response header and automatically retries when they encounter status 429 error. Therefore, wait for the retry to succeed.

Example

Refer to this example to understand the function of Business Central Read Snap.

Fetching Records for Additional Entities

The example pipeline demonstrates how to use Read related entities field set to fetch records for the additional entities.

Download this pipeline.

Step 1: Configure the Company and Entity fields in the Business Central Read Snap.

Step 2: Configure the additional entities related to employees Entity in the Read related entities field set as follows:

Step 3: On validation, the Snap displays the records for all the entities in the output view.

Downloads

 

  File Modified

File Example_Business Central Read_Doc Example.slp

Aug 07, 2023 by Lakshmi Manda

Snap Pack History

 


Related Content

Â