Return-Path: X-Original-To: apmail-cassandra-commits-archive@www.apache.org Delivered-To: apmail-cassandra-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 5FFB21806A for ; Thu, 17 Sep 2015 23:08:05 +0000 (UTC) Received: (qmail 92492 invoked by uid 500); 17 Sep 2015 23:08:05 -0000 Delivered-To: apmail-cassandra-commits-archive@cassandra.apache.org Received: (qmail 92445 invoked by uid 500); 17 Sep 2015 23:08:05 -0000 Mailing-List: contact commits-help@cassandra.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cassandra.apache.org Delivered-To: mailing list commits@cassandra.apache.org Received: (qmail 92427 invoked by uid 99); 17 Sep 2015 23:08:05 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 17 Sep 2015 23:08:05 +0000 Date: Thu, 17 Sep 2015 23:08:05 +0000 (UTC) From: "Andy Tolbert (JIRA)" To: commits@cassandra.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (CASSANDRA-9664) Allow MV's select statements to be more complex MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/CASSANDRA-9664?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14804684#comment-14804684 ] Andy Tolbert commented on CASSANDRA-9664: ----------------------------------------- Is it required for a where clause to be present now? I've been experimenting on this branch w/ the java-driver and noticed that I now get an NPE when not providing a where clause: {noformat}ERROR [SharedPool-Worker-1] 2015-09-17 17:50:02,862 ErrorMessage.java:336 - Unexpected exception during request java.lang.NullPointerException: null at org.apache.cassandra.db.view.View.relationsToWhereClause(View.java:719) ~[main/:na] at org.apache.cassandra.cql3.statements.CreateViewStatement.announceMigration(CreateViewStatement.java:224) ~[main/:na] at org.apache.cassandra.cql3.statements.SchemaAlteringStatement.execute(SchemaAlteringStatement.java:93) ~[main/:na] at org.apache.cassandra.cql3.QueryProcessor.processStatement(QueryProcessor.java:204) ~[main/:na] at org.apache.cassandra.cql3.QueryProcessor.process(QueryProcessor.java:235) ~[main/:na] at org.apache.cassandra.cql3.QueryProcessor.process(QueryProcessor.java:220) ~[main/:na] at org.apache.cassandra.cql3.CustomPayloadMirroringQueryHandler.process(CustomPayloadMirroringQueryHandler.java:43) ~[main/:na] at org.apache.cassandra.transport.messages.QueryMessage.execute(QueryMessage.java:115) ~[main/:na] at org.apache.cassandra.transport.Message$Dispatcher.channelRead0(Message.java:507) [main/:na] at org.apache.cassandra.transport.Message$Dispatcher.channelRead0(Message.java:401) [main/:na] at io.netty.channel.SimpleChannelInboundHandler.channelRead(SimpleChannelInboundHandler.java:105) [netty-all-4.0.23.Final.jar:4.0.23.Final] at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:333) [netty-all-4.0.23.Final.jar:4.0.23.Final] at io.netty.channel.AbstractChannelHandlerContext.access$700(AbstractChannelHandlerContext.java:32) [netty-all-4.0.23.Final.jar:4.0.23.Final] at io.netty.channel.AbstractChannelHandlerContext$8.run(AbstractChannelHandlerContext.java:324) [netty-all-4.0.23.Final.jar:4.0.23.Final] at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [na:1.8.0_25] at org.apache.cassandra.concurrent.AbstractTracingAwareExecutorService$FutureTask.run(AbstractTracingAwareExecutorService.java:164) [main/:na] at org.apache.cassandra.concurrent.SEPWorker.run(SEPWorker.java:105) [main/:na] at java.lang.Thread.run(Thread.java:745) [na:1.8.0_25] {noformat} Where on trunk C* surfaces an InvalidQueryException (as each primary key column I declare must include a 'IS NOT NULL' in my where clause). I'm also wondering why the 'IS NOT NULL' declaration for primary keys is required (couldn't that be implicit?) although thats not new on this branch and there might have been previous conversations about that (I'll look through tickets and strikethrough and link to that if I find it). > Allow MV's select statements to be more complex > ----------------------------------------------- > > Key: CASSANDRA-9664 > URL: https://issues.apache.org/jira/browse/CASSANDRA-9664 > Project: Cassandra > Issue Type: New Feature > Reporter: Carl Yeksigian > Assignee: Tyler Hobbs > Labels: client-impacting, doc-impacting > Fix For: 3.0.0 rc1 > > > [Materialized Views|https://issues.apache.org/jira/browse/CASSANDRA-6477] add support for a syntax which includes a {{SELECT}} statement, but only allows selection of direct columns, and does not allow any filtering to take place. > We should add support to the MV {{SELECT}} statement to bring better parity with the normal CQL {{SELECT}} statement, specifically simple functions in the selected columns, as well as specifying a {{WHERE}} clause. -- This message was sent by Atlassian JIRA (v6.3.4#6332)