Home » SQL & PL/SQL » SQL & PL/SQL » insert new rows / update existing columns
insert new rows / update existing columns [message #191689] Thu, 07 September 2006 14:41 Go to next message
basirana
Messages: 25
Registered: July 2006
Junior Member
hi

I have two tables

CREATE TABLE TB_APPLICATION_DEMO
(
APPLICATION_CODE NUMBER,
CORP_CODE VARCHAR2(10 BYTE)
)

and

CREATE TABLE TB_APPLICATION_DEMO_REPORT
(
APPLICATION_CODE NUMBER,
CORP_CODE VARCHAR2(10 BYTE)
)

Data will look like this

APPLICATION_CODE CORP_CODE
1 100
1 200
1 300
2 100
3 200
2 200
3 100

I need help to pull data from TB_APPLICATION_DEMO to TB_APPLICATION_DEMO_REPORT

data should be inserted TB_APPLICATION_DEMO_REPORT like below
APPLICATION_CODE CORP_CODE
1 100,200,300
2 100,200
3 100,200

please help me in writing pl/sql which can perform this task

Thanks

Re: insert new rows / update existing columns [message #191691 is a reply to message #191689] Thu, 07 September 2006 15:18 Go to previous message
joy_division
Messages: 4644
Registered: February 2005
Location: East Coast USA
Senior Member
Search the board for pivot.
Previous Topic: FUNCTION-BASE INDEX for user defined function
Next Topic: accessing database using Oracle SES
Goto Forum:
  


Current Time: Fri Dec 09 17:30:58 CST 2016

Total time taken to generate the page: 0.33978 seconds