Write a query to genarate target column.Please answer me.
Advance Thanks.
Src Tgt
Q10 Quarter to 2010
Q90 Quarter to 1990
Q80 Quarter to 1980
Q74 Quarter to 1974
Answer Posted / megha
select
'Quarter to '||to_char((to_date('01/01/'||substr(Src,2), 'dd/mm/rrrr')),'rrrr') as "Target"
from table
Is This Answer Correct ? | 9 Yes | 4 No |
Post New Answer View All Answers
Is foreign key mandatory?
What is sql server and ase?
what are the nonstandard string types? : Sql dba
What are primary key and foreign key and how they work?
What does sql stand for?
What are the two characteristics of a primary key?
Why we use cross join?
Can a foreign key have a different name?
How to connect a sql*plus session to an oracle server?
How can we implement rollback or commit statement in a trigger?
Which nosql database is best?
what is index? : Sql dba
what are the security recommendations while using mysql? : Sql dba
what is the difference between truncate and drop statements? : Sql dba
What is spool?