Skip to content
Advertisement

SQL query returns double data

The above code outputs the following:

Why does the resultlist contain the same data multiple times and how can I prevent that? I cannot use select distinct id because I need all columns.

Advertisement

Answer

A further look into the Group table was the clue: Two Groups had stored the Item with id 500. Changing that fixed the duplicates issue. I still get an Invalid OP Exception on another point in the code because of a circular reference problem.

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