JSONB column: sort only content of arrays stored in column with mixed JSONB content
问题 I have a table with JSONB column storing JSONB arrays/strings ( value_r column in the below example). What would be the simplest (and efficent) way to sort only content of JSONB arrays within JSONB column (storing also strings)? I've been looking for the simplest method (as query, or procedure is needed?) because I have to apply this in more complicated SQL code. Here is the test code: CREATE TABLE test_table ( id integer, ordinality bigint, key_r text, value_r jsonb ); INSERT INTO test_table