Which query would give the required output?

You need to display the first names of all customers from the CUSTOMERS table that contain the character ‘e’ and have the character ‘a’ in the second last position.
Which query would give the required output?
A. SELECT cust_first_nameFROM customersWHERE INSTR(cust_first_name, ‘e’)<>0 ANDSUBSTR(cust_first_name, -2, 1)=’a’;
B. SELECT cust_first_nameFROM customersWHERE INSTR(cust_first_name, ‘e’)<>” ANDSUBSTR(cust_first_name, -2, 1)=’a’;
C. SELECT cust_first_nameFROM customersWHERE INSTR(cust_first_name, ‘e’)IS NOT NULL ANDSUBSTR(cust_first_name, 1,-2)=’a’;
D. SELECT cust_first_nameFROM customersWHERE INSTR(cust_first_name, ‘e’)<>0 ANDSUBSTR(cust_first_name, LENGTH(cust_first_name),-2) =’a’;

Download Printable PDF. VALID exam to help you PASS.

Leave a Reply

Your email address will not be published. Required fields are marked *


The reCAPTCHA verification period has expired. Please reload the page.