You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In case anyone else prefers using PostgreSQL instead of SQL lite. You can use a Foreign data wrapper to link the SQLite database to PostgreSQL and then you can query from PostgreSQL. https://github.com/pgspider/sqlite_fdw
You may have to install it from source like me if your on Ubuntu or not using: CentOS 9, RHEL 9, Rocky Linux 9, AlmaLinux 9. But it's not to hard to setup. You basically just install the dependencies, find your pg_config file which pg_config, then set it export PG_CONFIG=/usr/bin/pg_config, lastly run the commands listed in the Readme.
Then just link it up in your postgres databse.
CREATE EXTENSION sqlite_fdw;
CREATE SERVER garmin_activities_sqlite FOREIGN DATA WRAPPER sqlite_fdw
OPTIONS (database '/home/your_user_name/HealthData/DBs/garmin_activities.db');
IMPORT FOREIGN SCHEMA main FROM SERVER garmin_activities_sqlite INTO public;
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
In case anyone else prefers using PostgreSQL instead of SQL lite. You can use a Foreign data wrapper to link the SQLite database to PostgreSQL and then you can query from PostgreSQL. https://github.com/pgspider/sqlite_fdw
You may have to install it from source like me if your on Ubuntu or not using: CentOS 9, RHEL 9, Rocky Linux 9, AlmaLinux 9. But it's not to hard to setup. You basically just install the dependencies, find your pg_config file
which pg_config
, then set itexport PG_CONFIG=/usr/bin/pg_config
, lastly run the commands listed in the Readme.Then just link it up in your postgres databse.
Beta Was this translation helpful? Give feedback.
All reactions