I have two tables which are interlinked:

Table #1: CheckList

```
ID_CHECKLIST(PK) |  NAME_CHECKLIST |  VERSION(PK)
1                   XYZ               1.0.0
1                   XYZ               1.1.0
1                   XYZ               1.2.0
2                   PQR               1.0.0
3                   ABC               1.1.0

```

Table #2: Machine\_CHECKLIST

```
ID_MACHINE |  ID_CHECKLIST(Foreign Key) |  VERSION(Foreign)
1              1                           1.2.0
1              3                           1.1.0
2              1                           1.1.0

```

Now I want to get all of the remaining checklist that are not included in ID\_MACHINE = 1

So my query is like this:

```
SELECT 
    ID_CHECKLIST, NAME_CHECKLIST, VERSION
FROM
    CHECKLIST 
WHERE
    (ID_CHECKLIST NOT IN (SELECT MC.ID_CHECKLIST 
                          FROM MACHINE_CHECKLIST MC 
                          WHERE MC.ID_MACHINE = '1'))
    OR (VERSION NOT IN (SELECT MC.VERSION 
                        FROM MACHINE_CHECKLIST MC  
                        WHERE MC.ID_MACHINE = '1'))

```

This query does not return proper results.

I pass `ID_MACHINE` dynamically. I cannot pass Version and that's the problem.

What am I doing wrong in the query?