7

I have a csv file that I want to import into a graph in ArangoDB. I'm using ArangoDB3-3.1.24 community version.

Here are the first three rows of the csv file

id,_from,_to,score
1,568703.1,568703.2,282
2,568703.1,568703.31,183
3,568703.1,568703.91,238

And here is what I tried

arangoimp --file "C:\Users\M\Desktop\file.csv" --server.username root --type csv --collection "Col_edge_L"

I think I'm missing something.

TylerH
  • 20,799
  • 66
  • 75
  • 101
Muna arr
  • 353
  • 2
  • 13

1 Answers1

5

If the edge collection doesn't already exist then you'll need to also pass the params --create-collection true --create-collection-type edge.

It could also be that the file may not be accessible to arangoimp - it may not have sufficient permissions to access the user's desktop. Try moving it to somewhere like c:\temp and see if that helps.

K Scandrett
  • 16,390
  • 4
  • 40
  • 65
  • I'm presuming an edge collection `_from` and `_to` should structure like a `vertex_collection_name/collection_key`. Try something like _to='geo/568703.1`. I'm not sure though. – Devaroop Oct 16 '19 at 10:37