I came across a use case where I wanted to generate a combination table where the attributes of a record had to be matched with all other records in the table. Something like creating list of edges in a Complete Graph using a nodes table. To give you an example of the requirement, you can consider the following table (Postgres).
I’m trying to do a select statement to order the result set by force of connections between them. ‘isConnectedTo’ edges relate Entities to another Entities The tricky part is I have double connections between the same entities as so: So Mike is connected to John which is connected to him too. Also Mike is connected to Susan. In this case