Skip to main content

Memgraph database adapter for Python language

Project description

pymgclient - Memgraph database adapter for Python language

pymgclient is a Memgraph database adapter for Python programming language compliant with the DB-API 2.0 specification described by PEP 249.

mgclient module is the current implementation of the adapter. It is implemented in C as a wrapper around mgclient, the official Memgraph client library. As a C extension, it is only compatible with the CPython implementation of the Python programming language.

pymgclient only works with Python 3.

Check out the documentation if you need help with installation or if you want to build pymgclient for yourself!

Documentation

Online documentation can be found on GitHub pages.

You can also build a local version of the documentation by running make from the docs directory. You will need Sphinx installed in order to do that.

Code sample

Here is an example of an interactive session showing some of the basic commands:

>>> import mgclient

# Make a connection to the database
>>> conn = mgclient.connect(host='127.0.0.1', port=7687)

# Create a cursor for query execution
>>> cursor = conn.cursor()

# Execute a query
>>> cursor.execute("""
        CREATE (n:Person {name: 'John'})-[e:KNOWS]->
               (m:Person {name: 'Steve'})
        RETURN n, e, m
    """)

# Fetch one row of query results
>>> row = cursor.fetchone()

>>> print(row[0])
(:Person {'name': 'John'})

>>> print(row[1])
[:KNOWS]

>>> print(row[2])
(:Person {'name': 'Steve'})

# Make database changes persistent
>>> conn.commit()

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

