yayza_
KKysely
•Created by yayza_ on 3/26/2025 in #query-showcase
A pagination helper
i tried to do that, but I ended up with an error because my main query uses a subquery, so I had to keep select clause too,
but that means my main query would select rows and run agg functions again 🤔 just to get a count.
i tested both queries and i'm getting same counts so far but i'll keep trying to do it like you mentioned because i definitely don't want removing groupBy to have an unintended effect
4 replies
KKysely
•Created by yayza_ on 3/26/2025 in #query-showcase
A pagination helper
lmk if i can make it better.. i'm still learning 🙂
4 replies
Inconsistent Typing of NUMERIC Fields with jsonBuildObject
I recently came a cross this as well , when a property is numeric i have to cast it to text or it will change the value to a number and i lose precision
price: sql<string>
${eb.ref('product.price')}::TEXT,
10 replies