# Get ID for each node

**URL:** <https://community.neo4j.com/t/get-id-for-each-node/29528>\
**Category:** Python\
**Created:** [November 24, 2020, 5:18am UTC](https://community.neo4j.com/t/get-id-for-each-node/29528 "2020-11-24T05:18:10Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![rosdiana](https://sea1.discourse-cdn.com/flex021/user_avatar/community.neo4j.com/rosdiana/32/14776_2.png) [@rosdiana](https://community.neo4j.com/u/rosdiana)\
**Post date:** [November 24, 2020, 5:18am UTC](https://community.neo4j.com/t/get-id-for-each-node/29528/1 "2020-11-24T05:18:10Z")

</div>

Hi,

I want to get ID for each node. I am using movie data from neo4j database.

In Neo4j desktop, i get the output i want.

 ![image](https://us1.discourse-cdn.com/flex021/uploads/neo4jcommunity/original/2X/2/2ee2d3eea4866d17fd37eb9376cb11e78cd03c8a.png)

But when i using the same cypher query in Python, i dont get the same output as in No4j.

Below is my code in Python.

```auto
result = tx.run("MATCH (a:Person{name:$name})"
                         "-[:ACTED_IN]->(listMovie) "
                         "RETURN a,listMovie as listMovies", name=name).data()

```

Then this is the output when i apply using Python. There is no ID (identity) for each node.

 ![image](https://us1.discourse-cdn.com/flex021/uploads/neo4jcommunity/original/2X/9/9b978fabdf74bb2d2ccb1964dd75a1ce0a05e4c2.png)

Please help me, what mistake i did. Thank you!

---

<div class="post-metadata">

**Author:** ![Cobra](https://sea1.discourse-cdn.com/flex021/user_avatar/community.neo4j.com/cobra/32/35243_2.png) [@Cobra](https://community.neo4j.com/u/Cobra)\
**Post date:** [November 24, 2020, 8:04am UTC](https://community.neo4j.com/t/get-id-for-each-node/29528/2 "2020-11-24T08:04:21Z")

</div>

Hello 🙂

You are not doing something wrong, should have a look at the function [id()](https://neo4j.com/docs/cypher-manual/current/functions/scalar/#functions-id) to get the Neo4j ID and the function [properties()](https://neo4j.com/docs/cypher-manual/current/functions/scalar/#functions-properties) to get the properties of a node 🙂

Regards,  
Cobra

---

<div class="post-metadata">

**Author:** ![rosdiana](https://sea1.discourse-cdn.com/flex021/user_avatar/community.neo4j.com/rosdiana/32/14776_2.png) [@rosdiana](https://community.neo4j.com/u/rosdiana)\
**Post date:** [November 26, 2020, 5:29am UTC](https://community.neo4j.com/t/get-id-for-each-node/29528/3 "2020-11-26T05:29:19Z")

</div>

Thanks so much! Got it.
