I am new to mysql and I am getting an error when trying to perform a query, I have a table with a list of employees and their salaries and I am supposed to get a list of the employees which last name ends in a vowel and apply a percent to the salary. I have searched in my book but I cannot find a solution.
SELECT concat(`fname`,' ', `lname`) as 'Full Name',
(`salary` * 0.012) as 'Tax'
WHERE (`'lname`) IN ( SELECT RIGHT(`lname`,1) as 'lLetter'
WHERE `lLeter` IN ('a', 'e', 'i', 'o', 'u'));
ORDER BY `lname`;