Q. The Doc_name Column of a table Hospital is given below:

 

Doc_name

Avinash

Hariharan

Vinayak

Deepak

Sanjeev

 

Based on the information, find the output of the following queries:

(i) SELECT doc_name FROM HOSPITAL WHERE Doc_name like "%v";

(ii) SELECT dcc_name FROM HOSPITAL WHERE doc_name like "%e%";

 

Answer =

 

(a)

Doc_name

Sanjeev

(b)

Doc_name

Deepak

Sanjeev

9 Comments

You can help us by Clicking on ads. ^_^
Please do not send spam comment : )

  1. Please tell me if it was like "%e" what could be the output,? as it does match with any name...

    ReplyDelete
    Replies
    1. it give the Name which end with latter 'e' . : )

      Delete
    2. It would give an empty set

      Delete
  2. what if it said "e%"? will it show the name with the beginning letter as e?

    ReplyDelete
  3. Actually, it meant by the fact that the name ended with letter 'e' :-)

    ReplyDelete
  4. What if it was %a

    ReplyDelete
    Replies
    1. It will give output with the name ending with character a.

      Delete

Post a Comment

You can help us by Clicking on ads. ^_^
Please do not send spam comment : )

Previous Post Next Post