write sql query following table
amount year quarter
1000 2003 first
2000 2003 second
3000 2003 third
4000 2003 fourth
5000 2004 first
6000 2004 second
7000 2004 third
8000 2004 fourth

i want the output
year q1_amount q2_amount q3_amount q4_amount
2003 1000 2000 3000 4000
2004 5000 6000 7000 8000

can anybady help me to achieve the aboue result by using informatica.

thanks in advance.

Answer Posted / kamleshmishra291

SQL OVERRIDE :
SELECT * FROM TABLE_NAME PIVOT(MAX(AMOUNT) FOR QUARTER IN ('FIRST','SECOND','THIRD','FOURTH'));

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are batches?

712


Can you use flat files in Mapplets.

2312


In warehouses how many schemas are there?

676


Enlist the tasks for which source qualifier transformation is used.

669


in reporting we add some new objects,how we get the count of the newly added objects to the report

1860






hi friends ... i have insurance project(informatica),can you please tell me how many table and mappings we need to use?and explain me.. thank you

9289


How do you load unique records into one target table and duplicate records into a different target table?

828


What is update strategy transform?

696


Explain why we use partitioning the session in informatica?

683


Explain the different lookup methods used in informatica?

686


What are the prerequisite tasks to achieve the session partition?

811


Write the different tools in the workflow manager?

662


I have three same source structure tables. But, I want to load into single target table. How do I do this? Explain in detail through mapping flow.

901


In how many ways we can create ports?

799


What is workflow monitor?

695