跳转到主要内容

编写SQL like程序并将其翻译成Python、SQL、Hive、PIG的意图。

项目描述


.. _l-README

README
======

.. only:: html

.. image:: https://travis-ci.org/sdpython/pysqllike.svg?branch=master
:target: https://travis-ci.org/sdpython/pysqllike
:alt: 构建状态

.. image:: https://ci.appveyor.com/api/projects/status/rrpks1pgivea23js?svg=true
:target: https://ci.appveyor.com/project/sdpython/pysqllike
:alt: Windows构建状态

.. image:: https://circleci.com/gh/sdpython/pysqllike/tree/master.svg?style=svg
:target: https://circleci.com/gh/sdpython/pysqllike/tree/master

.. image:: https://badge.fury.io/py/pysqllike.svg
:target: http://badge.fury.io/py/pysqllike

.. image:: http://img.shields.io/github/issues/sdpython/pysqllike.png
:alt: GitHub问题
:target: https://github.com/sdpython/pysqllike/issues

.. image:: https://img.shields.io/badge/license-MIT-blue.svg
:alt: MIT许可证
:target: https://open-source.org.cn/licenses/MIT

.. image:: https://landscape.io/github/sdpython/pysqllike/master/landscape.svg?style=flat
:target: https://landscape.io/github/sdpython/pysqllike/master
:alt: 代码健康

.. image:: https://requires.io/github/sdpython/pysqllike/requirements.svg?branch=master
:target: https://requires.io/github/sdpython/pysqllike/requirements/?branch=master
:alt: 要求状态

.. image:: https://codecov.io/github/sdpython/pysqllike/coverage.svg?branch=master
:target: https://codecov.io/github/sdpython/pysqllike?branch=master

**链接:**

* `GitHub/pysqllike <https://github.com/sdpython/pysqllike>`_
* `文档 <http://www.xavierdupre.fr/app/pysqllike/helpsphinx/index.html>`_
* `博客 <http://www.xavierdupre.fr/app/pysqllike/helpsphinx/blog/main_0000.html#ap-main-0>`_

描述
-----------

编写map/reduce作业
(例如使用`PIG <https://pig.apache.org/>`_)
通常需要从本地文件切换到远程文件
(在`Hadoop <https://hadoop.apache.ac.cn/>`_上)
一种方法是提取将要由map/reduce作业处理的小部分数据
作业随后在本地开发。当它工作后,
它在并行环境中运行。

此扩展的目标是允许使用以下Python语法实现此工作
如下所示

::

def myjob(input)
iter = input.select (input.age, input.nom, age2 = input.age2*input.age2)
wher = iter.where( (iter.age > 60).Or(iter.age < 25))
return where

input = IterRow (None, [ {"nom": 10}, {"jean": 40} ] )
output = myjob(input)

当作业准备好时,它可以翻译成`PIG <https://pig.apache.org>`_
作业:

input = LOAD '...' USING PigStorage('\t') AS (nom, age);
iter = FOREACH input GENERATE age, nom, age*age AS age2 ;
wher = FILTER iter BY age > 60 or age < 25 ;
STORE wher INTO '...' USING PigStorage();

它还应翻译成
`SQL <http://fr.wikipedia.org/wiki/Structured_Query_Language>`_。

功能
---------------

* 尚未准备就绪

设计
------

此项目包含有关日志记录函数、单元测试和帮助生成的各种辅助功能。
* 源文件夹:``src``
* 单元测试文件夹:``_unittests``,进入此文件夹并运行 ``run_unittests.py``
* `_doc` 文件夹:``_doc``,它将包含文档
* 文件 ``setup.py`` 用于构建和安装模块
* 文件 ``make_help.py`` 用于构建Sphinx文档

项目详情


下载文件

下载适合您平台的文件。如果您不确定选择哪个,请了解更多关于 安装包 的信息。

源分布

pysqllike-0.1.168.tar.gz (34.3 kB 查看哈希值)

上传时间

构建分布

pysqllike-0.1.168-py3-none-any.whl (24.1 kB 查看哈希值)

上传时间 Python 3

支持者:

AWS AWS 云计算和安全赞助商 Datadog Datadog 监控 Fastly Fastly CDN Google Google 下载分析 Microsoft Microsoft PSF 赞助商 Pingdom Pingdom 监控 Sentry Sentry 错误记录 StatusPage StatusPage 状态页面