Are you getting a dump during node instance creation via SDK? This can be observed when you are trying to perform a Save action in the UI. However, instead of saving the record, the system throws a runtime exception (500 Internal server errors) without any valid error messages in the UI.

If your answer to the above is “YES”, then this blog is for you. In this blog, I will equip you with the know-how on the following:

• HOW you can verify the details for this dump
• Root cause on WHY such errors occur
• WHAT is the approach to resolve such errors at your end

HOW?

Since there are no error messages, it is difficult for you to identify why such dumps are occurring in the UI. When you come across such a scenario and if there is an add-on implementation on that UI screen, a good idea would be to check in the Cloud Applications Studio.
You can follow the below steps to find the runtime errors from SDK:

1. Login to Cloud Application Studio
2. Go to the View tab in the menu
3. Select ‘Dump Analysis’ option from the list
4. You can refresh and check if there are any dump records available in this window {as shown in the screenshot below}

The error that you are looking for is “Failure creating records of node CBO.Root on the database”. CBO.Root follows the convention of <BusinessObjectName>.<NodeName> in the add-on where you have added the extension fields. This also shows the solution name where the node is present, which helps you locate the field easily.

Dump%20Analysis%20Tool%20in%20SDK

Dump Analysis Tool in SDK

WHY?

When we enter text in the frontend in a field with a character limit, our expectation is that if the character limit is exceeded, the system would automatically truncate the entered text at the character limit and save that portion of the text entered.

Example: Let us consider a field “A” with a character limit of 3. We enter the text WXYZ. Your expectation is that if the text exceeds the limit, the system should store the value WXY. However, instead, you get a runtime exception.

Due to a limitation from the framework side, the system does not behave this way. What you see in this scenario is a runtime exception (500 Internal server errors). The same dump will record a backend dump with the error: “The maximum length of a STRING or RAWSTRING field was exceeded”.

WHAT?

This issue comes up only for STRING/RAWSTRING based datatypes. The maximum possible length for the types STRING and RAWSTRING and the mandatory maximum length for SSTRING must not be exceeded in writes performed on database fields of these types using Open SQL. If it is exceeded, an exception of the class CX_SY_OPEN_SQL_DB is raised. Truncations of strings when read to a target field, however, are ignored.

For example, if you have declared a field of data type “LANGUAGEINDEPENDENT_SHORT_Name” which has a maximum length defined as 10. During runtime, if the length of this field is passed is 11, a runtime exception will occur.

You should identify the fields from the node and solution name mentioned in the Dump analysis tool in such issues. Make sure the character limit of the fields is not exceeded. If it is exceeded, reduce your input to be within the limit defined. This would get rid of the runtime error.

Additionally, you can handle this in the code by putting a validation in place to check if any fields are exceeding the string length defined.

I hope this will help you in tackling UI dumps related to the extension fields of string data type in the PDI Add-on.

Best Regards,

Dhanya KV

 

Randa Khaled

Randa Khaled

Author Since: November 19, 2020

0 0 votes
Article Rating
Subscribe
Notify of
0 Comments
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x