Skip to content
Advertisement

Select JSON object that appears more than one time

I am trying to write a query to return all trains that have more than one etapesSupervision.

My table has a column called DETAIL, in this column I can find the JSON of my train.

This is the query I wrote :

Using this, I return trains with only one etapesSupervision.

The thing is the column DETAIL is JSON, so I feel like I can’t do a lot with it.

I tried also with like, but it doesn’t work either.

Advertisement

Answer

Thank you for your comments. This is the query that worked:

And this way I have only trains that have more than one supervisor.

Thanks again

User contributions licensed under: CC BY-SA
8 People found this is helpful
Advertisement