cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ravishankar Rajendran (JIRA)" <j...@apache.org>
Subject [jira] [Comment Edited] (CASSANDRA-11602) Materialized View Doest Not Have Static Columns
Date Tue, 19 Apr 2016 15:43:25 GMT

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

Ravishankar Rajendran edited comment on CASSANDRA-11602 at 4/19/16 3:43 PM:
----------------------------------------------------------------------------

[~slebresne]  Logically all tables in C* are materialized views .i.e. tables cannot have foreign
keys and are modeled based on queries. That is what is a View in RDBMS world. All that the
C* MVs do is; it automates denormalization. Essentially MVs in C* must be similar to tables
in all behaviors. MVs in C* must be nothing but tables that can automate denormalization.

MVs must solve for static columns. MVs with no support to static column will be very disappointing
for developers. Static columns are a boon for developers and performance engineers. Static
columns + MV is like a holy grail.

If I can manually denormalize data between two tables with static columns. I should be able
to do the same with a table + MV. We must add support for static columns in MV.


was (Author: ravishankar_rajendran@yahoo.com):
[~slebresne]  Logically all tables in C* are materialized views .i.e. tables cannot have foreign
keys and are modeled based on queries. That is what is a View in RDBMS world. All that the
C* MVs do is; it automates denormalization. Essentially MVs in C* must be similar to tables
in all behaviors. MVs in C* must be nothing but tables that can automate denormalization.

MVs must solve for static columns. MVs with no support to static column will be very disappointing
for developers. Static columns are a boon for developers and performance engineers. Static
columns + MV is like a holy grail.

We must add support for static columns in MV.

> Materialized View Doest Not Have Static Columns
> -----------------------------------------------
>
>                 Key: CASSANDRA-11602
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-11602
>             Project: Cassandra
>          Issue Type: Bug
>            Reporter: Ravishankar Rajendran
>            Assignee: Carl Yeksigian
>
> {quote}
> CREATE TABLE "team" (teamname text, manager text, location text static, PRIMARY KEY ((teamname),
manager));
> INSERT INTO team (teamname, manager, location) VALUES ('Red Bull1', 'Ricciardo11', 'Australian');
> INSERT INTO team (teamname, manager, location) VALUES ('Red Bull2', 'Ricciardo12', 'Australian');
> INSERT INTO team (teamname, manager, location) VALUES ('Red Bull2', 'Ricciardo13', 'Australian');
> select * From team;
> CREATE MATERIALIZED VIEW IF NOT EXISTS "teamMV" AS SELECT "teamname", "manager", "location"
FROM "team" WHERE "teamname" IS NOT NULL AND "manager" is NOT NULL AND "location" is NOT NULL
PRIMARY KEY("manager", "teamname");  
> select * from "teamMV";
> {quote}
> The teamMV does not have "location" column. Static columns are not getting created in
MV.



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

Mime
View raw message