일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 |
- ReactQuery
- Drawer
- listeners
- 에뮬레이터 스킨
- 포트폴리오 사이트
- react
- 리액트 쿼리
- 리액트네이티브
- useState
- redux/toolkit
- bottom tabs
- rembg
- reactnative
- MonGo
- useRef
- bottom tabBar
- mongoDB
- react native
- Hook 함수
- tabBarStyle
- iTerm2
- oh-my-zsh
- useCallback
- useMemo
- 갤럭시 스킨
- nodejs
- Stack
- gitpages
- useEffect
- 이미지 배경 지우기
- Today
- Total
목록MongoDB (3)
프론트엔드 개발자의 개발 놀이터
1. MongoDB 모듈 NodeJS 드라이버 모듈로 MongoDB를 자체 콘솔에서 사용하는 것처럼 명령어를 그대로 사용할 수 있습니다. npm i mongodb mongodb nodejs 연결 // MongoClient : MongoDB에 연결해서 요청을 보낼 클라이언트 객체 const client = require('mongodb').MongoClient // useUnifiedTopology : 통합모드 client.connect(url, {useUnifiedTopology:true}, 콜백 함수); 로컬 pc에 연결할 때 url : mongodb://127.0.0.1:27017 다른 pc에 연결하고 싶을 때 url : mongodb://ip주소:port번호/데이터베이스 데이터베이스 연결 const..
데이터베이스 확인 > show dbs; admin 0.000GB config 0.000GB local 0.000GB 데이터베이스 생성 > use 데이터베이스명; switched to db admin - 데이터베이스가 없으면 생성 후 선택, 있으면 선택 - 데이터베이스에 자료가 없을 경우 show dbs에 나타나지 않음 데이터베이스 삭제 > db.dropDatabase(); 컬렉션 생성 > db.createCollection('컬렉션명'); 컬렉션 확인 > show collections; 컬렉션 삭제 > db.컬렉션명.drop(); Document 추가 > db.컬렉션명.insert({키1:값1, 키2:값2, ...}); ex) db.member.insert({"userid": "apple", "userp..
https://www.mongodb.com/docs/manual/tutorial/install-mongodb-on-os-x/ Install MongoDB Community Edition on macOS — MongoDB Manual Docs Home → MongoDB Manual MongoDB AtlasMongoDB Atlas is a hosted MongoDB service option in the cloud which requires no installation overhead and offers a free tier to get started.Use this tutorial to install MongoDB 7.0 Community Edition on macOS using www.mongodb.co..