iVend API not allowing to create Product Id with length greater than 20 characters(Method -SaveProduct & SaveProductList)
While calling iVend API method SaveProduct and SaveProductList, and passing ProductId with length greater than 20 characters, API was returning below error even though with 6.6, we can now create ProductId upto 50 characters
*Error Message: “Error Id cannot be more than 20 characters”*
As per investigation, we found that issue was due to a rule created in CfgValidationRule table for the Product Id.
There was a rule created by default in CfgValidationRule in API database(HO).
Data can be found with the below query.
Step 1. Run below query on API database(HO)
select * from CfgValidationRule where id = 'Product-Id' and RuleType=3 and
ERPType=<ERPTypeUsed>
Step 2. As per the data fetched by the query, check MaxLength column. Update and Set it to the value you want max value for Product Id.
Step 3. Do IIS Reset and check the results. Now it should allow you to create Product Id with more than 20 characters.
It is only applicable for iVend 6.6 as of now. It will not work for lower versions.