817
Good Morning (lemmy.ml)
you are viewing a single comment's thread
view the rest of the comments
[-] jubilationtcornpone@sh.itjust.works 41 points 1 week ago* (last edited 1 week ago)

What's that? Did you say you needed an RDBMS that can also handle JSON data? Well have I got good news for you!

[-] derpgon@programming.dev 11 points 1 week ago

Mysql / Mari can handle it too! Just use BLOB 🤣

[-] lime@feddit.nu 28 points 1 week ago

pg can actually query into json fields!

[-] Tanoh@lemmy.world 14 points 1 week ago

And you can add indexes on those JSON fields too!

[-] Tja@programming.dev 7 points 1 week ago

Kind of. I hope you don't like performance...

The performance is actually not bad. You're far better off using conventional columns but in the one off cases where you have to store queryable JSON data, it actually performs quite well.

[-] Tja@programming.dev 2 points 1 week ago

Quite well is very subjective. It's much slower than columns or specialized databases like MongoDB.

[-] Tanoh@lemmy.world 1 points 1 week ago

Sure, if you use a field often it is most likely better to extract it into a column with auto-updates from the JSON data.

But you have to tune it and see what is best for your use case. Just saying that you can add indexes to JSON fields as well!

[-] derpgon@programming.dev 3 points 1 week ago
[-] lime@feddit.nu 4 points 1 week ago

oh i didn't know that. iirc postgres easily beats mongo in json performance which is a bit embarrassing.

[-] derpgon@programming.dev 1 points 1 week ago

Holy, never knew, and never would expect. Postgres truly is king.

this post was submitted on 18 Jul 2025
817 points (99.4% liked)

Programmer Humor

25282 readers
871 users here now

Welcome to Programmer Humor!

This is a place where you can post jokes, memes, humor, etc. related to programming!

For sharing awful code theres also Programming Horror.

Rules

founded 2 years ago
MODERATORS