GeekInterview.com
   Home |  Tech FAQ  |   Interview Questions |  Placement Papers |  Tech Articles |  Learn |  Freelance Projects |  Online Testing |  Geeks Talk |  Job Postings |  Knowledge Base | Site Search |  Add/Ask Question

  GeekInterview.com  >  Interview Questions  >  Oracle  >  SQL

 Print  |  
Question:  Replace and Translate

Answer: How and in what way REPLACE is different from TRANSLATE?


July 07, 2008 04:24:41 #2
 suresh.kurapati11   Member Since: July 2008    Total Comments: 2 

RE: Replace and Translate
 
REPLACE: It is used to replaces the value,without giving the alternative letter or word.

Ex:1. select replace(ename,'S') from emp;
     2.select replace(ename,'S','A') from emp;

TRANSLATE: Here you must apply the with replace value,instead of giving value

Ex: select translate(ename,'S','A') from emp;
     

 

Back To Question