[
https://issues.apache.org/jira/browse/FLINK-19825?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Yanzhao Deng updated FLINK-19825:
---------------------------------
Attachment: (was: issue.txt)
> scala package class case class on flink sql
> -------------------------------------------
>
> Key: FLINK-19825
> URL: https://issues.apache.org/jira/browse/FLINK-19825
> Project: Flink
> Issue Type: Bug
> Components: API / Scala
> Affects Versions: 1.11.1
> Environment: flink version: 1.11.1
> scala version: 2.12
> Reporter: Yanzhao Deng
> Priority: Major
> Labels: flinksql
> Attachments: NewApiTest.scala, error.txt, package.scala
>
> Original Estimate: 336h
> Remaining Estimate: 336h
>
> When I use Flink SQL scala API, I found a bug. I have a sensor.txt, the txt
> file has some sensor data.One row of data is as follows:
> {code:java}
> sensor_1,1547718199,35.8
> {code}
> And I have a `package object MyTest` class. This class has a case class
> `SensorReading`.
> {code:java}
> package object MyTest {
> case class SensorReading(id: String, timestamp: Long, temperature: Double)
> }
> {code}
> When I use Flink SQL API, I think he should output the correct result, but he
> reported an error.
> {code:java}
> tEnv.createTemporaryView("ds", dataStream)
> val result: Table = tEnv.sqlQuery("SELECT * FROM ds where `temperature` >= 5")
> result.toAppendStream[SensorReading].print("test"){code}
> I will send you the error as a file later. And I found Inner class and scala
> General class not send this error.
> If you have any findings, please contact me.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)