Skip to main content
October 12, 2023
Question

why I am getting error while adding data store entity in Expression Rule?

  • October 12, 2023
  • 8 replies
  • 0 views

Getting this error while adding cdt Constant in expression rule 

8 replies

nitishr0002
October 12, 2023

Cross validate the data with the structure of the entity. Sometimes the data queried could not be as per the data type or they might overflow with the length set.

harshitb6843
October 12, 2023

Its fine. You can still proceed. To solve this error, just add sort info on the primary key of the column and it should be gone. I have faced it multiple times but couldn't understand the reason. 

October 12, 2023

but it's not allowing me to add sorting as long as I select constant it give me error 

harshitb6843
October 12, 2023

Then you can avoid using the builder and directly write the code the expression. 

stefanhelzle0001
October 12, 2023

Did you check the tomcat log file for any details?

October 12, 2023


a!queryEntity(
  entity: cons!DATA_STORE_CONSTANT,
  query: a!query(
    logicalExpression: a!queryLogicalExpression(
      operator: "AND",
      filters: {
        a!queryFilter(
          field: "coveragesiteid",
          operator: "=",
          value: ""
          /*with and without value giving same error*/
        )
      },
      ignoreFiltersWithEmptyValues: true
    ),
    pagingInfo: a!pagingInfo(
      startIndex: 1,
      batchSize: 2000,
      sort: a!sortInfo(
        field: "siteid_Pk",
        ascending: true
      )
    )
  )
)