Skip to main content

Mysql connector skeleton for the x protocol

Project description

MySQL X connector for python

This repo contains a skeleton for mysqlx connector. User has to just create a specific table class which inherits provided table class. Users own table class can contain any kinds of methods to manipulate the table.

This connector uses environment variables to connect to the database. You need to set HOST, PORT, USER, and PASSWORD variables in the environment. By default MySQL uses port 33060 for the X protocol.

Examples

Simple table example:

from mysqlx_connector import Table

class CityTable(Table):

	def get_cities(self):
		return super().parse_results(self._table.select().execute())

Usage of the created table:

city_table = CityTable('cities', 'exampleDatabase')

with city_table as table:
	for row in table.get_cities():
		print(row)

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

mysqlx_connector-0.0.4.tar.gz (2.6 kB view details)

Uploaded Source

Built Distribution

mysqlx_connector-0.0.4-py3-none-any.whl (15.6 kB view details)

Uploaded Python 3

File details

Details for the file mysqlx_connector-0.0.4.tar.gz.

File metadata

  • Download URL: mysqlx_connector-0.0.4.tar.gz
  • Upload date:
  • Size: 2.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/45.0.0 requests-toolbelt/0.9.1 tqdm/4.41.1 CPython/3.8.1

File hashes

Hashes for mysqlx_connector-0.0.4.tar.gz
Algorithm Hash digest
SHA256 13df86ccecadd31f4153cfce14187ae5eb6933465c85abf983f22c508d341eb6
MD5 6e5d45f935bee673bc7715c406f1421a
BLAKE2b-256 c60f5616f5ce9e1ec0fc125c625273d72dbc2e111c3cc1c4c2de4f805c5aa3fc

See more details on using hashes here.

Provenance

File details

Details for the file mysqlx_connector-0.0.4-py3-none-any.whl.

File metadata

  • Download URL: mysqlx_connector-0.0.4-py3-none-any.whl
  • Upload date:
  • Size: 15.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/45.0.0 requests-toolbelt/0.9.1 tqdm/4.41.1 CPython/3.8.1

File hashes

Hashes for mysqlx_connector-0.0.4-py3-none-any.whl
Algorithm Hash digest
SHA256 9e9838f924c2f7e858068b5d6e64512702da3adf62648c999832f54268a56497
MD5 5fa8c8413ad392b9f83e5dc7ac2c1812
BLAKE2b-256 c67c850f1604793f88ce5f1e15b8c09de056a6ebff81b2aa516d75bdc9a51878

See more details on using hashes here.

Provenance

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