GetConnectors changes in Profit 15

This page displays the most important changes and points for attention in the existing functionality of GetConnectors (and AFAS Remote). The changes may influence existing links with AFAS Profit.

What will change?

When getting data via the Profit Web services, the Profit application itself compiled and processed the data. Next, the data was sent back to the Profit web services in XML or JSON format. As from Profit 15, the processing and compiling of JSON and XML, respectively, is no longer performed in Profit but directly in the SQL database. This will mean that getting data from Profit through our GetConnectors will be a lot faster! The optimisation does, however, entail a number of changes.

What will work differently?

Generating JSON or XML directly from the SQL database leads to differences when compared to Profit 14. These differences are described below:

  • Currency fields have more digits behind the separator.
  • Numeric fields may have digits after the separator, for example, 20.00 VAT.
  • If a label contains a dot, Profit will report that this is inconsistent with the REST definitions.
  • SOAP option 3 (with empty elements).
  • Date and time fields may lead to different rounding off solutions.
  • Base64 output may have a slightly different format.
  • Sorting of tables may be different if sorting is not predefined.

Currency fields

The output of the currency fields is different. This is now in accordance with the meta description. An example of this changed output is the book value of Fixed Assets:

App_Cnr GetConnector wijzigingen Profit 15

Book value is described as follows in the metadata:

{

"id": "Book value"

"fieldId": "U005"

"dataType": "decimal"

"label": "Book value"

"length": 26

"controlType": 1

"decimals": 10

"decimalsFieldId": ""

}

This means that the field in Profit 15 is returned with several decimals.

Numeric fields

The output of numeric fields is different. This is now in accordance with the meta description. An example of this output is the VAT rate below:

{

"id": "Rate"

"fieldId": "U009"

"dataType": "decimal"

"label": "Rate"

"length": 5

"controlType": 1

"decimals": 2

"decimalsFieldId": ""

}

This means that the field in Profit 15 is returned with several decimals.

Labels without a separator via REST

If a separator is used in Profit 15 in a label, a message will be displayed for the user to deal with this carefully because this is not allowed in REST.

Soap option Output options=3 (with empty elements)

This option can be used to include an empty tag in the XML. In the old situation, however, it was the case that the tag had no value. Now, an empty tag is returned. A name space also now belong to this empty tag.

Date/time fields

The optimisation returns data directly from the SQL database. Date/time fields contain the time with a classification in milliseconds in SQL. Milliseconds are not used in Profit. To compensate the difference now, a rounding-off takes place by adding 0.498 milliseconds. Scenarios can be imagined because of this that mean that there is a deviation of ~2 milliseconds.

If you save your date/time fields to use them as filters during a next call, you may get duplicate lines. The condition is that you will have retrieved and saved this date/time with the old method (therefore during Profit 14) and you use it as a filter in relation to the new method (in Profit 15).

Get images in Base64

When you get images in attachment, the output is a base64 string. The new method will not be different from the old one in relation to contents, but the formatting in base64 may be slightly different. It is now displayed on one line.

Table sorting

With regard to Skip and Take, we are also always instructing that sorting must be used. If it is missing, SQL will determine a (optimum) sorting. This may be different for the old and new method. We recommend always defining a sorting method.

Directly to

  1. Connector
  2. All endpoints for Profit connectors
  3. Build and test connectors
  4. Call a connector using SOAP
  5. Call a GetConnector using the App connector
  6. Call a connector using Profit REST Services (JSON)