James Taylor created PHOENIX-2698:
-------------------------------------

             Summary: Local index column family structure doesn't match PTable
                 Key: PHOENIX-2698
                 URL: https://issues.apache.org/jira/browse/PHOENIX-2698
             Project: Phoenix
          Issue Type: Bug
            Reporter: James Taylor
            Assignee: Rajeshbabu Chintaguntla


See FIXME here:
{code}
                // FIXME: we only enter this if the number of column families 
is 1 because otherwise
                // local indexes break because it appears that the column 
families in the PTable do
                // not match the actual column families of the table (which is 
bad).
                if (keyOnlyFilter && table.getColumnFamilies().size() == 1) {
                    // Project the one column family. We must project a column 
family since it's possible
                    // that there are other non declared column families that 
we need to ignore.
                    
scan.addFamily(table.getColumnFamilies().get(0).getName().getBytes());
                } else {
{code}
The following *should* work, but doesn't when a local index is used:
{code}
                if (keyOnlyFilter && table.getColumnFamilies().size() <= 1) {
                    // Project the one column family. We must project a column 
family since it's possible
                    // that there are other non declared column families that 
we need to ignore.
                    scan.addFamily(SchemaUtil.getEmptyColumnFamily(table));
                } else {
{code}
This can be tested by running the IndexIT test suite (you'll see failures when 
local indexes are used about a column family not being found).



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

Reply via email to