Skip to content

Two node using the same primary key #55

@isaacguerreir

Description

@isaacguerreir

I created a simple example where field name of a Model is set to be a primary key.

{
  label: 'Vendor',
  schema: {
    name: {
      type: 'string',
      required: true,
      minLength: 1
    },
    description: {
      type: 'string',
      required: true,
      minLength: 5
    },
  },
  primaryKeyField: 'name'
}

In the docs, it says it's a unique identifier.

 /* --> (optional) the key to be used as a unique identifier, which enables some Instance methods */

I made a test and I created two Vendors with the same database. Why it is possible if both of them are unique identifiers? Is it a Neo4J thing?

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionA question about neogma or neo4j

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions