Here’s an outline of what I would do.  I use mysql and know nothing about 
sqlite, but assume the basic export and delete operations are easy.
1. Export the data you want from the old sqlite database into a CSV file.  
Export the full archive records, not just the missing field(s).  
2. Edit the CSV file if needed, to remove some records or whatever.
3. Use sqlite to delete from the current database the records corresponding to 
those in the CSV file.  (backup copy of db, like you said!)
4. Use wee_import to import the CSV file into the current database.  
5. Use wee_database to drop and rebuilt the daily summaries in weewx.

I used something like this to resurrect a bunch of historical data after a 
severe case of user error earlier this year. 

  -Les



> On 8 May 2021, at 7:46, Ernest Jillson <etjill...@gmail.com> wrote:
> 
> I imported years of data from wunderground into my weewx db. There was a 
> period of very bad rain data due to a malfunctioning tipping bucket. Also had 
> a day where a small grasshopper managed to get into the little hole, then 
> proceeded to rack up about 15 inches of rain for me that day while trying to 
> escape.
>  
> I stopped weewx, made a copy of my db, then used sqlite browser to remove all 
> of the bad rain data, day by day, week by week. When I was satisfied, I 
> restarted weewx and life was good.
>  
> It wasn't until a month later, while flipping through some of my past data 
> that I realized I had somehow managed to remove much more data than I wanted 
> to. I mean, we're talking like a year's worth of rain data.
>  
> I don't want to import those days all over again, but I can if that's the 
> only way. I'd much rather like to find a way to "bring over" the rain from 
> the saved database for a range of dates, then start the fixing process again. 
> When I brought the data over from wunderground, there were lots of dew 
> point/humidity and temperature anomolies I had to fix as well.
>  
> My question:  Is there a way (perhaps using the sqlite browser) to import a 
> column (rain) from one database (the saved one) to the new database for just 
> a range of dates?
>  
> Thanks in advance!
> 
> 
> -- 
> 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 weewx-user+unsubscr...@googlegroups.com 
> <mailto:weewx-user+unsubscr...@googlegroups.com>.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/weewx-user/CAC5oUmN6qQVrx0YTCLHhkKRdxJAg7%3DEjtcwDkudBO8bzJm956A%40mail.gmail.com
>  
> <https://groups.google.com/d/msgid/weewx-user/CAC5oUmN6qQVrx0YTCLHhkKRdxJAg7%3DEjtcwDkudBO8bzJm956A%40mail.gmail.com?utm_medium=email&utm_source=footer>.

-- 
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 weewx-user+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/C4BC476C-0FF0-48D7-A66D-90C9DC01F3CE%402pi.org.

Reply via email to