neo4j uuid is not created

怎甘沉沦 提交于 2019-12-13 07:30:02

问题


class Client
  include Neo4j::ActiveNode
end

> client = Client.new
 => #<Client uuid: nil, bot_client_id: nil, created_at: nil, email: nil, first_name: nil, last_name: nil, sms: nil, telegram_id: nil, updated_at: nil> 

My expectation is that the uuid would be populated.


回答1:


The uuid is only populated once the node object has been saved. So you could either do:

client = Client.create

Or:

client = Client.new
client.save


来源:https://stackoverflow.com/questions/43535208/neo4j-uuid-is-not-created

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!