Skip to main content

Simple framework for aiomysql

Project description

aiomysql-core

Simple framework for aiomysql

introduce

simple package, easy to use

aiomysql

Installation

pip install aiomysql-core

Simple uses

import asyncio
import aiomysql
from aiomysql_core import AioMysqlCore


async def test_example(loop):
    pool = await aiomysql.create_pool(host='', port=3308,
                                      user='', password='',
                                      db='', loop=loop)
    core = AioMysqlCore(pool=pool)
    rows = await core.query('select * from users where uid=%s', 113)
    print(rows)
    row = await core.get('select * from users where uid=%(uid)s', {'uid': 113})
    print(row)
    rowcount = await core.execute_rowcount('select * from users where uid=%(uid)s', {'uid': 113})
    print(rowcount)
    pool.close()
    await pool.wait_closed()


loop = asyncio.get_event_loop()
loop.run_until_complete(test_example(loop))

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

aiomysql-core-0.0.2.tar.gz (2.7 kB view details)

Uploaded Source

Built Distribution

aiomysql_core-0.0.2-py2.py3-none-any.whl (3.8 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file aiomysql-core-0.0.2.tar.gz.

File metadata

  • Download URL: aiomysql-core-0.0.2.tar.gz
  • Upload date:
  • Size: 2.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.14.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.35.0 CPython/3.6.8

File hashes

Hashes for aiomysql-core-0.0.2.tar.gz
Algorithm Hash digest
SHA256 7e1bc8b1e2d6d4ba974b8ffa440c865b052fa226bdcde82e36df0d4e0d25b219
MD5 efddb7933baae30316650f17bc93f493
BLAKE2b-256 17901d1df9685cf49f60d276cffa77ce986645ff5a4cbf36949f640c22bb159f

See more details on using hashes here.

File details

Details for the file aiomysql_core-0.0.2-py2.py3-none-any.whl.

File metadata

  • Download URL: aiomysql_core-0.0.2-py2.py3-none-any.whl
  • Upload date:
  • Size: 3.8 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.14.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.35.0 CPython/3.6.8

File hashes

Hashes for aiomysql_core-0.0.2-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 380d4c4a137b76c000cf669d4c7b14c8c3d329fa91872d9e9990d3e89775789a
MD5 b4f611c88dc2812040efc4fa292937fb
BLAKE2b-256 69bbad32200cdda2191a470e7596adab8049388d9fcaf5083468cd58ba58c839

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page