Kushal Das :python: :tor: 🇵🇸 on Nostr: Amy #django #orm person: How to convert the following to a QuerySet (I would love to ...
Amy #django #orm person:
How to convert the following to a QuerySet (I would love to have objects than values/dict)? #python
```
SELECT "containers_containerbase"."id",
"containers_containerbase"."cid",
"containers_containerbase"."cname",
MAX("containers_containerbase"."ctime")
FROM "containers_containerbase"
GROUP BY cname
```
Published at
2024-08-21 22:00:11Event JSON
{
"id": "8f6b8e19cbf5e7f397244f5e43cccd44939bfa190f25f56973c963eac6d03d2d",
"pubkey": "3df3d89bb59a64ff75dd54697fd4b32aacd77fa3a90bcd893f733339015c2089",
"created_at": 1724277611,
"kind": 1,
"tags": [
[
"proxy",
"https://toots.dgplug.org/@kushal/113002257577861257",
"web"
],
[
"t",
"orm"
],
[
"t",
"django"
],
[
"t",
"python"
],
[
"proxy",
"https://toots.dgplug.org/users/kushal/statuses/113002257577861257",
"activitypub"
],
[
"L",
"pink.momostr"
],
[
"l",
"pink.momostr.activitypub:https://toots.dgplug.org/users/kushal/statuses/113002257577861257",
"pink.momostr"
],
[
"-"
]
],
"content": "Amy #django #orm person:\n\nHow to convert the following to a QuerySet (I would love to have objects than values/dict)? #python \n\n```\nSELECT \"containers_containerbase\".\"id\",\n \"containers_containerbase\".\"cid\",\n\t \"containers_containerbase\".\"cname\",\n MAX(\"containers_containerbase\".\"ctime\")\n FROM \"containers_containerbase\"\n GROUP BY cname\n```",
"sig": "9499a18d20693fca746cd52550289644f6846b65a7dd597f8d1e4db703d8d3efea41c30ac555ad1266bbdad338fcbd79b4777c50d6dbb5054b13078ddbc51a4f"
}