I'm very new to neo4j and hence this question, I have my data in the format:
movie_id cast
1
[{'cast_id': 14, 'character': 'Woody (voice)', 'credit_id': '52fe4284c3a36847f8024f95', 'gender': 2, 'id': 31, 'name': 'Tom Hanks', 'order': 0, 'profile_path': '/pQFoyx7rp09CJTAb932F2g8Nlho.jpg'}, {'cast_id': 15, 'character': 'Buzz Lightyear (voice)', 'credit_id': '52fe4284c3a36847f8024f99', 'gender': 2, 'id': 12898, 'name': 'Tim Allen', 'order': 1, 'profile_path': '/uX2xVf6pMmPepxnvFWyBtjexzgY.jpg'}
where movie_id is the ID of the movie and cast contains a multiple dictionaries consisting of different casts and their information in the form of key value pairs. I want to form relationship between NODE Movie and NODE Cast (for unique 'cast_id', rest all like 'cast_name' would be node attributes.
For example, in the above example,
Node Movie (movie_id=1) --- ACTED_BY --- Node Cast (cast_id=14, cast_name='Tom Hanks' )
Node Movie (movie_id=1) --- ACTED_BY --- Node Cast (cast_id=15, cast_name='Tim Allen' )
since there are two dictionaries .... Please help. I'm very new to this.