Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8399967
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T21:26:37+00:00 2026-06-09T21:26:37+00:00

I have a graph database in ne04j where the nodes are connected to each

  • 0

I have a graph database in ne04j where the nodes are connected to each other based on a directed relation(knows).
A->B
A->C
A->E
etc.

The nodes are indexed based on the user ID so I can find any node. No problem with that.

The question is how to find all the nodes that are linked to node A. I guess it has something to do with outgoing relationship but I dont know how to actually implement it. I am new to neo4j though i understand the graph concepts involved. I am using Everyman neo4j php graph api.

Do I need to index the relationship as well to achieve what I am trying to do or is it possible via a function to get all the connected nodes?

Thanks!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-09T21:26:38+00:00Added an answer on June 9, 2026 at 9:26 pm

    In Neo4jPHP you can do:

    $node = $client->getNode($nodeId);
    $relationships = $node->getRelationships(array('KNOWS'), 'out');
    $outgoingNodes = array_map(function ($rel) {
        return $rel->getEndNode();
    }, $relationships);
    

    This is more performant than Cypher if all you want to do is retrieve the nodes. Use Cypher if you need to do more complicated path matching.

    More information here: https://github.com/jadell/neo4jphp/wiki/Nodes-and-Relationships under the section “Retrieve Relationships from a Node”

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a database called RankHistory that is populated daily with each user's username
I have a graph that contains nodes (groups) composed by inner nodes and when
I have 6 graph bars with the prices. Each price number will represent its
I have a graph with n nodes as an adjacency matrix . Is it
I have oriented graph. Graph can be strongly connected. Every vertex can have a
I need to represent graph information with relational database. Let's say, a is connected
Greetings, Is there any open source graph database available other than Neo4J?? NOTE: Why
Say I have a vertex {first_name, last_name} in a graph database (Neo4j in this
Abstract problem : I have a graph of about 250,000 nodes and the average
I have a graph that auto fills based on a few values. The values

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.