You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@hawq.apache.org by jiadexin <gi...@git.apache.org> on 2016/06/08 01:12:47 UTC
[GitHub] incubator-hawq pull request #695: support more pxf filter pushdwon
GitHub user jiadexin opened a pull request:
https://github.com/apache/incubator-hawq/pull/695
support more pxf filter pushdwon
https://issues.apache.org/jira/browse/HAWQ-779
Description
When I use the pxf hawq, I need to read a traditional relational database systems and solr by way of the external table. The project :https://github.com/Pivotal-Field-Engineering/pxf-field/tree/master/jdbc-pxf-ext, only "WriteAccessor ",so I developed 2 plug-ins, the projects: https://github.com/inspur-insight/pxf-plugin , But these two plug-ins need to modified HAWQ:
1. When get a list of fragment from pxf services, push down the 'filterString'. modify the backend / optimizer / plan / createplan.c of create_pxf_plan methods:
segdb_work_map = map_hddata_2gp_segments (uri_str,
total_segs, segs_participating,
relation, ctx-> root-> parse-> jointree-> quals);
2. modify pxffilters.h and pxffilters.c, support TEXT types LIKE operation, Date type data operator, Float type operator.
3. Modify org.apache.hawq.pxf.api.FilterParser.java, support the LIKE operator.
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/inspur-insight/incubator-hawq feature-pxf
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/incubator-hawq/pull/695.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #695
----
commit fb00bd27021fbabc98c1c940ebb890e974496500
Author: root <root@hmaster.(none)>
Date: 2016-06-07T01:16:06Z
HAWQ-779 Support more pxf filter pushdwon
commit caa20039e73589112c48c20a3f78c4a8f7b1f2d6
Author: Devin Jia <ji...@inspur.com>
Date: 2016-06-08T01:04:08Z
HAWQ-779 support more pxf filter pushdwon
----
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---
[GitHub] incubator-hawq issue #695: HAWQ-779. support more pxf filter pushdwon
Posted by shivzone <gi...@git.apache.org>.
Github user shivzone commented on the issue:
https://github.com/apache/incubator-hawq/pull/695
Merged this feature to master. Closing this pulll request
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---
[GitHub] incubator-hawq pull request #695: support more pxf filter pushdwon
Posted by shivzone <gi...@git.apache.org>.
Github user shivzone commented on a diff in the pull request:
https://github.com/apache/incubator-hawq/pull/695#discussion_r66495061
--- Diff: src/backend/access/external/pxffilters.c ---
@@ -125,7 +126,48 @@ dbop_pxfop_map pxf_supported_opr[] =
{1871 /* int82gt */, PXFOP_GT},
{1872 /* int82le */, PXFOP_LE},
{1873 /* int82ge */, PXFOP_GE},
- {1869 /* int82ne */, PXFOP_NE}
+ {1869 /* int82ne */, PXFOP_NE},
+
+ /**************FLOAT****************/
+ /* float4 */
+ {Float4EqualOperator /* float4eq */, PXFOP_EQ},
+ {622 /* float4lt */, PXFOP_LT},
+ {623 /* float4gt */, PXFOP_GT},
+ {624 /* float4le */, PXFOP_LE},
+ {625 /* float4ge */, PXFOP_GE},
+ {621 /* float4ne */, PXFOP_NE},
+
+ /* float8 */
+ {Float8EqualOperator /* float8eq */, PXFOP_EQ},
+ {672 /* float8lt */, PXFOP_LT},
+ {674 /* float8gt */, PXFOP_GT},
+ {673 /* float8le */, PXFOP_LE},
+ {675 /* float8ge */, PXFOP_GE},
+ {671 /* float8ne */, PXFOP_NE},
+
+ /* float48 */
--- End diff --
This pull request doesn't quite seem related to supporting operators on Float. What is the purpose of this ?
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---
[GitHub] incubator-hawq pull request #695: HAWQ-779. support more pxf filter pushdwon
Posted by jiadexin <gi...@git.apache.org>.
Github user jiadexin closed the pull request at:
https://github.com/apache/incubator-hawq/pull/695
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---
[GitHub] incubator-hawq issue #695: support more pxf filter pushdwon
Posted by jiadexin <gi...@git.apache.org>.
Github user jiadexin commented on the issue:
https://github.com/apache/incubator-hawq/pull/695
My local branch some confusion, handle submodules marked for deletion, I do not know how to recover. I first created PR in GITHUB, not familiar with.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---
[GitHub] incubator-hawq issue #695: HAWQ-779. support more pxf filter pushdwon
Posted by shivzone <gi...@git.apache.org>.
Github user shivzone commented on the issue:
https://github.com/apache/incubator-hawq/pull/695
+1
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---
[GitHub] incubator-hawq issue #695: support more pxf filter pushdwon
Posted by shivzone <gi...@git.apache.org>.
Github user shivzone commented on the issue:
https://github.com/apache/incubator-hawq/pull/695
Please update the corresponding test in FilterParserTest to include the new operators
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---
[GitHub] incubator-hawq pull request #695: support more pxf filter pushdwon
Posted by jiadexin <gi...@git.apache.org>.
Github user jiadexin commented on a diff in the pull request:
https://github.com/apache/incubator-hawq/pull/695#discussion_r66714047
--- Diff: src/backend/access/external/pxffilters.c ---
@@ -125,7 +126,48 @@ dbop_pxfop_map pxf_supported_opr[] =
{1871 /* int82gt */, PXFOP_GT},
{1872 /* int82le */, PXFOP_LE},
{1873 /* int82ge */, PXFOP_GE},
- {1869 /* int82ne */, PXFOP_NE}
+ {1869 /* int82ne */, PXFOP_NE},
+
+ /**************FLOAT****************/
+ /* float4 */
+ {Float4EqualOperator /* float4eq */, PXFOP_EQ},
+ {622 /* float4lt */, PXFOP_LT},
+ {623 /* float4gt */, PXFOP_GT},
+ {624 /* float4le */, PXFOP_LE},
+ {625 /* float4ge */, PXFOP_GE},
+ {621 /* float4ne */, PXFOP_NE},
+
+ /* float8 */
+ {Float8EqualOperator /* float8eq */, PXFOP_EQ},
+ {672 /* float8lt */, PXFOP_LT},
+ {674 /* float8gt */, PXFOP_GT},
+ {673 /* float8le */, PXFOP_LE},
+ {675 /* float8ge */, PXFOP_GE},
+ {671 /* float8ne */, PXFOP_NE},
+
+ /* float48 */
--- End diff --
When using HAWQ PXF read relational database, FLOAT is a very common type, and often used in conditional expressions. So I added FLOAT operators .
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---