Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Need to combine the two table to get the Sales person details according to EMP id

Hi ALL,

I need combine the two table and need to display the data based on sales person ,Please find the table details below

2014:

LOAD

    EmployeeID as EMPID%,

    SalesPerson,

    "Year",----->Contain only 2014 year

    Quater,---->Contain Q1,Q2,Q3,Q4

    Sales

FROM [lib://source/Quota.qvd]

(qvd);

2015:

Load * Resident 2014;

LOAD

    EmployeeID as [EMPID%],

    "Year",---->2015 as year

    Quater ,---->Contain Q1,Q2,Q3,Q4

    Sales

FROM [lib://source/Quota1.qvd]

(qvd);

Drop Table 2014;

in 2014 table it is having sales Person name related to the EMPID and i need  the same in 2015 to display the sales person name,

Kindly let me know how we can achieve.

1 Solution

Accepted Solutions
OmarBenSalem

Try this:

MapTable:

Mapping Load EmployeeID,

SalesPerson from

[lib://source/Quota.qvd]

(qvd);

2014:

LOAD

    EmployeeID as EMPID%,

    SalesPerson,

    "Year",----->Contain only 2014 year

    Quater,---->Contain Q1,Q2,Q3,Q4

    Sales

FROM [lib://source/Quota.qvd]

(qvd);

2015:

LOAD

    EmployeeID as [EMPID%],

ApplyMap('MapTable',EmployeeID) as SalesPerson

    "Year",---->2015 as year

    Quater ,---->Contain Q1,Q2,Q3,Q4

    Sales

FROM [lib://source/Quota1.qvd]

(qvd);

View solution in original post

2 Replies
OmarBenSalem

Try this:

MapTable:

Mapping Load EmployeeID,

SalesPerson from

[lib://source/Quota.qvd]

(qvd);

2014:

LOAD

    EmployeeID as EMPID%,

    SalesPerson,

    "Year",----->Contain only 2014 year

    Quater,---->Contain Q1,Q2,Q3,Q4

    Sales

FROM [lib://source/Quota.qvd]

(qvd);

2015:

LOAD

    EmployeeID as [EMPID%],

ApplyMap('MapTable',EmployeeID) as SalesPerson

    "Year",---->2015 as year

    Quater ,---->Contain Q1,Q2,Q3,Q4

    Sales

FROM [lib://source/Quota1.qvd]

(qvd);

Anonymous
Not applicable
Author

Thank You So much omar,It is working Fine

Need to Know,Whether is there any other way to do this.