flink-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Fabian Hueske (JIRA)" <j...@apache.org>
Subject [jira] [Created] (FLINK-4077) Register Pojo DataSet/DataStream as Table requires alias expression.
Date Wed, 15 Jun 2016 15:06:09 GMT
Fabian Hueske created FLINK-4077:
------------------------------------

             Summary: Register Pojo DataSet/DataStream as Table requires alias expression.
                 Key: FLINK-4077
                 URL: https://issues.apache.org/jira/browse/FLINK-4077
             Project: Flink
          Issue Type: Bug
          Components: Table API
    Affects Versions: 1.1.0
            Reporter: Fabian Hueske
            Assignee: Fabian Hueske
             Fix For: 1.1.0


Registering a Pojo DataSet / DataStream as Table requires alias expressions and does not work
with simple field references. However, alias expressions would only be necessary if the fields
of the Pojo should be renamed. 

{code}
DataStream<Person> persons = ...

// DOES NOT WORK
tEnv.registerDataStream(
  "Persons", 
  persons, 
  "name, age, address");

// DOES WORK
tEnv.registerDataStream(
  "Persons", 
  persons, 
  "name AS name, age AS age, address AS address");
{code}

We should also allow simple field name references in addition to alias expressions to rename
fields.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message