Mongodb type reference node

后端 未结 4 1375
情深已故
情深已故 2021-02-18 22:25

I am trying reference another object in a model in node,

User = new Schema({
        username: {
            type: String,
            index: {unique: true}
             


        
4条回答
  •  囚心锁ツ
    2021-02-18 22:44

    Here is link to manual @ refs.

    Tho You can't use refs at schema design level.

提交回复
热议问题