It's not really practical to use wee_import in the manner your describe. 
wee_import works by obtaining an archive record from the source and then 
inserting the archive record in the database, if a record with the same 
dateTime value already exists in the archive then the imported record is 
discarded. The only way you could use wee_import would be to export the 
records concerned from the WeeWX archive in their entirety, delete the 
records concerned from the archive, add the missing data to the exported 
data and then import the updated data back into WeeWX. It would work and 
could be automated to some extent, but there is still going to be a good 
bit of manually manipulation of the data.

You may find that you can do better by operating directly on the archive 
table with some well chosen SQL. The wee_import approach may be safest but 
I imagine will be the most labour intensive. The SQL approach may be 
quicker but also more risk of doing something bad to your, that could be 
mitigated by some testing on expendable data. You would also need to use 
wee_database to rebuild your daily summaries after using SQL to update the 
archive.

Key point in either case would be to backup your data first.

Gary
On Thursday, 24 December 2020 at 07:32:43 UTC+10 [email protected] 
wrote:

> Hi,
>
> I'm about to close gaps in my data history (due to system downtime and 
> also historical data from my pre-weewx times).
> Adding missing records is nicely described and looks rather simple and 
> straightforward.
>
> However, I don't know how to handle the update of already existing records.
> E.g. due to missing information my radiation data in the DB are missing 
> while all other sensor data are already stored.
>
> Can I use wee_import the same way I do for importing new records ?
>
> If so, what data do I have to provide ? Only the content of the 
> to-be-updated fields or the whole record (i.e. values for all fields).
>
> Or, does it not work with wee_import and I have to do it differently ?
> If so, how ?
>
> --------------
>
> Another question indirectly related to the import of history data.
>
> How do I display earlier years (in day, week, month, year aggregation like 
> in the current year ?) beyond the scarce reports to be chosen in the "upper 
> right corner" ?
>
> Will I have to create a sort of history skin where I can select date, 
> week, month, year and based on this selection the picture generator will 
> provide the graphics ?
> Or does some such"piece" already exist (fully, partially, ...) ?
>
> Please advise.
>
> Thanks
> Rainer
>

-- 
You received this message because you are subscribed to the Google Groups 
"weewx-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/0458c50b-0cfa-4b41-bc3c-162224d4913an%40googlegroups.com.

Reply via email to