bjorngranvik / reudd

REgarding User Driven Development - a user centric "data in/report out" web site using Neo4j.
Apache License 2.0
1 stars 0 forks source link

Make the bulk import accept multiple import types #17

Closed bjorngranvik closed 10 years ago

bjorngranvik commented 10 years ago

Currently the bulk import only supports type information on the first row (see ProgrammerController.bulkAddSubmit). We could add a check per row to see if we get "type:" and redo the type information assignment (see bulktext and its first loop).

This would be very beneficial for entering simple subgroups.

matsjonas commented 10 years ago

What format do you suggest for the import? When I look at the code it seems as though it should be able to import something like this:

type:           ; name     ; alive
Person          ; Jonas    ; true
Person, Genius  ; Einstein ; false
Animal, Gorilla ; Koko     ; true

Haven't tried it thoug so I cannot verify.

bjorngranvik commented 10 years ago

That should work but it will produce the same type of attributes on both a person and a gorilla. I mean something like:

type: ; name ; alive Person ; Jonas ; true Person, Genius ; Einstein ; false type: ; name ; rel:....Owned_by <--- Too late, can't remember syntax Car ; Volvo ; Jonas

This way we can better describe subgraphs with various types and attributes.

/Björn

11 sep 2013 kl. 22:36 skrev Jonas Andersson:

What format do you suggest for the import? When I look at the code it seems as though it should be able to import something like this:

type: ; name ; alive Person ; Jonas ; true Person, Genius ; Einstein ; false Animal, Gorilla ; Koko ; true Haven't tried it thoug so I cannot verify.

— Reply to this email directly or view it on GitHub.

matsjonas commented 10 years ago

I added an example csv file to the repository so we can see the format that is supported in commit c03a6c3.

It can handle multiple types and references back and forth between nodes. If the types have different attributes the csv file should simply not specify values for the nodes on that attribute's column.

matsjonas commented 10 years ago

Closing this issue since we support all features requested already. Perhaps not in the exact format that is requested, but if we plan to use Geoff in the future a total re-write will be necessary no matter what.

bjorngranvik commented 10 years ago

Good simple solution that works. Me like. Geoff can wait.