Skip to main content

This content has been archived and is no longer being updated. Links may not function; however, this content may be relevant to outdated versions of the product.

Support Article

Pega is unable to integrate with an MSSQL Server stored proc

SA-6208

Summary



User have a custom Requirement to Invoke MSSQL stored procedure from PEGA, they are using MSSQL Server Version: 2008.

Error Messages



ERROR 10.52.50.88|10.186.102.18 dashb3 - Error in RDB-List
com.pega.pegarules.pub.database.DatabaseException: There was a problem getting a list: code: 257 SQLState: S0003 Message: Implicit conversion from data type xml to varchar is not allowed. Use the CONVERT function to run this query.
From: (H728270D1F6D95E13F6160762FE3BFBEE:10.186.102.18)
SQL: { ? = call out1.praGetAnzibProfileByCisAsXml(?,?) }
SQL Inserts: <(OUTPUT PARAMETER)> <> <(OUTPUT PARAMETER)>

Caused by SQL Problems.
Problem #1, SQLState S0003, Error code 257: com.microsoft.sqlserver.jdbc.SQLServerException: Implicit conversion from data type xml to varchar is not allowed. Use the CONVERT function to run this query.
at com.pega.pegarules.data.internal.access.ExceptionInformation.createExceptionDueToDBFailure(ExceptionInformation.java:167)
at com.pega.pegarules.data.internal.access.DatabaseImpl.list(DatabaseImpl.java:6298)
at com.pega.pegarules.data.internal.access.DatabaseImpl.executeRDB(DatabaseImpl.java:6691)
at com.pega.pegarules.data.internal.access.DatabaseImpl.executeRDB(DatabaseImpl.java:6647)
at com.pega.pegarules.data.internal.access.DatabaseImpl.listRDB(DatabaseImpl.java:6595)


Steps to Reproduce



1. Have a SQL Connector with connection string configured in the Browse tab
2. Have an activity that triggers the call to the above SQL Connect rule; set the CustomerReferenceNumber to a valid varchar value
3. Simulate the activity from Actions>Run and provide a valid value for CustomerReferenceNumber


Root Cause


Currently PRPC does not support custom types in Pega . 

Resolution


Developer must create an wrapper stored procedure that can internally construct the custom object type, which is used in the RULE-connect -sql .

Published January 31, 2016 - Updated October 8, 2020

Was this useful?

0% found this useful

Have a question? Get answers now.

Visit the Collaboration Center to ask questions, engage in discussions, share ideas, and help others.

Did you find this content helpful?

Want to help us improve this content?

We'd prefer it if you saw us at our best.

Pega Community has detected you are using a browser which may prevent you from experiencing the site as intended. To improve your experience, please update your browser.

Close Deprecation Notice
Contact us