Strange mysql date problem
Posted
#1
(In Topic #1047)
Regular

Code
hResult = hConn.Find("transactions", "ORDER BY TransDate")
produces:-<LIST>
- <LI>27/01/0022 00:00:00
27/01/0022 00:00:00
31/01/0022 00:00:00
31/01/0022 00:00:00
01/12/2021 00:00:00
01/12/2021 00:00:00
01/12/2021 00:00:00
01/12/2021 00:00:00
01/12/2021 00:00:00
01/12/2021 00:00:00
01/12/2021 00:00:00
01/12/2021 00:00:00</LI>
The first four records are out of sequence, the remainder are all correct.
The first four records are the most recent addition to the database so perhaps something has changed in Gambas3 or in mysql
Gambas v3.18.2
mysql Ver 8.0.33-0ubuntu0.22.04.2
This is a worrying failure of a basic function so any ideas would be appreciated.
Posted
Administrator

I see a correct order as the year 22 is way before 2021.bill-lancaster said
produces:-<LIST></LIST>
- <LI>27/01/0022 00:00:00
27/01/0022 00:00:00
31/01/0022 00:00:00
31/01/0022 00:00:00
01/12/2021 00:00:00
01/12/2021 00:00:00
01/12/2021 00:00:00
01/12/2021 00:00:00
01/12/2021 00:00:00
01/12/2021 00:00:00
01/12/2021 00:00:00
01/12/2021 00:00:00</LI>
The first four records are out of sequence, the remainder are all correct.
I guess you wanted the year 2022 instead of 22, but put in the wrong year.
gbWilly
- Gambas Dutch translator
- Gambas wiki content contributor
- Gambas debian/ubuntu package recipe contributor
- GambOS, a distro for learning Gambas and more…
- Gambas3 Debian/Ubuntu repositories
… there is always a Catch if things go wrong!
- Gambas Dutch translator
- Gambas wiki content contributor
- Gambas debian/ubuntu package recipe contributor
- GambOS, a distro for learning Gambas and more…
- Gambas3 Debian/Ubuntu repositories
… there is always a Catch if things go wrong!
Posted
Regular

1 guest and 0 members have just viewed this.


