To display details of employees with the text "Not given" when the commission is null, you can use the following SQL query:
```sql
SELECT employee_id, first_name, last_name, hire_date, commission_pct
FROM employees
WHERE commission_pct IS NULL
AND commission_pct = 'Not given';
```
This query selects the employee_id, first_name, last_name, hire_date, and commission_pct columns from the employees table. The WHERE clause filters the results to only include rows where the commission_pct is null and also equal to the text "Not given".
Write a query to display details of employees with the text “Not given”, if the commission is null
1 answer