How to ensure Graph relation is UNIQUE? #5778
Unanswered
shiyewuxian
asked this question in
Q&A
Replies: 2 comments
-
Ah, I found another similar one discussion: https://github.com/orgs/surrealdb/discussions/1425 @tobiemh May I have your advice when this function will be issued? Thanks. |
Beta Was this translation helpful? Give feedback.
0 replies
-
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
When I was trying to build Graph relations, I found even if there's already a relation (
person:a->likes->person:b
) in SurrealDB, if I run the same:RELATE person:a->likes->person:b
, the likes table will create another in:person:a
and out:person:b
once again.The only difference is using different ID.
However, for many cases, we would like to keep the entities UNIQUE, otherwise it's will be hard to get clear relations.
My question is: is there a simple way to realise the UNIQUE?
Beta Was this translation helpful? Give feedback.
All reactions