{"id":21673864,"url":"https://github.com/datadudes/json2hive","last_synced_at":"2025-04-12T04:20:42.425Z","repository":{"id":62572792,"uuid":"109268656","full_name":"datadudes/json2hive","owner":"datadudes","description":"Generate Hive CREATE TABLE statements from json data","archived":false,"fork":false,"pushed_at":"2017-11-02T13:30:57.000Z","size":5,"stargazers_count":10,"open_issues_count":4,"forks_count":5,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-25T23:51:19.426Z","etag":null,"topics":["cli","hive","json"],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/datadudes.png","metadata":{"files":{"readme":"README.rst","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-11-02T13:30:40.000Z","updated_at":"2023-10-13T15:45:24.000Z","dependencies_parsed_at":"2022-11-03T18:30:21.365Z","dependency_job_id":null,"html_url":"https://github.com/datadudes/json2hive","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/datadudes%2Fjson2hive","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/datadudes%2Fjson2hive/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/datadudes%2Fjson2hive/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/datadudes%2Fjson2hive/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/datadudes","download_url":"https://codeload.github.com/datadudes/json2hive/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248019444,"owners_count":21034243,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cli","hive","json"],"created_at":"2024-11-25T13:41:48.510Z","updated_at":"2025-04-12T04:20:42.401Z","avatar_url":"https://github.com/datadudes.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"json2hive\n=========\n\njson2hive is a command line utility that can automatically generate CREATE TABLE statements for\nHive tables backed by JSON data.\n\nFeatures\n--------\n\n- Automatically infer schema of JSON data by analysing JSON records\n- Supports external and managed Hive tables\n- Can be used as command line utility or programmatically\n\nInstallation\n------------\n\nYou can install ``json2hive`` using pip:\n\n.. code-block:: bash\n\n    $ pip install json2hive\n\nIt is **strongly recommended** that you install ``json2hive`` inside a `virtual environment`_!\n\n.. _virtual environment: http://docs.python-guide.org/en/latest/dev/virtualenvs/\n\nUsage\n-----\n\n**On the Command Line**\n\nRun the following and follow the instructions:\n\n.. code-block:: bash\n\n    $ json2hive --help\n\n**As a library**\n\n.. code-block:: python\n\n    from json2hive.utils import infer_schema\n    from json2hive.generators import generate_json_table_statement\n\n    # infer schema from objects, these objects could be the result of json.loads(...)\n    object1 = {'name': 'John', age: 25}\n    object2 = {'name': 'Mary', age: 23}\n    schema = infer_schema([object1, object2])\n\n    # Generate CREATE TABLE statement\n    statement = generate_json_table_statement('example', schema, managed=True)\n    print(statement)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdatadudes%2Fjson2hive","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdatadudes%2Fjson2hive","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdatadudes%2Fjson2hive/lists"}