Reputation: 553
I have object Event that i want to save is location. i thinking on 2 ways to do that: 1.make Event node and connect him to location node and save there the location 2.save the location on the Event node.
Considering that in the future I would be interested to pull the information on all the events carried out in a certain place. What is the most effective way?
Additional question that i have about effective. i have 2 users: mobile application user and web users. and i thinking on effective way to save the information. also here i thinking on 2 ways: 1.save the data on all users in one node and add to app users label mobile 2.save the data on all users in one node and connect him to node that will save only the device type.
Considering that in the future I would be interested to pull the information on all the users that use IOS/Android. What is the most effective way?
Upvotes: 2
Views: 176
Reputation: 10856
It depends on what you want to do with the location information. Some reasons why you might use Location
nodes (and thus make a relationship between Event
and Location
):
Event
But if you just have a lat/long or a location name you're more in the territory of just having a property on the Event
. If you're going to query on the property make sure you have an index (that goes for whatever properties you'd want to query on Location
nodes too).
Regarding users: You're probably asking for headaches if you're going to store two sets of users. I would have one set of users and use properties like logged_in_with_android
.
Upvotes: 2