-
[MongoDB] document의 _id를 지정해서 데이터 삽입하기공부/MongoDB 2022. 1. 3. 00:09
_id 값에는 그냥 unique한 ID를 지정해서 insert하면 된다.
string이나 숫자도 가능
만약 같은 _id 값을 가지는 document를 insert하려고 하면 위와 같은 에러가 뜬다.
'공부 > MongoDB' 카테고리의 다른 글
[MongoDB] find( ) (0) 2022.01.09 [MongoDB] CRUD Operations (0) 2022.01.09 [MongoDB] MongoDB 서버 실행 (0) 2022.01.02 [MongoDB] 데이터 삽입 및 조회 (0) 2022.01.02 MongoDB 공부 시작~! (0) 2022.01.02