In this project, I explored different ways to work with databases in a Node.js app
- Raw MongoDB: Dived into the basics with the MongoDB driver — inserting, querying, and aggregating data manually to understand how it works
- Mongoose: Created schemas and models with handy methods like
addToCart,removeFromCart, andcreateOrder. Usedpopulateto link related data andtimestampsto track when things were created or updated - Shopping Cart & Orders: Built a cart system and order management, experimenting with relationships between
User,Product, andOrdercollections
- Sequelize & Aiven: Played around with SQL databases using Sequelize and hosted them on Aiven. Learned how relational databases differ from MongoDB
Overall, this project was about learning different ways to structure, relate, and manage data, and seeing how NoSQL and SQL compare in real projects
For the frontend, I used EJS instead of React since it:
- Simplifies handling sessions and dynamic views
- Easy to integrate for smaller projects
This setup allowed me to focus on backend logic and database operations.