| ▲ | tracker1 5 days ago | |||||||
As others mention, you can create indexes directly against the json without projecting in to a computed column... though the computed column has the added benefit of making certain queries easier. That said, this is pretty much what you have to do with MS-SQL's limited support for JSON before 2025 (v17). Glad I double checked, since I wasn't even aware they had added the JSON type to 2025. | ||||||||
| ▲ | advisedwang 5 days ago | parent | next [-] | |||||||
Exclusively using computed columns, and never directly querying the JSON does have the advantage of making it impossible to accidentally write a unindexed query. | ||||||||
| ▲ | selimthegrim 5 days ago | parent | prev [-] | |||||||
I did hear about it at a local DBA conference but didn't think it was a big deal | ||||||||
| ||||||||