Skip to content
This repository has been archived by the owner on Jun 27, 2022. It is now read-only.

Add support for different database types #3

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

fabyte
Copy link

@fabyte fabyte commented Jan 9, 2021

Initially, MySQL/MariaDb and SQLite are supported.

Tested for SQLite on the following system:

$ lsb_release -a
No LSB modules are available.
Distributor ID: Raspbian
Description:    Raspbian GNU/Linux 10 (buster)
Release:        10
Codename:       buster

$ python --version
Python 3.9.1

No problems occured for a sqlite database with >4 million rows.

Initially, MySQL/MariaDb and SQLite are supported.
@CarlosGS
Copy link

This is a convenient addition, tested and I think it could be merged. It worked great with SQLite and a 800Mb home-assistant_v2.db file, thanks @fabyte! Note, maybe remove the (you need to get rid of the first three `add_argument` calls above) to prevent confusion.

@dseifert THANK YOU so much for taking the time to share and document your script! It is extremely useful, and exactly as you wrote: "if you only figure this out after already having assembled a huge amount of historical data, there is no option to migrate your data" 🤦 PS: If I may suggest a small addition to the last part of the readme: "In this influxdb.yaml you may need to replace the default host "a0d7b954-influxdb" with "homeassistant.local". Thanks again!

@jonasdiemer
Copy link

Also tested today with sqlite3 - no problems. This PR should be merged (I only found it after I did modifications myself).

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants