convert json to relational db
Project description
Json2DB
Python3.6+
Just need defined a json object, then you can save it in to a relational DB like MySQL PostgreSQL or other DB.
Reason To Write This FrameWork
Example
from json2db import JFactory
d = {"aa": 1, "bb": 2, "brother": {"name": "jack", "namess": [{"other": "jack"}]}, 'sons': [{"son_name": "aa"}]}
factory = JFactory()
model = factory.from_json(data=d, root_name="data")
model.create_tables_in_db()
model.store(data=d)
model.search(search_args=[("aa", 1)], limit=2)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
json2db-1.0.0.tar.gz
(8.2 kB
view hashes)
Built Distribution
Close
Hashes for json2db-1.0.0-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6a594e0770d7d62fb7a7147ebe9e0d6e4a8ed50238458dd6219d2ae1c380709f |
|
MD5 | ef962e706c4c781c8bb51a5fe8ed3090 |
|
BLAKE2b-256 | 43b827b779e704443081e7f59133bd01033ad23e3b0f67bf0571d2b11b8f53de |