You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@beam.apache.org by "Beam JIRA Bot (Jira)" <ji...@apache.org> on 2020/08/02 17:07:02 UTC

[jira] [Commented] (BEAM-8741) Queries that attempt to write to pubsub publish time should fail at construction time

    [ https://issues.apache.org/jira/browse/BEAM-8741?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17169583#comment-17169583 ] 

Beam JIRA Bot commented on BEAM-8741:
-------------------------------------

This issue is P2 but has been unassigned without any comment for 60 days so it has been labeled "stale-P2". If this issue is still affecting you, we care! Please comment and remove the label. Otherwise, in 14 days the issue will be moved to P3.

Please see https://beam.apache.org/contribute/jira-priorities/ for a detailed explanation of what these priorities mean.


> Queries that attempt to write to pubsub publish time should fail at construction time
> -------------------------------------------------------------------------------------
>
>                 Key: BEAM-8741
>                 URL: https://issues.apache.org/jira/browse/BEAM-8741
>             Project: Beam
>          Issue Type: Improvement
>          Components: dsl-sql
>            Reporter: Brian Hulette
>            Priority: P2
>              Labels: stale-P2
>
> Currently it's possible to perform a query like:
> {code:sql}
> CREATE TABLE pubsub (
>   event_timestamp TIMESTAMP,
>   id VARCHAR
> ) ...
> INSERT INTO pubsub (event_timestamp, id) VALUES (...)
> {code}
> But when this is executed, the event_timestamp will be dropped, because on read it will be instead be populated with pubsub's publish time.
> A couple of ideas:
> - We could indicate that this is a VIRTUAL GENERATED column, and is therefore read-only. Calcite seems to have some support for this concept, see [ColumnStrategy.java|https://github.com/apache/calcite/blob/master/core/src/main/java/org/apache/calcite/schema/ColumnStrategy.java].
> - We could just throw an exception in the Pubsub JSON Table Provider if the query's output schema contains event_timestamp.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)