pymgclient-1.5.1.tar.gz (129.9 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

pymgclient-1.5.1-cp313-cp313-win_amd64.whl (2.3 MB view details)

Uploaded CPython 3.13Windows x86-64

pymgclient-1.5.1-cp313-cp313-manylinux_2_38_x86_64.manylinux_2_39_x86_64.whl (2.4 MB view details)

Uploaded CPython 3.13manylinux: glibc 2.38+ x86-64manylinux: glibc 2.39+ x86-64

pymgclient-1.5.1-cp313-cp313-macosx_15_0_arm64.whl (2.5 MB view details)

Uploaded CPython 3.13macOS 15.0+ ARM64

pymgclient-1.5.1-cp313-cp313-macosx_14_0_arm64.whl (2.5 MB view details)

Uploaded CPython 3.13macOS 14.0+ ARM64

pymgclient-1.5.1-cp312-cp312-win_amd64.whl (2.3 MB view details)

Uploaded CPython 3.12Windows x86-64

pymgclient-1.5.1-cp312-cp312-manylinux_2_38_x86_64.manylinux_2_39_x86_64.whl (2.4 MB view details)

Uploaded CPython 3.12manylinux: glibc 2.38+ x86-64manylinux: glibc 2.39+ x86-64

pymgclient-1.5.1-cp312-cp312-macosx_15_0_arm64.whl (2.5 MB view details)

Uploaded CPython 3.12macOS 15.0+ ARM64

pymgclient-1.5.1-cp312-cp312-macosx_14_0_arm64.whl (2.5 MB view details)

Uploaded CPython 3.12macOS 14.0+ ARM64

pymgclient-1.5.1-cp311-cp311-win_amd64.whl (2.3 MB view details)

Uploaded CPython 3.11Windows x86-64

pymgclient-1.5.1-cp311-cp311-manylinux_2_38_x86_64.manylinux_2_39_x86_64.whl (2.4 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.38+ x86-64manylinux: glibc 2.39+ x86-64

pymgclient-1.5.1-cp311-cp311-macosx_15_0_arm64.whl (2.5 MB view details)

Uploaded CPython 3.11macOS 15.0+ ARM64

pymgclient-1.5.1-cp311-cp311-macosx_14_0_arm64.whl (2.5 MB view details)

Uploaded CPython 3.11macOS 14.0+ ARM64

pymgclient-1.5.1-cp310-cp310-win_amd64.whl (2.3 MB view details)

Uploaded CPython 3.10Windows x86-64

pymgclient-1.5.1-cp310-cp310-manylinux_2_38_x86_64.manylinux_2_39_x86_64.whl (2.4 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.38+ x86-64manylinux: glibc 2.39+ x86-64

pymgclient-1.5.1-cp310-cp310-macosx_15_0_arm64.whl (2.5 MB view details)

Uploaded CPython 3.10macOS 15.0+ ARM64

pymgclient-1.5.1-cp310-cp310-macosx_14_0_arm64.whl (2.5 MB view details)

Uploaded CPython 3.10macOS 14.0+ ARM64

File details

Details for the file pymgclient-1.5.1.tar.gz.

File metadata

  • Download URL: pymgclient-1.5.1.tar.gz
  • Upload date:
  • Size: 129.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.9.23

File hashes

Hashes for pymgclient-1.5.1.tar.gz
Algorithm Hash digest
SHA256 defce8fc712ed2ca32ca75acfb3787b43a89592d8cef10b0f3e2aa7092e3d140
MD5 9e5587090d5461f6d67fec4a9d606aef
BLAKE2b-256 d27815d68f3389b4a28f61fe385a499d71ac00019b449785d937f649e20e2a46

See more details on using hashes here.

File details

Details for the file pymgclient-1.5.1-cp313-cp313-win_amd64.whl.

File metadata

  • Download URL: pymgclient-1.5.1-cp313-cp313-win_amd64.whl
  • Upload date:
  • Size: 2.3 MB
  • Tags: CPython 3.13, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.9.23

File hashes

Hashes for pymgclient-1.5.1-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 b8330095b124a783d2de7a57913e25928737cdf88f28fd72a5682abfd49e8eb4
MD5 823910663988f139e41596e6744eb52a
BLAKE2b-256 f64dd02cd10cdfc907c74441081896c52dec65c50310d001c26394195efec535

See more details on using hashes here.

File details

Details for the file pymgclient-1.5.1-cp313-cp313-manylinux_2_38_x86_64.manylinux_2_39_x86_64.whl.

File metadata

File hashes

Hashes for pymgclient-1.5.1-cp313-cp313-manylinux_2_38_x86_64.manylinux_2_39_x86_64.whl
Algorithm Hash digest
SHA256 3b8b6c36a74970ba2e93b8329fddf9728c562c1a6f3df846ffbc833eea525052
MD5 9de088e8661a84b12bc554ce46927fb0
BLAKE2b-256 76c95f1dd1af7d4c7e5897619ffd4e190deb0d866de567b4cd0f2ea00df7bdb9

See more details on using hashes here.

File details

Details for the file pymgclient-1.5.1-cp313-cp313-macosx_15_0_arm64.whl.

File metadata

File hashes

Hashes for pymgclient-1.5.1-cp313-cp313-macosx_15_0_arm64.whl
Algorithm Hash digest
SHA256 cde56666e314406b7eace394b3f9cd067e15f73f0d55e1a3892ab02f8985ede2
MD5 5b45ba8805574bde4d423228fa21bfca
BLAKE2b-256 42587b40481fe99a4f187ea3eda9ad325b4c2a35c3fbfad15563f469b801f5fe

See more details on using hashes here.

File details

Details for the file pymgclient-1.5.1-cp313-cp313-macosx_14_0_arm64.whl.

File metadata

File hashes

Hashes for pymgclient-1.5.1-cp313-cp313-macosx_14_0_arm64.whl
Algorithm Hash digest
SHA256 7ca3ca6a00c57638f141a20990fedf26f3558903ce92c8f9c1b5e3709280699f
MD5 2fa19661791f466dc3c30e53e11a9c75
BLAKE2b-256 3333d5b68864a5f19a36eadfe195884202e547bbc858f76beb92aa761d8148b0

See more details on using hashes here.

File details

Details for the file pymgclient-1.5.1-cp312-cp312-win_amd64.whl.

File metadata

  • Download URL: pymgclient-1.5.1-cp312-cp312-win_amd64.whl
  • Upload date:
  • Size: 2.3 MB
  • Tags: CPython 3.12, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.9.23

File hashes

Hashes for pymgclient-1.5.1-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 729c4a025c2eda7673bd7eeb60c3273194b63acbf0397ebbf7f33c272937ba8d
MD5 6e090d667e6d8ca806534eb4ad864e7d
BLAKE2b-256 1b68cbd7eefa98f6a46a3a8d27009530d431f005c90c74eca205b6cb71be33a4

See more details on using hashes here.

File details

Details for the file pymgclient-1.5.1-cp312-cp312-manylinux_2_38_x86_64.manylinux_2_39_x86_64.whl.

File metadata

File hashes

Hashes for pymgclient-1.5.1-cp312-cp312-manylinux_2_38_x86_64.manylinux_2_39_x86_64.whl
Algorithm Hash digest
SHA256 21af7e4eac4d3d6a68dc9fee9d9598c13d9700842ebb9c51c65d67add8bbfba1
MD5 fa7ee47469adb387d5122ef1dd9c84ad
BLAKE2b-256 6d9f89ab956fc0ef084242bda5a62a2e9d213a8af6ef27d353d7c6a31e26429c

See more details on using hashes here.

File details

Details for the file pymgclient-1.5.1-cp312-cp312-macosx_15_0_arm64.whl.

File metadata

File hashes

Hashes for pymgclient-1.5.1-cp312-cp312-macosx_15_0_arm64.whl
Algorithm Hash digest
SHA256 e543f9328f45254bdbc497a0afb03f75be25641595ef38faa27931a1bb143ac6
MD5 d6b0d91fdc9e0ac95c0d23d1580bc8d9
BLAKE2b-256 fa419d4a67cc207300f6bf454948cc7ca6da6dc1ef9717ac4c7a0fc83d913d5b

See more details on using hashes here.

File details

Details for the file pymgclient-1.5.1-cp312-cp312-macosx_14_0_arm64.whl.

File metadata

File hashes

Hashes for pymgclient-1.5.1-cp312-cp312-macosx_14_0_arm64.whl
Algorithm Hash digest
SHA256 504d0c3c3417d029a6376b810c66aa8b2299357c067d0f6292a78b1e1c5f89df
MD5 012ea597ef76381f327543ca4175cf09
BLAKE2b-256 d527c1045f7d32e20e7b29a522e8c1458fc8c1bcc84c799e9804ea342915a8da

See more details on using hashes here.

File details

Details for the file pymgclient-1.5.1-cp311-cp311-win_amd64.whl.

File metadata

  • Download URL: pymgclient-1.5.1-cp311-cp311-win_amd64.whl
  • Upload date:
  • Size: 2.3 MB
  • Tags: CPython 3.11, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.9.23

File hashes

Hashes for pymgclient-1.5.1-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 ce5cb8fc6de966cdf7d7c0a58a742321f50cda6ff84ec20ad8e6123bb9344494
MD5 b11e5770e2aec79772a6e896e97e2dab
BLAKE2b-256 61f6ddc2be9ac5daa5654c3d13eaa0321392fe39986a79796e281fb70912ef9b

See more details on using hashes here.

File details

Details for the file pymgclient-1.5.1-cp311-cp311-manylinux_2_38_x86_64.manylinux_2_39_x86_64.whl.

File metadata

File hashes

Hashes for pymgclient-1.5.1-cp311-cp311-manylinux_2_38_x86_64.manylinux_2_39_x86_64.whl
Algorithm Hash digest
SHA256 a95df69dfe5eac4c66ea5974f401ea9cf635de7adb04c0a97ec8c1cb3909e615
MD5 92fb8f6ac703536faabd885ed6098827
BLAKE2b-256 5375984b8b02e02861d57dcaf5cc766611f4848356026305655cd110cd6b8bd7

See more details on using hashes here.

File details

Details for the file pymgclient-1.5.1-cp311-cp311-macosx_15_0_arm64.whl.

File metadata

File hashes

Hashes for pymgclient-1.5.1-cp311-cp311-macosx_15_0_arm64.whl
Algorithm Hash digest
SHA256 f7463d60e2c4ce1492be8bf2a7e9cc89759b64e5ba98d9efa9e58b47c127aebd
MD5 ad6625fb0b10ceedfdd3e1ee846492cc
BLAKE2b-256 c8830a3e70fcbd7f5dcafdcd095ab1a00d45172d89a00a4aac76d56a9326ffaa

See more details on using hashes here.

File details

Details for the file pymgclient-1.5.1-cp311-cp311-macosx_14_0_arm64.whl.

File metadata

File hashes

Hashes for pymgclient-1.5.1-cp311-cp311-macosx_14_0_arm64.whl
Algorithm Hash digest
SHA256 f953f690fa4d6343bba31f192b6740fb8e4dd570e4d6c08b51abfcf528a991fc
MD5 668664073d1447941753f2f9713e62dc
BLAKE2b-256 5720010d02afc24e445647ca511259b58c1c1e80b5f2ad1d5e48f5694d818919

See more details on using hashes here.

File details

Details for the file pymgclient-1.5.1-cp310-cp310-win_amd64.whl.

File metadata

  • Download URL: pymgclient-1.5.1-cp310-cp310-win_amd64.whl
  • Upload date:
  • Size: 2.3 MB
  • Tags: CPython 3.10, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.9.23

File hashes

Hashes for pymgclient-1.5.1-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 53e9b6cd3742d4c9ebf25fe6fb646c8ca96f7b8836a5f6fdb7b8614624b81b3a
MD5 ad4cd08dc5f3fd68f88066a366b1e079
BLAKE2b-256 adaa4ed8b48189e2c7898b6858ad0aa4fab22cbc8eb1e9d9e97e2aa6a91f7830

See more details on using hashes here.

File details

Details for the file pymgclient-1.5.1-cp310-cp310-manylinux_2_38_x86_64.manylinux_2_39_x86_64.whl.

File metadata

File hashes

Hashes for pymgclient-1.5.1-cp310-cp310-manylinux_2_38_x86_64.manylinux_2_39_x86_64.whl
Algorithm Hash digest
SHA256 9d9b13774e996544cdae12757d7ae5530d78a112fd4b62cd583a22a508786b45
MD5 20c945cca51d2fbd7e30feff4077626f
BLAKE2b-256 670b63f6fe96ffde22449a600e8ab703aa25b289645d6d9f3569da761a6ac9e2

See more details on using hashes here.

File details

Details for the file pymgclient-1.5.1-cp310-cp310-macosx_15_0_arm64.whl.

File metadata

File hashes

Hashes for pymgclient-1.5.1-cp310-cp310-macosx_15_0_arm64.whl
Algorithm Hash digest
SHA256 db43fbe52ed283f1d7f5db4687f29b6a0481b0fb3057d7da05104a9c669569c3
MD5 b082077031fa6202e08f4ae6b4665e05
BLAKE2b-256 5305e6547655f01484305fbe79f080a66acdb770e80eb18799c3bfc9af58dd96

See more details on using hashes here.

File details

Details for the file pymgclient-1.5.1-cp310-cp310-macosx_14_0_arm64.whl.

File metadata

File hashes

Hashes for pymgclient-1.5.1-cp310-cp310-macosx_14_0_arm64.whl
Algorithm Hash digest
SHA256 36fc48656c3b28887495f7f3301fba5791a0ffa505caf07ee225f147c3e28162
MD5 1fca46ede47bc12a00db708723063ff3
BLAKE2b-256 7e5120b8b6cf1a04dd6a4be3d842039619c60d7c125ba9a3a47dfb67686117f2

See more details on using hashes here.

Supported by

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