I am getting error on JoinEnrichment and don't know why it is coming.
My query in JoinEnrichment :
SELECT original.*, enrichment.*
FROM original
FULL JOIN enrichment
ON original.name = enrichment.name
Error
JoinEnrichment[id=a17b1f06-f80c-3641-945f-c2ff331f8028] Failed to join 'original' FlowFile FlowFile[filename=cmdbci-mtaas] and 'enrichment' FlowFile FlowFile[filename=cmdbci-mtaas]; routing to failure: java.sql.SQLException: Error while preparing statement [SELECT original., enrichment.
FROM original
FULL JOIN enrichment
ON original.name = enrichment.name]
Caused by: org.apache.calcite.runtime.CalciteContextException: From line 4, column 4 to line 4, column 34: Cannot apply '=' to arguments of type '<JAVATYPE(CLASS JAVA.LANG.OBJECT)> = <JAVATYPE(CLASS JAVA.LANG.STRING)>'. Supported form(s): '<COMPARABLE_TYPE> = <COMPARABLE_TYPE>'
Caused by: : Corg.apache.calcite.sql.validate.SqlValidatorExceptionannot apply '=' to arguments of type '<JAVATYPE(CLASS JAVA.LANG.OBJECT)> = <JAVATYPE(CLASS JAVA.LANG.STRING)>'. Supported form(s): '<COMPARABLE_TYPE> = <COMPARABLE_TYPE>'
Sample input from original
Location,Environment,ip_address,category,name,dv_sys_updated_on
"",,,Hardware,Ndiggan,2022-12-17 22:37:28
"",,,Hardware,class,2022-12-31 22:37:38
"",,,,Vlan2,2022-12-27 02:17:13
Sample input from enrichment
Location,Environment,ip_address,category,name,dv_sys_updated_on
"",,,Hardware,vpna,2022-12-17 22:36:02
"",,,Hardware,dlcccno,2022-12-17 22:37:04
"",,,Hardware,Ndiggan,2022-12-17 22:37:28
I have an application with spring 2.6.8, I have migrated it to 2.7.4.
And everything works correctly.
But when I have upgraded from java 11 to java 17 it gives me the following error
#Cacheable(value = "datoAuxiliar", key = "{#nombre, #tipo}", unless = "#result == null")
public DatoAuxiliar findByTipoAndSecurityDomainAndNombre(TipoDatoAuxiliar tipo, SecurityDomain securityDomain,
String nombre);
-- ERROR
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'tipoContratoSelectItemController': Invocation of init method failed; nested exception is java.lang.IllegalArgumentException: Null key returned for cache operation (maybe you are using named params on classes without debug info?) Builder[public abstract java.util.List com.xxx.xxx.repository.DatoAuxiliarRrhhRepository.findByTipoAndSecurityDomainAndDeletedIsNull(com.abalia.elser.domain.enumeration.TipoDatoAuxiliar,com.abalia.elser.domain.SecurityDomain)] caches=[datoAuxiliar] | key='#tipo' | keyGenerator='' | cacheManager='' | cacheResolver='' | condition='' | unless='#result == null' | sync='false'
I've tried several things but they don't work for me.
Can someone help me with this problem?
Thanks.
I tried to execute this sql but Exception happened.
source code is here
#Select(
"""
SELECT
COUNT(*)
FROM
order
WHERE
order_id IN
<foreach item="id" collection="orderIds" open="(" separator="," close=")" >
#{id}
</foreach>
"""
)
fun findByOrderIds(#Param(value = "orderIds") orderIds: List<String>): Int
Error message is here↓
nested exception is org.apache.ibatis.binding.BindingException: Parameter 'id' not found. Available parameters are [orderIds, param1]
I cannot find wrong point.
If you have idea please let me know.
Following is the exception stackify shows me on dashboard:
ERROR The string was not recognized as a valid DateTime. There is an unknown word starting at index 0.
System.FormatException: The string was not recognized as a valid DateTime. There is an unknown word starting at index 0. ---> System.FormatException: null is not a valid value for DateTime.
at System.DateTimeParse.Parse
at System.ComponentModel.DateTimeConverter.ConvertFrom
--- End of inner exception stack trace ---
at System.ComponentModel.DateTimeConverter.ConvertFrom
at System.ComponentModel.NullableConverter.ConvertFrom
at Microsoft.AspNetCore.Mvc.ModelBinding.Binders.SimpleTypeModelBinder.BindModelAsync
I am not able to understand which field of the viewmodel causes the issue like this. How can I catch this exception on my local code?
enter code hereHi I'm using Entity manager(EJB) which internally depends on hibernate to get Object.
My query is ........
TypedQuery<FraudDetectionInfoEntity> queryKount = em_oltp.createQuery("SELECT o FROM FraudDetectionInfoEntity o WHERE o.order.orderId=:orderId",FraudDetectionInfoEntity.class);
query.setParameter("orderId", orderEntity.getOrderId());
FraudDetectionInfoEntity infoEntity=queryKount.getSingleResult();
I'm getting folowing error If I run that query.
org.hibernate.QueryParameterException: could not locate named parameter [orderId]
org.hibernate.QueryParameterException: could not locate named parameter [orderId]
12:46:58,639 ERROR [com.vip.enterprise.admin.web.controller.OrderPlacementController] (http-/127.0.0.1:8084-6) error com.vip.enterprise.service.exception.ServiceException: org.hibernate.QueryParameterException: could not locate named parameter [orderId]
12:47:00,001 ERROR [com.vip.enterprise.service.jobs.ReplenishmentJob] (EJB default - 4) Replenish Orders JOB : Mon Jan 27 12:47:00 IST 2014
Your code is ok. Missing variable query or queryKount?
TypedQuery<FraudDetectionInfoEntity> queryKount = em_oltp.createQuery("SELECT o FROM FraudDetectionInfoEntity o WHERE o.order.orderId=:orderId",FraudDetectionInfoEntity.class);
query.setParameter("orderId", orderEntity.getOrderId());
<or>
queryKount.setParameter("orderId", orderEntity.getOrderId());