0 votes
1 view
in SQL by (53.7k points)

Can anyone explain how to retrieve data from two tables with one SQL statement?

1 Answer

0 votes
by (116k points)

We have to use joins to retrieve the data from two tables with one SQL statement. We join two tables on a particular condition and we can retrieve the data from multiple tables.

Suppose we have two tables TableA and TableB and here is the syntax to retrieve data from two tables:

SELECT TableA.column(s), TableB.column(s)
FROM TableA
INNER JOIN TableB ON TableA.Column_Name = TableB.Column_Name;

I suggest enrolling in this SQL training course by Intellipaat to learn SQL.

Related questions

0 votes
1 answer
0 votes
1 answer
0 votes
3 answers
0 votes
1 answer
asked Apr 29, 2020 in SQL by Sudhir_1997 (53.7k points)
Welcome to Intellipaat Community. Get your technical queries answered by top developers !


Categories

...