NodeJS connection to MySQL with ORM

preview_player
Показать описание
Connect Node JS with MySQL #mysql #nodejs #coding #nodejsdevelopment #begginers

1. Create one Database and Create some tables into that (I will use my previous structure here)
2. Database is ready , i need to open previously created node js in VS Code.
4. All MySQL Configuration are noted in localDB object in Module exports
5. Need to install mysql2 dependency into project.
6. Creates folder structure for projects like - lib, routes, orm, services, views
8. create one folder for models also orm/models and other for DAO's orm/daos.
9. Create model for user_mst table to access data from it.
10. install Sequelize, file-system, body-parser and cors dependency into project.
11. then maintained all table field into model of node js.
12. Model is created for user_mst. let's update table associations.
13. Table Associations also done. need to create one class in routes, services and daos,
create one route for getAllUser in Route link method from services to dao.
15. Run the project by passing local param.
16 So, We are connected to database of MySQL then check api getAllUser
17. Data will getting in Postman.

@CodeWithHarry @LearningPartnerDigital @sahosoftsolutions2343
--------------
Thank you
Рекомендации по теме