[August 2019] OCP 071 certification exams test the latest version of the original title - Article 31 title

Choose two

Examine the data in the CUST NAME column of the CUSTOMERS table:

CUST_NAME


Renske Ladwig

Jason model

Samuel McCain

Allan MCEwen

Irene Mikkilä

Julia Nayer

You want to display the CUST_NAME values where the last name starts with Mc or MC.

Which two WHERE clauses give the required result?

A) WHERE INITCAP (SUBSTR(cust_name, INSTR(cust_name,' ') +1 ) ) IN ('MC%', 'Mc%)

B) WHERE UPPER (SUBSTR(cust_nane, INSTR(cust_name, ' ') +1 ) ) LIKE UPPER('MC%')

C) WHERE INITCAP(SUBSTR(cust_nane, INSTR(cust_name,' ') +1 ) ) LIKE 'Mc%'

D) WHERE SUBSTR(cust_name,INSTR(cust_name,' ') +1 ) LIKE 'Mc%' OR 'MC%'

E) WHERE SUBSTR(cust_name, INSTR(cust_name,' ') +1 ) LIKE 'Mc%'

Anser:BC

(Analysis: the original 66 questions, variations of this question is more Answer: B Notice the use of substr and instr, no experimental or difficult to understand.

Answer:C

Guess you like

Origin blog.51cto.com/13854012/2451418