Given the following Core Data Service View Entity Data Definition:
1 @AccessControl.authorizationCheck: #NOT_REQUIRED
2 DEFINE VIEW ENTITY demo_flight_info_join
3 AS SELECT
4 FROM scarr AS a
5 LEFT OUTER JOIN scounter AS c
6 LEFT OUTER JOIN sairport AS p
7 ON p.id = c.airport
8 ON a.carrid = c.carrid
9 {
10 a.carrid AS carrier_id,
11 p.id AS airport_id,
12 c.countnum AS counter_number
13 }
In what order will the join statements be executed?
The order in which the join statements will be executed is:
scarr will be joined with scounter first and the result will be joined with sairport.
Therefore, the join statements will be executed as follows:
First, scarr AS a will be joined with scounter AS c using the join condition a.carrid = c.carrid. This means that all the rows from scarr will be included in the result, and only the rows from scounter that have the same value for the carrid field will be included. If there is no matching row from scounter, the countnum field will be filled with an initial value.
Second, the result of the first join will be joined with sairport AS p using the join condition p.id = c.airport. This means that all the rows from the first join will be included in the result, and only the rows from sairport that have the same value for the id field as the airport field from the first join will be included. If there is no matching row from sairport, the id field will be filled with an initial value.
Ronnie
4 months agoRegenia
5 months agoJennifer
5 months agoDerrick
5 months agoNell
4 months agoDierdre
4 months agoKarrie
4 months agoErasmo
4 months agoCandida
4 months agoEmilio
5 months agoHershel
5 months agoBurma
5 months agoElmer
5 months agoBulah
5 months agoSheldon
5 months agoJesusita
6 months agoLetha
6 months agoMirta
6 months agoSheldon
6 months ago