Skip to content

Custom Edge Names #135

@rasjonell-zz

Description

@rasjonell-zz

I already have a project that uses ArangoDB, I wanted to use Cruddl for a new feature. The Data Modeling doc states that:

In ArangoDB, relations are stored in an edge collection with the name orders_customer (the plural of the source object combined with the field name).

However I have a different approach designing my db regarding edge names and would be really nice to be able to give custom names to relationships. ie:

type Customer @rootEntity {
  name: String
  orders: [Order] @relation(edge: "has_ordered", inverse_edge: "was_ordered_by")
}

Also it was unclear whether it is possible to give custom attributes to edges besides _from and _to.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions