Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Combining Rows and Columns of two sheets

Status
Not open for further replies.

FarzanaSaleem

Programmer
Jun 17, 2003
63
PK
I have an Excel workbook with 2 sheets.
Sheet1 has values from database1 in 'Row Format'.
Sheet2 has values from database2 in 'Column Format'.

Columns in Sheet1:
Emp #
Name
Basic Salary
House Rent
COLA

Columns in Sheet2:
Emp #
Name
Earning ID
Amount

Sample value for Sheet1:
1
ABC
100
200
300

Sample value for Sheet2:
Row1:
1
ABC
BS
100

Row2:
1
ABC
HR
200

Row3:
1
ABC
COLA
400

I have to combine data of these two sheets in a new sheet, Sheet3, on a single line:

Columns in Sheet3:
Emp#
Name
Basic Salary DB1
House Rent DB1
COLA DB1
BS DB2
HR DB2
COLA DB2

Sample value for Sheet2:
1
ABC
100
200
300
100
200
400

 
Anyone to help me please.

Thank you

PS: Last sample values have the heading:
Sample value for Sheet2:

It is actually:
Sample value for Sheet3:
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top