I do not know of and could not find a setting to do this.
There are three ways to get a NULL to replace an empty string (assume in the following a table with name and info columns) -
1) Don't list the columns that are empty strings. The following query will insert a name with a NULL for info.
PHP Code:
$query = "INSERT INTO table (name) values ('$myname')";
2) Explicitly put the NULL keyword in the query (note that you cannot put a '$myinfo' variable, with or without quotes, and set it to NULL or 'NULL' and have it work) -
PHP Code:
$query = "INSERT INTO table (name,info) values ('$myname',NULL)";
3) Use an IF statement to give a NULL or the original value -
PHP Code:
$query = "INSERT INTO table (name,info) values (IF(LENGTH('$myname')=0,NULL,'$myname'),IF(LENGTH('$myinfo')=0,NULL,'$myinfo'))";