SQL Exceptions for One-Column Partitioning on Column 2

Invalid example queries for one-column partitioning on column 2 (c2). Each example raises a SQL exception.

Example 1

SELECT * FROM my_tpf( 
  TABLE( SELECT T.x, T.y FROM T )
  OVER( PARTITION BY T.x )

In this example, the UDF describes to the server that the data is partitioned by the first column (T.y) ,and that the SQL writer is also explicitly requesting partitioning on a different column (T.x), which conflicts with what the UDF is requesting. As a result the server returns a SQL error.

Example 2

SELECT * FROM my_tpf( 
  TABLE( SELECT T.x, T.y FROM T )
  OVER( NO PARTITION BY )

This example conflicts with the request made by the UDF because the SQL writer does not want the input table partitioned. As a result the server returns a SQL error.

Example 3

SELECT * FROM my_tpf( 
  TABLE( SELECT T.x, T.y FROM T )
  OVER( PARTITION BY T.x, T.y )

In this example, the UDF describes to the server that the data is partitioned by the first column (T.y), and the SQL writer requests partitioning on columns (T.x and T.y), which conflicts with what the UDF is requesting. As a result the server returns a SQL error.