The question is answerable with the current data-model, but it is a lot of work, complicated, and a sheer waste of time.
However, with a sensible data model, it is a very simple question, so I will answer it with such a model.
We remove the UsersList
field from your Customer-Support table. It should never never never be there. No, really, never.
Now, assuming that, as your example data shows, every user can have one CSid, we will add a field CSid
to your User Table. This is called a foreign key. Since, as you mention, not all users are linked to the CS Table, you make sure the field allows NULL
values.
Now we fill in the data:
User table
UserId Username CSid
1 User1 1
2 User2 2
3 User3 1
4 User4 NULL
17 User17 3
18 User18 3
20 User20 3
And now, to answer your question:
SELECT * FROM UserTable WHERE CSid IS NULL;
Your question is a very good example why it pays to think about your data model before messing it up. Your query is extremely simple, if your data model makes sense.