[ticket/12448] Fix null columns for postgres

PHPBB3-12448
[ticket/12448] Fix null columns for MS SQL

PHPBB3-12448