Latest

MySQL : How to fix Can't connect to MySQL server on localhost 10061 error

When I installed MySQL server a few months ago on my Windows 10 machine, I chose to have the database files on my main SSD drive. As it was slowly filling up, I decided to migrate the MySQL database files to another drive. I assumed all I needed to do is to update a path for datadir option in my.ini configuration file, but that didn't work. After the database location move, starting the MySQL server gave me 10061 error "Can't connect to MySQL server" error. Luckily, the fix was quite simple.

Read More

.NET : How to save DataTable to Database Table using C#

Recently I wanted to save DataTable data into database. I assumed this would be easy using Entity Framework, but it turns out it is not, since DataTable consists of rows and columns while the Entity Framework deals with objects. Another way is to use ADO.NET by iterating through the rows in the DataTable and insert each row using SqlCommand and INSERT statement, but there is an easier way to accomplish this and that is by using SqlBulkCopy class, which is the focus of this article.

Read More

SQL : How to solve Northwind Database Install Error in SQL Server 2012

Recently I was going through a database programming tutorial that used Northwind Database in code examples, so I thought "No problem, I'll quickly add that database to my SQL Server 2012". I assumed this would be easy but to my surprise that wasn't the case.

In this post I will show you what problems I encountered while trying to install Northwind database and how I finally managed to make it work.

Read More

Share this page

Back to Top