What would you like to show instead of null values in the rows that contain them? A NULL value in a field that is a foreign key can be considered a design flaw of the database. If you want to have null values as foreign key then don't pretend this is a relation and use QSqlTableModel() with a custom delegate that will treat the foreign key in a special manner - by replacing its values with ones from another table.