Repository Dapper Patterns is a C# project developed using .NET and MS SQL Server. It implements two well-known design patterns: Repository and Dapper. This project allows users to perform CRUD operations on Category and Product tables in the database, demonstrating the practical use of these patterns for database interaction in .NET applications.
This project was created as part of my homework assignment at IT Step Academy. It showcases how to use the Repository pattern alongside the Dapper ORM for efficient and maintainable data access in C# applications.
Note: This project requires an MS SQL Server database setup with Category and Product tables. You will need to update the connection string in the Program.cs
file to connect to your database instance.
Follow these steps to set up the project:
- Clone the repository:
git clone https://github.com/zabavb/Repository-Dapper-patterns.git
- Update the connection string in the
Program.cs
file with your MS SQL Server credentials. - Ensure that the Category and Product tables are created in your MS SQL Server database.
- Open the solution file in Visual Studio, build the project, and run the application.
- Repository Pattern: Abstract data access logic for maintainability and testability.
- Dapper ORM Integration: Use Dapper for efficient database interactions with minimal overhead.
- CRUD Operations: Perform Create, Read, Update, and Delete operations on Category and Product tables.
To use this application, ensure you have an MS SQL Server instance running and the necessary tables created. Configure the connection string in the configuration file and use the application to interact with your database using the implemented repository and Dapper patterns.
Contributions are welcome! If you have any suggestions or improvements, feel free to fork the repository and submit a pull request.
- Fork the Repository: Click the "Fork" button at the top-right of this page.
- Create a Branch: Create a new branch for your changes.
- Commit Changes: Make your changes and commit them with a descriptive message.
- Push to Your Fork: Push your changes to your forked repository.
- Submit a Pull Request: Go to the "Pull Requests" tab and submit a new pull request.
If you have any questions or inquiries, feel free to reach out to me at email or connect with me on LinkedIn.
- Thanks to IT Step Academy for providing the resources and guidance for this project.
- Special thanks to Microsoft for their comprehensive documentation and tools.
Feel free to modify or extend this README to fit your needs better. Happy coding!