The use of a correlated nested subqueries

0 like 0 dislike
9 views
There was a question in sql
Are the following:

there are three tables

first, let's say, with fields "person-titles-city (code)", the second "city (code)-city(transcript)-country (code)", the third "country (code)-country (transcript) — the continent."

At the entrance are the variable that defines the person. How to query in database to get all the information from three tables related to person, i.e. "title-town (transcript)-the country (transcript)-the continent"

A particularly interesting option with the use of a correlated nested subqueries.
by | 9 views

4 Answers

0 like 0 dislike
Also surprised why interested in is the correlated subqueries? I think in this case it is not appropriate, or?
Just in case inner join:
\r
select person.Description, city.cityName, state.Name from person
\r inner join city on city.cityId = person.cityId
\r inner join state on state.stateId = city.stateId
\r
\rwhere a preson.id = @personId
by
0 like 0 dislike
A very simple question. Try to solve puzzles on sql-ex.ru/ for a set of experiences :)
by
0 like 0 dislike
And that's not qualify?
by
0 like 0 dislike
Sent the solution to my Twitter, which I use:
\r
SELECT 1.title, 2.city, 3.country, 3.continent FROM 1, 2, 3 WHERE 1.person = "Spock" AND 1.chord = 2.Khorog AND 2.Strana = 3.Strana
by

Related questions

0 like 0 dislike
2 answers
0 like 0 dislike
1 answer
0 like 0 dislike
1 answer
asked May 20, 2019 by Dvoeglazov
0 like 0 dislike
2 answers
110,608 questions
257,186 answers
0 comments
28,803 users