I try to modelling stock database. Currently the model like this
UC1: I want to know the history of increasing share of the company. So I have Share Node.
Each Share node have properties: numberOfShare and INCREASE_SHARE relationship from preveous Share Node to Onother Share Node.
(s1 Share {code:'Company A'}-[r:INCREASE_SHARE]->(s1 Share {code:'Company A'}
like this picture
UC2: I also want to maintain the numberOfShare each person or company have at this any point.
So I add:
(p:Person)-[r:HAS_SHARE]->(s:Share)
(s:Share {code:'Company A')-[r:HAS_SHARE]->(s:Share {code:'Company B')
RelastionShip.
As you can see in the picture when the numberOfShare of the Company B increase, some person (red Person) or some company doesnot want to increase the share that they are holding.
That Why adding duplicate relasionship is not needed. I can use the old numberOfShare in the Yellow relationship.
How can i do it?