---
title: "How to fix \"1364 Field 'alias' doesn't have a default value\""
description: "The error \"1364 Field 'alias' doesn't have a default value\" occurs during configuration import. Removing the \"STRICT_TRANS_TABLES\" mode from MySQL/MariaDB settings and restarting the service resolves this issue."
url: "https://docs.itrsgroup.com/docs/faq/op5/360014018777-op5-monitor-how-to-fix-1364-field-alias-doesn-t-have-a-default-value/index.html"
---
Sometimes you get the following error message when importing configuration:

```
You might want to do a complete reimport?
No imported configuration exists
A bug was encountered in /monitor/op5/nacoma/index.php Please contact OP5 Support regarding this matter. There was a SQL error The debug information in /tmp/nacoma-stacktraces/... will be essential to troubleshooting the problem, so please include it if you file a bug report or contact op5 Support.
```

If the stack trace file contains something like:

```
There was a SQL error
SQLSTATE[HY000]: General error: 1364 Field 'alias' doesn't have a default value
```

You probably have sql\_mode set to "STRICT\_TRANS\_TABLES" in the MySQL/MariaDB configuration. Verify by checking your /etc/my.cnf or using the MySQL cli:

```
# grep sql_mode /etc/my.cnf
## mysql -e "show variables like 'sql_mode'"
```

By default, this setting isn't set:

```
## mysql -e "show variables like 'sql_mode'"
+---------------+-------+
| Variable_name | Value |
+---------------+-------+
| sql_mode |  |
+---------------+-------+
```

Because of database design, we don't support the use of "STRICT\_TRANS\_TABLES", so you need to remove this setting in /etc/my.cnf and restart MySQL/MariaDB afterwards:

```
# systemctl restart mariadb # EL7
# service mysqld restart # EL6
```

If you can't find the stack trace in EL7, you can easily find it by issuing this command:

```
## find /tmp -type d -name "nacoma-stacktraces"
```


