Then check the relationship (type and direction) from n to pulse if it
exists.

Michael

On Thu, Apr 27, 2017 at 8:08 AM, Alliance Ais <[email protected]>
wrote:

> Thanks for given your valuable time. But We cannot fetch any pulse that
> you mentioned as *p2* in cypher Query. We get only null value for *p2. *Please
> suggest us what we have to change in my Cypher Query?
>
>
>
> On Thursday, April 27, 2017 at 1:18:43 AM UTC+5:30, Kamal Murthy wrote:
>>
>> Hi,
>>
>> I added a variable 'p2' for pulse (shown in bold) in the optional match
>> and added the same variable to the return list. Here is the query:
>>
>> match (n)-[r1]->(p)-[r2]->(b:business)
>> where id(n) = {otherUserId}
>>
>> where r1.onPulse=true and r2.onPulse= true and
>> (p:check_in OR p:tip OR p:review or p:rate)
>> optional match (n)-[:pulse_post]->*(p2*:pulse)
>> optional match(p)-[r3:has_pix]->(pix:pix)
>> OPTIONAL MATCH (p)-[tg:has_biz_tag|has_user_tag|has_hash_tag]->(tags)
>> return n,r1,p,r2,r3,pix,tg,tags,*p2*
>>
>> -Kamal
>>
>> On Wednesday, April 26, 2017 at 12:07:44 AM UTC-7, Alliance Ais wrote:
>>>
>>>
>>> <https://lh3.googleusercontent.com/-eDX3rqw_T3Y/WQBE4VCiZPI/AAAAAAAAC8o/tOrnfgJiIm4lYYxFBwj6UJcNW5zGExT9ACLcB/s1600/neo4j.jpg>
>>> Hi, Michael Hunger
>>>
>>> Thanks for reply and your query helped us a lot but little issue we have
>>> that i am sharing with you please help us as we are near to complete
>>> project as we stuck above requirement.
>>>
>>> Let me explain where we are getting issue.
>>>
>>> Please refer above image, while we are using your query we are getting
>>> rate,review and tip but not getting pulse that is posted by system user,
>>> while talking about pulse one important thing i would like to share with
>>> you is pulse post done by user is not on venue[business]. where other
>>> activities [check-in, review, tip, rate] done on venue[business] by user.
>>>
>>> while using your query its not getting pulse in the result set.
>>>
>>> One more thing in final result set that we are getting from your query ,
>>> how we can set order by date in descending order for whole result set.
>>>
>>> We are waiting for your suggestion that so valuable for us.
>>>
>>>
>>>
>>>
>>> On Thursday, April 13, 2017 at 1:19:10 AM UTC+5:30, Michael Hunger wrote:
>>>>
>>>> match (n)-[r1]->(p)-[r2]->(b:business)
>>>>
>>>> where id(n) = {otherUserId}
>>>>
>>>> where r1.onPulse=true and r2.onPulse= true and (p:check_in OR p:tip OR 
>>>> p:review or p:rate)
>>>>
>>>> optional match (n)-[:pulse_post]->(pulse)
>>>>
>>>> optional match(p)-[r3:has_pix]->(pix:pix)
>>>>
>>>> OPTIONAL MATCH (p)-[tg:has_biz_tag|has_user_tag|has_hash_tag]->(tags)
>>>>
>>>> return n,r1,p,r2,r3,pix,tg,tags
>>>>
>>>>
>>>> On Fri, Apr 7, 2017 at 9:20 AM, Alliance Ais <[email protected]>
>>>> wrote:
>>>>
>>>>> Hello Following My Neo4J Query to Get *CheckIn* or *Review* or *Pixel*
>>>>> etc. which is Given by User to Business.Which I got perfectly.but *I
>>>>> want also Get Pulse which given By User but not given on Business.*
>>>>> So My Following Query is not Get Pulse.
>>>>>
>>>>>
>>>>> <https://lh3.googleusercontent.com/-UbNvvKqhcPw/WOc9moX6piI/AAAAAAAAC8I/MiUDsXow51MiVJbvn_WCaiitZlaq9wy7gCLcB/s1600/pixelPost.jpg>
>>>>>
>>>>> start n=node({otherUserId}) with n match (n)-[r1]-(p)-[r2]-(b:business)
>>>>> where r1.onPulse=true and r2.onPulse= true and ('check_in' IN labels(p) 
>>>>> OR 'tip' IN labels(p) OR 'review' IN labels(p) OR 'rate' IN labels(p)) 
>>>>> with p,r1,r2,n,b
>>>>> optional match(p)-[r3:has_pix]-(pix:pix)
>>>>> OPTIONAL MATCH (p)-[tg]-(tags)
>>>>> where type(tg) in ['has_biz_tag', 'has_user_tag', 'has_hash_tag'] return 
>>>>> n,r1,p,r2,r3
>>>>>
>>>>> Above my Relationship node. I want Neo4J Query for that.
>>>>>
>>>>>
>>>>> Also I asked in StackOverflow : http://stackoverflow.com/q/432
>>>>> 71456/2893413
>>>>>
>>>>> --
>>>>> You received this message because you are subscribed to the Google
>>>>> Groups "Neo4j" group.
>>>>> To unsubscribe from this group and stop receiving emails from it, send
>>>>> an email to [email protected].
>>>>> For more options, visit https://groups.google.com/d/optout.
>>>>>
>>>>
>>>> --
> You received this message because you are subscribed to the Google Groups
> "Neo4j" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Neo4j" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to