Skip to main content

Mireo SpaceTime MSQL connector

Project description

Mireo SpaceTime MSQL connector

msql-driver is a Python module for querying Mireo SpaceTime database using MSQL query language.

Features

  • Both blocking and asynchronous modes of operation are available.
  • Query results are convertible to Python lists, NumPy arrays and Pandas dataframes.
  • Requires CPython 3.9+.
  • Available for Linux (glibc 2.17+ and musl 1.2+; x86-64 and arm64), Windows (x86-64 and arm64) and MacOS (10.12+ x86-64 and 11.0+ arm64).

Installation

pip install -U msql-driver

Conversions to NumPy and Pandas data types require those packages that can be installed as optional dependencies:

pip install -U msql-driver[numpy]
pip install -U msql-driver[pandas]
pip install -U msql-driver[all]

Example

import msql_driver

# Connect
session = msql_driver.SessionConfig().host(<address>).user(<org>, <user>, <password>).build()
print(session.status())  # SessionStatus.Connected

# Run query
res, = session.run_query("select * from st.segment limit 10")

# Print column names and their MSQL data types
print(res.row_type.columns)

# Iterating over rows converts each lazily to a Python list of appropriate Python data types
for row in res:
	print(row)

# Query result can be converted to:
rows = res.to_list()  # Python list of appropriate Python data types
arr = res.to_numpy()  # NumPy array of appropriate NumPy data types (requires numpy)
df = res.to_pandas()  # Pandas dataframe of appropriate NumPy/Pandas data types (requires pandas)

# Disconnect
session.stop()
print(session.status())  # SessionStatus.Stopped

License

Licensed under BSD 3-Clause “New” or “Revised” License.

Credits

Authored and maintained by Mireo.

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

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

msql_driver-0.6.0-cp39-abi3-win_arm64.whl (852.5 kB view details)

Uploaded CPython 3.9+Windows ARM64

msql_driver-0.6.0-cp39-abi3-win_amd64.whl (931.5 kB view details)

Uploaded CPython 3.9+Windows x86-64

msql_driver-0.6.0-cp39-abi3-musllinux_1_2_x86_64.whl (994.9 kB view details)

Uploaded CPython 3.9+musllinux: musl 1.2+ x86-64

msql_driver-0.6.0-cp39-abi3-musllinux_1_2_aarch64.whl (911.7 kB view details)

Uploaded CPython 3.9+musllinux: musl 1.2+ ARM64

msql_driver-0.6.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (997.5 kB view details)

Uploaded CPython 3.9+manylinux: glibc 2.17+ x86-64

msql_driver-0.6.0-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (922.3 kB view details)

Uploaded CPython 3.9+manylinux: glibc 2.17+ ARM64

msql_driver-0.6.0-cp39-abi3-macosx_11_0_arm64.whl (872.6 kB view details)

Uploaded CPython 3.9+macOS 11.0+ ARM64

msql_driver-0.6.0-cp39-abi3-macosx_10_12_x86_64.whl (947.1 kB view details)

Uploaded CPython 3.9+macOS 10.12+ x86-64

File details

Details for the file msql_driver-0.6.0-cp39-abi3-win_arm64.whl.

File metadata

File hashes

Hashes for msql_driver-0.6.0-cp39-abi3-win_arm64.whl
Algorithm Hash digest
SHA256 963dd824362361cb785699f86d29c2dc8b7468460684241b02bbed1d539f15b1
MD5 273d0c8ff22239402253583d84076d89
BLAKE2b-256 933902223477a2f71be6f8cb29c2eb8a3277cde74757ea9ea6558bbb575b5fe9

See more details on using hashes here.

File details

Details for the file msql_driver-0.6.0-cp39-abi3-win_amd64.whl.

File metadata

File hashes

Hashes for msql_driver-0.6.0-cp39-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 249fe9b4edceaf6d56e299f20b147e1ca994ce16196cde19ebca9ceb0b824530
MD5 eb78120349fbccc359ab23f99aec000f
BLAKE2b-256 00a77c213e263478c61bb69904bc8494452cbf3ff397e170af6b677405a619b2

See more details on using hashes here.

File details

Details for the file msql_driver-0.6.0-cp39-abi3-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for msql_driver-0.6.0-cp39-abi3-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 dc1995c8c0e4d1a48404f342cd506719c45db25fdc66819adeb9d08d0b47100c
MD5 fb7b567eefdafc835c875ad320aad9e3
BLAKE2b-256 56de44a838a5da6caa10071a7a50ca4116d10f3402cf86caa64634ad22571075

See more details on using hashes here.

File details

Details for the file msql_driver-0.6.0-cp39-abi3-musllinux_1_2_aarch64.whl.

File metadata

File hashes

Hashes for msql_driver-0.6.0-cp39-abi3-musllinux_1_2_aarch64.whl
Algorithm Hash digest
SHA256 f108ab96c25175a1cdb6655b7f577a41703c02df63498b2bcacdf9f669e23a5a
MD5 7c5f95198c050af5ed393b7495928d53
BLAKE2b-256 2da43881ac2aa062dc6a996cdd68a0b950fded6cb3405eea345c473c453a42d4

See more details on using hashes here.

File details

Details for the file msql_driver-0.6.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for msql_driver-0.6.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 b668c1bde785bf88c7e7e5cf376d7c0aa0f28298c5a477eccc9c5ec91c473990
MD5 67313393383c7d4bc73da04971af15d1
BLAKE2b-256 291051b3910a32244eea7e5427da0c496a850cd04856519fa5321ea9a1d08cca

See more details on using hashes here.

File details

Details for the file msql_driver-0.6.0-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for msql_driver-0.6.0-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 707aee26770cf3e7f53aba6be9feb9367ec5d614c0273e9734269c6042bad5b7
MD5 8543e4391ea78d8159d561b70a876bd4
BLAKE2b-256 d9b52a092e9fa315c751f5630ce1add423b36726a2dccad94156760c5ac58ff6

See more details on using hashes here.

File details

Details for the file msql_driver-0.6.0-cp39-abi3-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for msql_driver-0.6.0-cp39-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 c95b814c955a5e3f4352415250024617ccd4d30c5cf51a1f602ffc9b66dd0320
MD5 aeb6165cc6eae8f42ce7a30a2ba58dda
BLAKE2b-256 4eafb9476a3151d07dd403b7631b4b88a2b7642e66717d4c5eb87ef149ab9ae7

See more details on using hashes here.

File details

Details for the file msql_driver-0.6.0-cp39-abi3-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for msql_driver-0.6.0-cp39-abi3-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 d7d6073973ddb53faa4b4f16d9ef17065c5e1d4fb7a45032dbf57d29bcaa8479
MD5 3f8a716ee4c5ea2b09a071baddff66f8
BLAKE2b-256 8bd97aa2b367491d5193cd38f3cf01b663703b5668fa8876ef4fc1b04ccae2ae

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