cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Unexpected Preparer error DefaultSAPCustomerAddressConsistencyInterceptor - SQL search error - Invalid column name 'false'

0 Likes
1,017

We are working on Hybris 6.7.1. We are using MS SQL database.

When I try to update the SAP customer ID attribute of item 'Address' I am getting this error:

DefaultSAPCustomerAddressConsistencyInterceptor
Unexpected Preparer error; SQL search error - Invalid column name 'false'. query = 'SELECT item_t0.PK FROM addresses item_t0 WHERE ( item_t0.p_sapcustomerid =? and item_t0.p_duplicate = false) AND (item_t0.TypePkString=? )', values =

Anybody else experiencing this issue? Any fix?

Accepted Solutions (1)

Accepted Solutions (1)

0 Likes

Basically, the issue with MS SQL database I think, We have had same issue and it turn out the issue is with OTB class DefaultSAPCustomerAddressConsistencyInterceptor from sapcustomerb2b extension, some code changes has been done in this class[hybris 6.7], The issue is with the query

String query = "SELECT {PK} FROM {" + AddressModel._TYPECODE + "} WHERE {" + AddressModel.SAPCUSTOMERID + "} =?kunnr " + " and {" + AddressModel.DUPLICATE + "} = false";

override this class and change query to

String query = "SELECT {PK} FROM {" + AddressModel._TYPECODE + "} WHERE {" + AddressModel.SAPCUSTOMERID + "} =?kunnr " + " and {" + AddressModel.DUPLICATE + "} = 0";

Instead to set false in AddressModel.DUPLICATE in query set 0, its work in my case hope it would help you as well

Happy Coding !!!

Answers (0)