The incoming request has too many parameters. The server supports a maximum of 2100 parameters.

0
Hello, My domain model is too simple; I have an entity, and another 19 entities inherit from this entity (generalization and specialization).I have an XPath to display pending requests for multiple users in the same tab depending on the status request and the role of the user, which for some reason are stored in associations in the database, as you can see in the image (SSManagement_Manager) / (SSManagment_ViceManager) / etc. The problem is that when I use this Xpath to display data on a data grid and select a specialization entity as the data source, it's working well. BUT when I use the same XPath on the generalization entity, we face the below error, and I can't find a solution for this or why it happens. Also  please note that it's working well locally because i use Mendix Build  in database but on test or prod we are using SQL and we face that error Does anyone know why?     Error   InternalLimitedXPathTextGetRequest (depth = -1, amount = 20): //SupportServices.SupportService[ (Status = 'PendingDirectManager'  and SupportServices.SupportService_Employee/AdminConfig.Employee/AdminConfig.Manager = '[%CurrentUser%]') or  (Status = 'PendingGeneralManager'  and ( SupportServices.SupportService_SSManagement/SupportServices.SSManagement [SupportServices.SSManagement_ServiceOwnerManager = '[%CurrentUser%]' or SupportServices.SSManagement_ServiceOwnerViceManager = '[%CurrentUser%]'][IsServiceOwnerManagerOnLeave] ) )  or  ((Status = 'PendingDepartmentManager' or Status = 'PendingResponsibleEmployee')  and SupportServices.SupportService_SSManagement/SupportServices.SSManagement/SupportServices.DepartmentInfo_SSManagement/SupportServices.DepartmentInfo/SupportServices.DepartmentInfo_Manager = '[%CurrentUser%]') or  ((Status = 'PendingResponsibleEmployee' or Status = 'Approved') and SupportServices.SupportService_ResponsibleEmployee/SupportServices.DepEmployee/SupportServices.DepEmployee_Employee= '[%CurrentUser%]')   ]  at com.mendix.connectionbus.RequestAnalyzer.doRequest(RequestAnalyzer.scala:33)   Caused by: com.mendix.basis.connectionbus.ConnectionBusException: Exception occurred while retrieving data. (SQL State: S0001, Error Code: 8003)  at com.mendix.connectionbus.util.SqlExceptionUtils$.getDetailedException(SqlExceptionUtils.scala:24)   Caused by: com.microsoft.sqlserver.jdbc.SQLServerException: The incoming request has too many parameters. The server supports a maximum of 2100 parameters.    
asked
1 answers
0

You can check which select query is send to the database when you set log level of ConnectionBus_Retrieve to Debug or Trace. Probably it will contain many joins and lots of parameters exceding the limit of the JDBC connection to SQL server. A possible solution is to reduce the amount of inherited subentities and use 1-1 associations, depending of what attributes you are selecting in the grid. Or define the query explicitly in OQL or SQL in Java action.

answered