Skip to main content

rda_python_dbms

RDA Python package to manage RDA PostgreSQL databases.

Programs

The package installs the following command-line utilities, all running as the current user:

  • pgddl — create, drop or alter tables, indexes and keys from the table definitions in <tablename>.json files
  • pgseq — reset the sequences of all (or the given) tables in one or more schemas
  • pgbackup — dump the configured rdadb schemas on rda-pgdb-02 into /data/pgbackup, replacing existing backups and emailing a summary
  • pgdbdump — dump a PostgreSQL database to a local directory
  • pgdbrestore — restore a PostgreSQL database from a local dump directory
  • pgchksum — re-check archived files against their RDADB records (checksums, sizes and timestamps for Web and Saved files; sizes and timestamps only for Quasar backup files), optionally fix the records (-x), and email each dataset's primary owner a list of its missing files (-e)
  • pgcmptables — compare the columns, indexes and data of identical tables on two database servers
  • pgschema — copy the tables of a schema into the same schema in another database on the same server

Run a program without its required options to print its usage. Do not use -h for help: it is the host name option in several programs. pgbackup has no usage text and starts the backup as soon as it runs.

Environment setup

Create a Python environment first; package installs in the next section run inside whichever environment you activate here.

Option A — Python venv (DECS machines)

python3 -m venv $ENVHOME          # e.g. /glade/u/home/gdexdata/gdexmsenv
source $ENVHOME/bin/activate

Option B — Conda (DAV/Casper)

conda create --prefix $ENVHOME python=3.12   # e.g. /glade/work/gdexdata/conda-envs/pg-gdex
conda activate $ENVHOME

Installing rda-python-dbms

Pick whichever install mode fits your workflow. All variants pull in the transitive dependency (rda_python_common) automatically.

For local development, clone this repo alongside your project and install it in editable mode so that changes are picked up without re-installing:

git clone https://github.com/NCAR/rda-python-dbms.git
cd rda-python-dbms
pip install -e .

To test a specific branch (e.g. an in-progress feature or fix branch), pass -b/--branch to git clone:

git clone -b <branch-name> https://github.com/NCAR/rda-python-dbms.git
cd rda-python-dbms
pip install -e .

For a regular (non-editable) install from a checkout:

pip install /path/to/rda-python-dbms

For a production install on a system that uses the published distribution:

pip install rda_python_dbms

Metadata

Release files for rda-python-dbms 3.0.1

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

Source distribution (sdist)

Source distribution for rda-python-dbms 3.0.1
File Size Uploaded Provenance Actions
rda_python_dbms-3.0.1.tar.gz 210.9 kB With provenance Details for rda_python_dbms-3.0.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for rda-python-dbms 3.0.1
File Interpreter ABI Platform Actions
rda_python_dbms-3.0.1-py3-none-any.whl Python 3 none any Details for rda_python_dbms-3.0.1-py3-none-any.whl

Total release size: 1.0 MB

Release files / rda_python_dbms-3.0.1.tar.gz

Download URL rda_python_dbms-3.0.1.tar.gz
Size 210.9 kB
Tags Source
SHA-256 checksum
How to use checksums
6a2581d5576a23ba1743bfdd36df444705b027b7876352455339ec7c80cd48ec
BLAKE2b-256 checksum
How to use checksums
7dbc9207f28dd5925f0609b9c3e5141f00595646ca514cb8427cd5de37a404ec
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 26, 2026.

Transparency log

Release files / rda_python_dbms-3.0.1-py3-none-any.whl

Download URL rda_python_dbms-3.0.1-py3-none-any.whl
Size 802.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
19d34cc81ed660aa6d34e7a2281a1a540c33b5a4b129853afa3e6e4178cde4bd
BLAKE2b-256 checksum
How to use checksums
597e8dacafa77713807c1c300e2ea730c4a5f530f240403837630422661ff825
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 26, 2026.

Transparency log

Security for rda-python-dbms 3.0.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for rda_python_dbms-3.0.1.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 26, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

3.0.1 This release

2 release files Full provenance

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