ClanCats / Hydrahon

🐉 Fast & standalone PHP MySQL Query Builder library.
https://clancats.io/hydrahon/master/
MIT License
278 stars 58 forks source link

Hydrahon method first not return the first result after a order by #64

Open DioxideHydrogen opened 1 year ago

DioxideHydrogen commented 1 year ago

I was doing a charge system for my company. And i haved that verify if the client X already haved a charge created in the respectly YearMonth (YYYYMM).

I did the query and i asked to hydrahon class fetch all payments charges, order by (ID, DESC), and bring the first result. But instead of he give me first result of ordering, he bringed to me first result before ordering!

This was the query methods: Imagem do WhatsApp de 2022-11-28 à(s) 10 35 04

This was the result he bring me. Imagem do WhatsApp de 2022-11-28 à(s) 10 35 28

This is what he need bring me: Imagem do WhatsApp de 2022-11-28 à(s) 10 35 41