MySQL

MySQL Insert Into Inner Join1 min read

When adding records in SQL language, you sometimes need to get records from different tables. In such cases, INSERT and SELECT statements must be used together.
In this article you will see the use of INSERT and SELECT statements together.
You’ll also find examples of the article’s title “Insert Into Inner Join”.

I used the following database for the following queries.

SQL Example: Write the query that adds student number 5 as a writer to the author table




SQL Example: Write the query that adds the author table as the author of the 10 oldest students in the student table. (INSERT INTO, SELECT)

SQL Example: This query is not very meaningful, but it was created to use INSERT, SELECT, and JOIN concepts together. In the example, book name, author name and author surname are added to the author table as the book name.

I hope the examples have been positive for your application.

Leave a Comment