[
https://issues.apache.org/jira/browse/PHOENIX-11?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13917344#comment-13917344
]
James Taylor commented on PHOENIX-11:
-------------------------------------
I think one approach that might work is to drive this off of the QueryPlan. You
can get a QueryPlan from any SQL query by doing the following:
Statement stmt = conn.createStatement();
PhoenixStatement pstmt = stmt.unwrap(PhoenixStatement.class);
QueryPlan plan = pstmt.compilePlan("SELECT * FROM FOO");
Then from the plan you can get a break down of all the steps that will get
executed. You can also get the split points.
// Nested iterators where each one is a step in the process of executing a
query
ResultIterator iterator = plan.newIterator();
// Splits that will be used (taking into account where clause, etc)
List<KeyRange> splits = plan.getSplits();
We could potentially add what you need to divide up the work between. Might be
a good way to go.
> Create Pig Loader
> -----------------
>
> Key: PHOENIX-11
> URL: https://issues.apache.org/jira/browse/PHOENIX-11
> Project: Phoenix
> Issue Type: Bug
> Reporter: James Taylor
> Assignee: maghamravikiran
>
> A Pig Storage function exists, so we can store to phoenix tables. What is
> needed is a Loader to go with the Storer.
--
This message was sent by Atlassian JIRA
(v6.1.5#6160)