1/*
2Every derived table (AKA sub-query) must indeed have an alias.
3I.e. each query in brackets must be given an alias (AS whatever)
4,which can the be used to refer to it in the rest of the outer query.
5*/
6
7SELECT ID FROM (
8 SELECT ID, msisdn FROM (
9 SELECT * FROM TT2
10 ) AS T
11) AS T
12
13
14
15