jshrake / healthkit-to-sqlite Goto Github PK
View Code? Open in Web Editor NEWCommand-line tool to convert Apple HealthKit data to a SQLite database.
License: Apache License 2.0
Command-line tool to convert Apple HealthKit data to a SQLite database.
License: Apache License 2.0
Ran this on my exported ZIP and got:
$ healthkit-to-sqlite export.zip sqlite://healthkit.db
Error: error returned from database: (code: 1) near "Press": syntax error
Caused by:
(code: 1) near "Press": syntax error
Describe the bug
After several minutes of running this:
healthkit-to-sqlite export.zip sqlite://healthkit.db
I get the reported error.
To Reproduce
If possible, please share a minimal export.zip
or XML snippet that can reproduce the issue.
Debug Output
Please share the relevant log output after running with RUST_LOG=debug
. This will provide insight into any SQL failures:
RUST_LOG=debug healthkit-to-sqlite export.zip sqlite://healthkit.db
[2023-08-12T04:25:38Z INFO sqlx::query] INSERT INTO Workout (`workoutActivityType`, …; rows affected: 0, rows returned: 0, elapsed: 29.500µs
INSERT INTO
Workout (
`workoutActivityType`,
`duration`,
`durationUnit`,
`totalDistance`,
`totalDistanceUnit`,
`totalEnergyBurned`,
`totalEnergyBurnedUnit`,
`sourceName`,
`sourceVersion`,
`device`,
`creationDate`,
`startDate`,
`endDate`,
`metadata_HKIndoorWorkout`,
`metadata_HKTimeZone`,
`metadata_HKWeatherTemperature`,
`metadata_HKWeatherHumidity`,
`workoutEvents`,
`workoutStatistics`,
`geometry`
)
VALUES
(
?,
?,
?,
?,
?,
?,
?,
?,
?,
?,
?,
?,
?,
?,
?,
?,
?,
?,
?,
?
)
Error: error returned from database: (code: 1) table Workout has no column named workoutStatistics
Caused by:
(code: 1) table Workout has no column named workoutStatistics
Desktop (please complete the following information):
Additional context
$ sqlite3 healthkit.db
SQLite version 3.36.0 2021-06-18 18:58:49
Enter ".help" for usage hints.
sqlite> .schema Workout
CREATE TABLE `workout`
(
`creationdate` DATE,
`device` TEXT,
`duration` REAL,
`durationunit` TEXT,
`enddate` DATE,
`geometry` JSON,
`metadata_hkaveragemets` TEXT,
`metadata_hkelevationascended` TEXT,
`metadata_hkindoorworkout` INTEGER,
`metadata_hkmetadatakeysyncidentifier` TEXT,
`metadata_hkmetadatakeysyncversion` INTEGER,
`metadata_hktimezone` TEXT,
`metadata_hkweatherhumidity` TEXT,
`metadata_hkweathertemperature` TEXT,
`sourcename` TEXT,
`sourceversion` TEXT,
`startdate` DATE,
`totaldistance` REAL,
`totaldistanceunit` TEXT,
`totalenergyburned` REAL,
`totalenergyburnedunit` TEXT,
`workoutactivitytype` TEXT,
`workoutevents` JSON
);
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.