diff options
author | Miika Turkia <miika.turkia@gmail.com> | 2015-02-22 08:20:20 +0200 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2015-02-22 07:48:33 -0800 |
commit | 44b4ae00ed772b79c4c23327dda2d8a209bffca9 (patch) | |
tree | f3c96f8ae6546ca5d2c46d350ac99399119293ca /parse-xml.c | |
parent | ad5503fec5f45ee9374b690828b67fcc622de065 (diff) | |
download | subsurface-44b4ae00ed772b79c4c23327dda2d8a209bffca9.tar.gz |
Discard deleted dives on DM5 import
I had some double profiles with slight differences in them, until I
realized that this was caused by including deleted dives in the import.
Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'parse-xml.c')
-rw-r--r-- | parse-xml.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/parse-xml.c b/parse-xml.c index 3d50bcd26..1d9ce9777 100644 --- a/parse-xml.c +++ b/parse-xml.c @@ -2407,7 +2407,7 @@ int parse_dm5_buffer(sqlite3 *handle, const char *url, const char *buffer, int s /* StartTime is converted from Suunto's nano seconds to standard * time. We also need epoch, not seconds since year 1. */ - char get_dives[] = "select DiveId,StartTime/10000000-62135596800,Note,Duration,coalesce(SourceSerialNumber,SerialNumber),Source,MaxDepth,SampleInterval,StartTemperature,BottomTemperature,StartPressure,EndPressure,'','',SurfacePressure,DiveTime,SampleInterval,ProfileBlob,TemperatureBlob,PressureBlob,'','','','',SampleBlob FROM Dive"; + char get_dives[] = "select DiveId,StartTime/10000000-62135596800,Note,Duration,coalesce(SourceSerialNumber,SerialNumber),Source,MaxDepth,SampleInterval,StartTemperature,BottomTemperature,StartPressure,EndPressure,'','',SurfacePressure,DiveTime,SampleInterval,ProfileBlob,TemperatureBlob,PressureBlob,'','','','',SampleBlob FROM Dive where Deleted is null"; retval = sqlite3_exec(handle, get_dives, &dm5_dive, handle, &err); |