-1014: Too many source tables

Explanation:

The number of underlying tables of the FROM clause of the SQL statement exceeds 16. If a join view table was specified in the FROM clause, the number of base tables underlying the join view table is considered for the calculation.

User Action:

You can split the SQL statement into two successive SQL statements.

It is also possible to bypass this restriction by using a QUERY expression in the FROM clause.