Regarding your first question: There are several tables in the database employees. Try to look there for information about departments. What you show in your pictures seems to be the table employees.employees.
For your second problem:
I’d suggest that you check if your second parameter value is passed in the right way. Try to find the type of the field you try to search and how the data has to be passed.