4
I’m trying to get the biggest date registered in my BD
, I am trying to use the functions MAX and DATE_FORMAT together and the search result is not what expected, I have these dates registered:
2016-10-24 2016-10-25 2016-10-26 2016-10-27 2016-10-28 2016-10-31 2016-11-01 2016-11-03 2016-11-04 2016-11-07 2016-11-08
What the query returns to me is the day 2016-10-31
and should be 2016-11-08
, I understand that I am not executing the query correctly, what I am doing at the moment is this:
SELECT MAX(DATE_FORMAT(Data,'%d/%m/%Y')) as DataInicial FROM calendarioDolar
Hello @Sorack, thank you so much for the tip, solved my problem.
– adventistapr
Dispose! I will add a brief explanation. If you can approve as correct answer it will be of great value to those who research for the same problem
– Sorack
I’m waiting for the 4 min for approval, there’s a time limit between response and approval.
– adventistapr