Created attachment 1841916 [details] sqlgrey-1.8.0-no-zero-in-date.patch Description of problem: I noticed that sqlgrey was finally added to epel8 but unfortunately I ran into an issue on CentOS 8 where the service fails to start due to some sql error. Version-Release number of selected component (if applicable): 1.8.0-22.el8 How reproducible: Steps to Reproduce: 1. Install sqlgrey and Percona MySQL 5.7 2. Create user and database for sqlgrey 3. Start service Actual results: sqlgrey[15291]: warning: Use of uninitialized value $DBI::errstr in concatenation (.) or string at /usr/sbin/sqlgrey line 246. sqlgrey[15291]: dbaccess: warning: couldn't do query: CREATE TABLE from_awl (sender_name varchar(64) NOT NULL, sender_domain varchar(255) NOT NULL, src varchar(39) NOT NULL, first_seen timestamp NOT NULL, last_seen timestamp NOT NULL, PRIMARY KEY (src, sender_domain, sender_name)): , reconnecting to DB sqlgrey[15291]: mail: failed to send: sqlgrey[15291]: fatal: create_from_awl_table error at /usr/sbin/sqlgrey line 195. When I try running the query manually, I get the following: mysql> CREATE TABLE from_awl (sender_name varchar(64) NOT NULL, sender_domain varchar(255) NOT NULL, src varchar(39) NO ERROR 1067 (42000): Invalid default value for 'last_seen' Expected results: Additional info: I did some additional digging and discovered if I run the following query ahead of time: SET @@session.sql_mode ="NO_ZERO_IN_DATE"; It works: mysql> CREATE TABLE from_awl (sender_name varchar(64) NOT NULL, sender_domain varchar(255) NOT NULL, src varchar(39) NO T NULL, first_seen timestamp NOT NULL, last_seen timestamp NOT NULL, PRIMARY KEY (src, sender_domain, sender_name)); Query OK, 0 rows affected (0.07 sec) I've included a patch which I've applied on a local package we've been using that should fix the problem.