I thought it might only work on sqlite....it does process the records in 
mysql but doesn't do anything with them...obviously.

Thanks

On Tuesday, 13 March 2018 20:21:16 UTC+11, gjr80 wrote:
>
> Greg,
>
> The --check-strings (and its friend --fix-strings) action is there for 
> SQLite databases (do a wee_database --help). It will run on a MySQL 
> install but essentially has no effect. Having a null/NULL value in a 
> database is fine, that is how the python None values are stored. However, 
> having a string or a null string in a weeWX database field is not OK, that 
> is what --check-strings will pickup and --fix-strings will fix. I'm not 
> sure why the null string only comes up for SQLite databases, before my 
> time, though one way that you can easily get them if you are not carfeul is 
> through use of a graphical db browser/editor.
>
> Gary
>
> On Tuesday, 13 March 2018 19:02:58 UTC+10, Greg from Oz wrote:
>>
>> Hi,
>> I am using mqysql as my weewx database.
>> I run the wee_database --check-strings and it comes back clean but if I 
>> run mysql command to look for NULL I get a lot of results.
>> Anyone know why this would be the case?
>>
>> Thanks
>>
>> wee_database --check-strings
>> Using configuration file /etc/weewx/weewx.conf
>> Using database binding 'wx_binding', which is bound to database 
>> 'archive_mysql'
>> Preparing Null String Check, this may take awhile...
>> Checking record: 488186; Timestamp: 2018-03-12 10:05:00 AEDT (1520809500)
>> No null strings found.
>> Completed Null String Check in 28.89 seconds.
>>
>>
>> Yet, if I run the command below it shows I do have NULL values.
>>
>>
>> MariaDB [weewx]> select dateTime, rain , rainRate from archive where rain 
>> IS NULL;
>> +------------+------+----------+
>> | dateTime   | rain | rainRate |
>> +------------+------+----------+
>> | 1501541984 | NULL |        0 |
>> | 1501546184 | NULL |        0 |
>> | 1501563583 | NULL |        0 |
>> | 1501564184 | NULL |        0 |
>> | 1501564490 | NULL |        0 |
>> | 1501585184 | NULL |        0 |
>> | 1501590884 | NULL |        0 |
>> | 1501634684 | NULL |        0 |
>> | 1501635284 | NULL |        0 |
>> | 1501636784 | NULL |        0 |
>> | 1501656884 | NULL |        0 |
>> | 1501659584 | NULL |        0 |
>> | 1501675645 | NULL |        0 |
>>
>>

-- 
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.
For more options, visit https://groups.google.com/d/optout.

Reply via email to