yanxinyi commented on a change in pull request #742: Phoenix-5797 RVC Offset 
does not work with tenant views on global indexes
URL: https://github.com/apache/phoenix/pull/742#discussion_r397544348
 
 

 ##########
 File path: 
phoenix-core/src/it/java/org/apache/phoenix/end2end/RowValueConstructorOffsetIT.java
 ##########
 @@ -940,4 +941,70 @@ public void testOffsetExplain() throws SQLException {
             assertTrue(explainStringBuilder.toString().contains("With RVC 
Offset"));
         }
     }
+
+    @Test public void testGlobalIndexViewAccess() throws Exception {
+        String
+                ddl =
+                "CREATE TABLE IF NOT EXISTS ARCHIVE.FIELD_HISTORY_ARCHIVE (\n"
+                        + "    ORGANIZATION_ID CHAR(15) NOT NULL,\n"
+                        + "    PARENT_KEY_PREFIX CHAR(3) NOT NULL,\n"
+                        + "    PARENT_ID CHAR(15) NOT NULL,\n" + "    
CREATED_DATE DATE NOT NULL,\n"
+                        + "    DATA VARCHAR   \n" + "    CONSTRAINT PK PRIMARY 
KEY \n" + "    (\n"
+                        + "        ORGANIZATION_ID, \n" + "        
PARENT_KEY_PREFIX,\n"
+                        + "        PARENT_ID,\n" + "        CREATED_DATE\n" + 
"    )\n"
+                        + ") MULTI_TENANT=true";
+
+        //Index reorders the pk only
+        String
+                indexSyncDDL =
+                "CREATE INDEX IF NOT EXISTS FIELD_HISTORY_ARCHIVE_INDEX\n"
+                        + "ON ARCHIVE.FIELD_HISTORY_ARCHIVE 
(PARENT_KEY_PREFIX, CREATED_DATE, PARENT_ID)\n"
+                        + "INCLUDE (DATA)";
+
+        String
+                viewDDL =
 
 Review comment:
   nit: weird line break

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to