There is a table Log with a primary key LogId . There is also a UserLog table with a userlogIdLog field.
Relationship tables such:
Log.LogId = UserLog.userlogIdLog It is necessary to display all records from the Log table except for those that are in the UserLog . In this case, the records in the userlog may not be.
I did the following:
SELECT * FROM log RIGHT OUTER JOIN userlog ul ON ul.userlogIdLog = log.LogId WHERE log.LogId IS NULL
LEFT JOIN ... WHERE ul.userlogIdLog IS NULL- zb '