Skip to content
Advertisement

Tag: postgresql

How I can update one to many relation in Postgres?

Here is my first table question. Questions have many options, so I referring every option row with question_id Now, How can I update both tables in one query? I building an API. The below-given output is for request. The request will response with question details and options for the question. I am able to update question but questions have many

Remove Duplicate Result on Query

could help me solve this duplication problem where it returns more than 1 result for the same record I want to bring only 1 result for each id, and only the last history of each record. My Query: Result of my query, but returns 3 or 5 identical ids with different histories I want to return only 1 id of

Advertisement