Skip to main content

A handy Python library for common database admin operations.

https://img.shields.io/pypi/v/pydba.svg

Requirements

https://img.shields.io/pypi/pyversions/pydba.svg

Features

Basic imports and class constructor usage.

>>> from pydba import PostgresDB
>>> db = PostgresDB()
>>> db.available()
True
>>> db.names()
['postgres']

Database creation and deletion.

>>> db.create('foo')
>>> db.names()
['postgres', 'foo']
>>> db.rename('foo', 'bar')
>>> db.names()
['postgres', 'bar']

Database backup and restore.

>>> db.dump('bar', 'bar.backup')
>>> db.drop('bar')
>>> db.names()
['postgres']
>>> db.restore('bar', 'bar.backup')
>>> db.names()
['postgres', 'bar']

Querying and shutting down database connections.

>>> db.connections('postgres')
[Connection(datname='postgres', pid=13832, state='idle', query='', usename='drkjam', ...)]
>>> db.kill_connections('postgres')
>>> db.connections('postgres')
[]

Release files for pydba 1.2.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distributions (sdists)

Source distribution for pydba 1.2.1
File Size Uploaded
pydba-1.2.1.zip 10.4 kB Details
pydba-1.2.1.tar.gz 6.8 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for pydba 1.2.1
File Interpreter ABI Platform
pydba-1.2.1-py2.py3-none-any.whl Python 2, Python 3 none any Details

Total release size: 26.9 kB

Release files / pydba-1.2.1.zip

Download URL pydba-1.2.1.zip
Size 10.4 kB
Tags Source
SHA-256 checksum
How to use checksums
b91ded1efad5e3fce870594737e02e0ad917af648ada5e1cc5ebe2858a8f19b1
BLAKE2b-256 checksum
How to use checksums
c40c1e625a0c1954c23bce11a0075697d2cee6c0d073387a92711c95b919a791
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release files / pydba-1.2.1.tar.gz

Download URL pydba-1.2.1.tar.gz
Size 6.8 kB
Tags Source
SHA-256 checksum
How to use checksums
ffa666b1d4b743484202f1ee8d239bd3c4121af6498f0c2a5ced933f0b2d1ad1
BLAKE2b-256 checksum
How to use checksums
f98ad91ca3c79be152ba13c46f7d241387d7d680938112a8360198b66adb6b87
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release files / pydba-1.2.1-py2.py3-none-any.whl

Download URL pydba-1.2.1-py2.py3-none-any.whl
Size 9.6 kB
Tags Python 2 Python 3
SHA-256 checksum
How to use checksums
4d25911d665599e2230040e43114dfcb870d790d9fc9e993170dfc9e541eb917
BLAKE2b-256 checksum
How to use checksums
d7c2a2e5a52c3468e5760cf6fa1445743f0a5a5803259e320b447c904913c87f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release history Release notifications | RSS feed

This release

1.2.1 This release

3 release files

1.2.0

3 release files

1.1.0

3 release files

1.0.0

3 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page