Skip to main content

A tool to upgrade DuckDB database files.

Project description

duckdb-upgrade

Tests

A tool to easily upgrade duckdb databases from one version to another. It automates the process of exporting the contents of a DuckDB database and then importing them into a newer version of a DuckDB database.

[!IMPORTANT] This process isn't guaranteed to be compatible with every combination of DuckDB. The tool is limited to forward upgrades only, but things may still break during that upgrade. By default this tool keeps a backup of the old version of the database, but it is still important to be mindful of any process that may cause data corruption. Any data loss or corruption is on you, so exercise reasonable precautions before use.

Usage

This tool is available both through pip and Docker. Use one of the following commands to run it, or your preferred method to run Python packages or Docker images. These examples cover upgrading some DuckDB in the current directory to the latest version of the database.

via Pipx

$ pipx run duckdb-upgrade example.duckdb

via Docker

$ docker run -v $(pwd):/data ghcr.io/mrflynn/duckdb-upgrade:latest /data/example.duckdb

Advanced Usage

You can also specify the target version you with to upgrade to using the -t flag. For example, if you wish to upgrade some database to version 0.10.0, run the command as follows:

$ duckdb-upgrade -t '0.10.0' example.duckdb

[!CAUTION] You can also run the tool with the --no-backup flag which won't create a backup of the original database before upgrading it. This is potentially dangerous, so please use with caution. Again, any data loss resulting from this is on you.

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

duckdb-upgrade-0.2.0.tar.gz (8.8 kB view details)

Uploaded Source

Built Distribution

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

duckdb_upgrade-0.2.0-py3-none-any.whl (7.7 kB view details)

Uploaded Python 3

File details

Details for the file duckdb-upgrade-0.2.0.tar.gz.

File metadata

  • Download URL: duckdb-upgrade-0.2.0.tar.gz
  • Upload date:
  • Size: 8.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for duckdb-upgrade-0.2.0.tar.gz
Algorithm Hash digest
SHA256 cf697d45dcb02830c4d5cc14384d87722a5738d5fcedeb64117a1fa4ec9dfe84
MD5 9d437fa9b47ce703626107f42c7f776b
BLAKE2b-256 9b64ee95b67384245802154da555d16c6683e24d3da5a77909cee57425e960e5

See more details on using hashes here.

Provenance

The following attestation bundles were made for duckdb-upgrade-0.2.0.tar.gz:

Publisher: release.yaml on MrFlynn/duckdb-upgrade

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file duckdb_upgrade-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: duckdb_upgrade-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 7.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for duckdb_upgrade-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 acaf5d5927dbab48bf9c33594f622f25ce0ed1eeaa53e875b96777591b3b1d0e
MD5 1b0719d17c5934b80754f5217c316c82
BLAKE2b-256 b9824c673d58946f433e18b4bae4998f48f73dce64bed87676f5d2670a12b173

See more details on using hashes here.

Provenance

The following attestation bundles were made for duckdb_upgrade-0.2.0-py3-none-any.whl:

Publisher: release.yaml on MrFlynn/duckdb-upgrade

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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