250x250
Notice
Recent Posts
Recent Comments
- Today
- Total
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | ||||||
2 | 3 | 4 | 5 | 6 | 7 | 8 |
9 | 10 | 11 | 12 | 13 | 14 | 15 |
16 | 17 | 18 | 19 | 20 | 21 | 22 |
23 | 24 | 25 | 26 | 27 | 28 |
Tags
- sequelize
- TypeScript
- til
- jsonwebtoken
- Find
- single quote
- JavaScript
- clipBehavior
- EC2
- async
- RDS
- moment
- nginx
- flutter
- Node.js
- mongoose
- https
- TailwindCSS
- MYSQL
- await
- findByIdAndDelete
- certbot
- css
- mongodb
- Nodejs
- Express
- AWS
- wil
- atlas
- double quote
Link
Archives
반응형
목록findOne (1)
기억 휘발 방지소
[Node.js / mongoose] findOne, findById로 검색을 해보자
검색을 할 때에도 2가지 방법으로 할 수 있다. findById() findOne() 📌 Model.findById(id) _id를 기준으로 단일 문서를 찾는다. _id를 기준으로 질의하려면 findOne()대신에 findById()를 사용하라고 한다. 참고문서 Mongoose v6.0.6: Parameters doc «Object» values for initial set optional «[fields]» object containing the fields that were selected in the query which returned this document. You do not need to set this parameter to ensure Mongoose handles your query ..
Database/ODM
2021. 9. 20. 22:17
반응형