Open coder0112 opened 7 months ago
Hi, can you please post the full stack trace?
Hi, can you please post the full stack trace?
Hi.
2024-04-02T15:07:01.090+05:00 ERROR [user-service,,] 8200 --- [nio-8400-exec-1] u.c.s.exception.GlobalExceptionHandler : Unknown error occurred
java.lang.ClassCastException: class com.blazebit.persistence.view.impl.metamodel.FlatViewTypeImpl cannot be cast to class com.blazebit.persistence.view.metamodel.ViewType (com.blazebit.persistence.view.impl.metamodel.FlatViewTypeImpl and com.blazebit.persistence.view.metamodel.ViewType are in unnamed module of loader 'app')
at com.blazebit.persistence.view.impl.EntityViewSettingHelper.applyViewFilters(EntityViewSettingHelper.java:298)
at com.blazebit.persistence.view.impl.EntityViewSettingHelper.apply(EntityViewSettingHelper.java:122)
at com.blazebit.persistence.view.impl.EntityViewManagerImpl.applySetting(EntityViewManagerImpl.java:1235)
at com.blazebit.persistence.spring.data.base.query.AbstractPartTreeBlazePersistenceQuery$QueryPreparer.createQuery0(AbstractPartTreeBlazePersistenceQuery.java:256)
at com.blazebit.persistence.spring.data.base.query.AbstractPartTreeBlazePersistenceQuery$QueryPreparer.createQuery(AbstractPartTreeBlazePersistenceQuery.java:226)
at com.blazebit.persistence.spring.data.base.query.AbstractPartTreeBlazePersistenceQuery$QueryPreparer.createQuery(AbstractPartTreeBlazePersistenceQuery.java:441)
at com.blazebit.persistence.spring.data.base.query.AbstractPartTreeBlazePersistenceQuery.doCreateQuery(AbstractPartTreeBlazePersistenceQuery.java:165)
Ok, so it seems that right now, we only support view filters on entity views that have a @IdMapping
defined, though I'm not sure if there is a good reason for this limitation.
Since you seem to want to get the count for every litigation status, you might as well annotate that getter i.e. @IdMapping CourtWarningLitigationStatus getLitigationStatus();
Thank you very much for not ignoring my problem and helping me solve the problem. It works. It was my bad
Hello!
Description
I try to get list of entity view with custom filter but I get an error
there is part of my
EntityViewUtils is below
I wrote custom filter below
I used Spring Boot JPA. It is working with pagination.
Expected behavior
Actual behavior
Steps to reproduce
Environment
Version: 1.6.9
JPA-Provider: Hibernate 6.2.6.Final DBMS: PostgreSQL
Application Server: Java Spring Boot