У меня есть проект в Java EE.Когда я получаю доступ к таблице из базы данных, она возвращает ошибку, вот запрос HQL:
select b from Blacklist b inner join fetch b.users u where b.type ilike :type order by b.date desc
и это сообщение об ошибке:
18:18:10,694 ERROR [STDERR] java.lang.NullPointerException
18:18:10,694 ERROR [STDERR] at org.hibernate.engine.query.QueryPlanCache$HQLQueryPlanKey.<init>(QueryPlanCache.java:193)
18:18:10,694 ERROR [STDERR] at org.hibernate.engine.query.QueryPlanCache.getHQLQueryPlan(QueryPlanCache.java:87)
18:18:10,694 ERROR [STDERR] at org.hibernate.impl.AbstractSessionImpl.getHQLQueryPlan(AbstractSessionImpl.java:156)
18:18:10,694 ERROR [STDERR] at org.hibernate.impl.AbstractSessionImpl.createQuery(AbstractSessionImpl.java:135)
18:18:10,694 ERROR [STDERR] at org.hibernate.impl.SessionImpl.createQuery(SessionImpl.java:1650)
18:18:10,694 ERROR [STDERR] at org.hibernate.ejb.AbstractEntityManagerImpl.createQuery(AbstractEntityManagerImpl.java:93)
18:18:10,694 ERROR [STDERR] at org.jboss.jpa.tx.TransactionScopedEntityManager.createQuery(TransactionScopedEntityManager.java:139)
18:18:10,694 ERROR [STDERR] at doku.edp.trasactions.Eds2UtilityBean.getFieldDataFromBlacklist(Eds2UtilityBean.java:325)
18:18:10,694 ERROR [STDERR] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
18:18:10,695 ERROR [STDERR] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
18:18:10,695 ERROR [STDERR] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
18:18:10,695 ERROR [STDERR] at java.lang.reflect.Method.invoke(Method.java:597)
18:18:10,695 ERROR [STDERR] at org.jboss.aop.joinpoint.MethodInvocation.invokeTarget(MethodInvocation.java:122)
18:18:10,695 ERROR [STDERR] at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:111)
18:18:10,695 ERROR [STDERR] at org.jboss.ejb3.EJBContainerInvocationWrapper.invokeNext(EJBContainerInvocationWrapper.java:69)
18:18:10,695 ERROR [STDERR] at org.jboss.ejb3.interceptors.aop.InterceptorSequencer.invoke(InterceptorSequencer.java:73)
18:18:10,695 ERROR [STDERR] at org.jboss.ejb3.interceptors.aop.InterceptorSequencer.aroundInvoke(InterceptorSequencer.java:59)
18:18:10,695 ERROR [STDERR] at sun.reflect.GeneratedMethodAccessor522.invoke(Unknown Source)
18:18:10,695 ERROR [STDERR] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
18:18:10,695 ERROR [STDERR] at java.lang.reflect.Method.invoke(Method.java:597)
18:18:10,695 ERROR [STDERR] at org.jboss.aop.advice.PerJoinpointAdvice.invoke(PerJoinpointAdvice.java:174)
18:18:10,695 ERROR [STDERR] at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102)
18:18:10,695 ERROR [STDERR] at org.jboss.ejb3.interceptors.aop.InvocationContextInterceptor.fillMethod(InvocationContextInterceptor.java:72)
18:18:10,695 ERROR [STDERR] at org.jboss.aop.advice.org.jboss.ejb3.interceptors.aop.InvocationContextInterceptor_z_fillMethod_405857447.invoke(InvocationContextInterceptor_z_fillMethod_405857447.java)
18:18:10,695 ERROR [STDERR] at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102)
18:18:10,695 ERROR [STDERR] at org.jboss.ejb3.interceptors.aop.InvocationContextInterceptor.setup(InvocationContextInterceptor.java:88)
18:18:10,695 ERROR [STDERR] at org.jboss.aop.advice.org.jboss.ejb3.interceptors.aop.InvocationContextInterceptor_z_setup_405857447.invoke(InvocationContextInterceptor_z_setup_405857447.java)
18:18:10,695 ERROR [STDERR] at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102)
18:18:10,695 ERROR [STDERR] at org.jboss.ejb3.connectionmanager.CachedConnectionInterceptor.invoke(CachedConnectionInterceptor.java:62)
Я вижу свою базу данных Postgres, когда явыполняя SELECT
запрос к таблице, я получаю предупреждение:
разрешение отклонено для белого списка отношений.
Является ли предупреждение на Postgres причиной этой ошибки