MySQL how to insert a row into a table

Inserting data into MySQL tables is easy, but I tend to forget little details once in a while. I was having the best espresso coffee and trying to remember this one. Below is how you insert a new row into a MySQL table. Assume you created the following table: And then you want to insert …

Connect to a remote MySQL database using Linux terminal

This is simple. After you setup a user with proper access rights run the below commands. # mysql -u yourUser -p -h <yourHostname or IP> A little explanation: -u tells mysql what your username -p tells mysql you have a password and will prompt you to enter it after you press enter -h tells mysql …

Difference between Inner Join and Outer Join in SQL

An inner join it is the most common kind of join, so common that SQL doesn’t actually make us say “inner join” to do one. An outer join returns a set of records or rows that include what an inner join would return, but also includes other rows for which no corresponding match is found in the …