The application now works with empty database, too.