Folks,
I have a following table in my PostgreSQL.
CREATE TABLE public.my_table
(
id uuid NOT NULL,
name character varying(50) NOT NULL,
field1 jsonb NOT NULL
)
I keep JSON array in my field1 as per example below:
[
{
"id": "abc"
},
{
"id": "def"
},
{
"id": "ghi"
}
]
My question is: How do I query for rows that include a specific "id" in that JSON array?
Thanks for your help! Cheers!