[resolved] SQL query returning different results within talend
Hi, I have a tMysqlInput component that runs this query :
SELECT IF (LENGTH(MONTH(a.currentDate)) = 2,CONCAT(YEAR(a.currentDate), "-",
MONTH(a.currentDate), "-00"), CONCAT(YEAR(a.currentDate), "-0", MONTH(a.currentDate),
"-00")) AS currentMonth, SUM(dataCount) AS dataCount
FROM dw_stats_newAnnonceCount_daily a
WHERE MONTH(a.currentDate) = MONTH(CURDATE())
GROUP BY MONTH(a.currentDate)
When executed directly on the server, it gives me the appropriate results :
currentMonth dataCount
2010-04-00 171416
When executed withing the component, it gives me weird stuff :
2010-03-31|171416
The data count is accurate but for some reasons, my date workaround doesn't work well with talend.
Maybe a bug but not sure.
Any idea anyone?