-
Notifications
You must be signed in to change notification settings - Fork 521
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
HugeGraph的id策略疑问 #1349
Comments
首先得明白选择主键模式的原因, 这得从自己业务需求和数据来看:
如果你并不存在以上场景需要, 选择自定义主键就可以了. (此时你需要自己维护vid唯一, 参考文档) 如果你需要主键模式的益处, 再回到你说的问题:
|
感谢大佬回复! |
你应该用的v0.11 版本的 Server 吧, 因为主键模式下数值类型会做统一编码/压缩, 你也有两个方式:
方法1可以优先考虑. |
明白了,再次感谢大佬! |
我在设置id策略为PRIMARY_KEY以后,查看点的id仍然为系统生成的id,形式如:10:11 。
我在建立边的时候,希望通过主键来进行关联,但是API中需要使用id。id对我来说是未知的值,导致每次加载边都需要先查出来id,然后再进行关联。有没有办法可以让id直接和主键相等,从而解决这个问题?
The text was updated successfully, but these errors were encountered: