Marc Planard on Nostr: npub1eqghr…6fncn async is not the issue, SQL definitely is as I'm definitely ...
npub1eqghrdelwyf920kghgwlmkjve6ptgnjy3jzkpfvxjmmjsh4em83sq6fncn (npub1eqg…fncn) async is not the issue, SQL definitely is as I'm definitely terrible with it. But that's the thing: maybe I need to become less terrible at SQL instead of letting an ORM babysit me.
What made me pause and write this message is that I have to write like 5 or 10 queries which all have the same SELECT part and they just have the WHERE / ORDER / LIMIT part being different. Yet with sqlx I have no idea how to do that without repeating myself (and using concat!() for that sounds gross...)
Published at
2023-11-10 18:07:17Event JSON
{
"id": "5158662af9983405e1d67423eae1443590372c010438640100dfc42387107834",
"pubkey": "79c16d9c318f770b262a163ddc7d2c8c449ff553f4bec786d8479ebf207dfd4d",
"created_at": 1699639637,
"kind": 1,
"tags": [
[
"p",
"c81171b73f7112553ec8ba1dfdda4cce82b44e448c8560a58696f7285eb9d9e3",
"wss://relay.mostr.pub"
],
[
"p",
"5bdfe5c3188a24f76efd37648930d8ada3e458961d03b2e0d62596d4f76e4778",
"wss://relay.mostr.pub"
],
[
"e",
"c3fe3c1b3d4290e0be564c0ba209f366362d50738770ac936a2c31fc88b0b4ac",
"wss://relay.mostr.pub",
"reply"
],
[
"proxy",
"https://mamot.fr/users/corpsmoderne/statuses/111387583267209072",
"activitypub"
]
],
"content": "nostr:npub1eqghrdelwyf920kghgwlmkjve6ptgnjy3jzkpfvxjmmjsh4em83sq6fncn async is not the issue, SQL definitely is as I'm definitely terrible with it. But that's the thing: maybe I need to become less terrible at SQL instead of letting an ORM babysit me. \nWhat made me pause and write this message is that I have to write like 5 or 10 queries which all have the same SELECT part and they just have the WHERE / ORDER / LIMIT part being different. Yet with sqlx I have no idea how to do that without repeating myself (and using concat!() for that sounds gross...)",
"sig": "66bca83ee95229b2a89d07a7e9d1d45aa8c5212bb2c9bee75530c5e13229e0714ae7fd8f5519925b7ea826e6d3ba22b1885670e17d5b080d5066b0c03d53ae3a"
}