missymassy86
New Member
- Joined
- Apr 8, 2012
- Messages
- 2
Hi,
I am not proficient with Excels and I have a problem with finding a formula for this situation where I have extract data from another worksheet for the budget sheet. I have a few similar criterias and probably 2 or 3 of the criterias may be the same. What formula should i use to extract the data from worksheet 2 to worksheet 1? This will be updated periodically. However, some of the information in worksheet 2, i may not need them.
Someone please help me, I have been trying to figure it out for the past 4 days. Thank you very much!!
Sample from worksheet 1:
<table style="width: 630px; height: 236px;" border="0" cellpadding="0" cellspacing="0"><colgroup><col style="width:48pt" span="6" width="64"> <col style="mso-width-source:userset;mso-width-alt:2596;width:53pt" width="71"> </colgroup><tbody><tr style="height:27.0pt" height="36"> <td class="xl68" style="height:27.0pt;width:48pt" height="36" width="64">Product</td> <td class="xl68" style="border-left:none;width:48pt" width="64">Country</td> <td class="xl68" style="border-left:none;width:48pt" width="64">Account code</td> <td class="xl68" style="border-left:none;width:48pt" width="64">Activity Code</td> <td class="xl74" style="border-left:none;width:48pt" width="64">Jan</td> <td class="xl74" style="border-left:none;width:48pt" width="64">Feb</td> <td class="xl74" style="border-left:none;width:53pt" width="71">March</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl69" style="height:15.0pt" height="20">54303</td> <td class="xl69">Canada</td> <td class="xl71" style="width:48pt" width="64">Marketing
</td> <td class="xl72">123456</td> <td>
</td> <td>
</td> <td>
</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl69" style="height:15.0pt" height="20">54303</td> <td class="xl69">India</td> <td class="xl71" style="width:48pt" width="64">Marketing</td> <td class="xl72">100005</td> <td>
</td> <td>
</td> <td>
</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl80" style="height:15.0pt" height="20">54314</td> <td class="xl80">Thailand</td> <td class="xl81" style="width:48pt" width="64">Marketing</td> <td class="xl82">100005</td> <td>
</td> <td>
</td> <td>
</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl80" style="height:15.0pt" height="20">54314</td> <td class="xl80">Thailand</td> <td class="xl81" style="width:48pt" width="64">Marketing</td> <td class="xl82">100003</td> <td>
</td> <td>
</td> <td>
</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl70" style="height:15.0pt" height="20">71762</td> <td class="xl67" style="width:48pt" width="64">GCC</td> <td class="xl71" style="width:48pt" width="64">Marketing</td> <td class="xl73">234567</td> <td>
</td> <td>
</td> <td>
</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl75" style="height:15.0pt" height="20">71762</td> <td class="xl76" style="width:48pt" width="64">China</td> <td class="xl77" style="width:48pt" width="64">Marketing</td> <td class="xl78">234567</td> <td>
</td> <td>
</td> <td>
</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl75" style="height:15.0pt" height="20">71762</td> <td class="xl76" style="width:48pt" width="64">China</td> <td class="xl77" style="width:48pt" width="64">Marketing</td> <td class="xl78">234567</td> <td>
</td> <td>
</td> <td>
</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl75" style="height:15.0pt" height="20">71762</td> <td class="xl75">China</td> <td class="xl77" style="width:48pt" width="64">Marketing</td> <td class="xl79">411306</td> <td>
</td> <td>
</td> <td>
</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl70" style="height:15.0pt" height="20">71762</td> <td class="xl70">Japan</td> <td class="xl71" style="width:48pt" width="64">Fees</td> <td class="xl73">234567</td> <td>
</td> <td>
</td> <td>
</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl70" style="height:15.0pt" height="20">71762</td> <td class="xl70">Japan</td> <td class="xl71" style="width:48pt" width="64">Fees</td> <td class="xl73">234567</td> <td>
</td> <td>
</td> <td>
</td> </tr> </tbody></table>
-- removed inline image ---
2nd worksheet:
<table style="width: 635px; height: 328px;" border="0" cellpadding="0" cellspacing="0"><colgroup><col style="width:48pt" span="7" width="64"> </colgroup><tbody><tr style="height:27.0pt" height="36"> <td class="xl69" style="height:27.0pt;width:48pt" height="36" width="64">Product</td> <td class="xl69" style="border-left:none;width:48pt" width="64">Geography</td> <td class="xl69" style="border-left:none;width:48pt" width="64">Country</td> <td class="xl69" style="border-left:none;width:48pt" width="64">Account code</td> <td class="xl69" style="border-left:none;width:48pt" width="64">Activity Code</td> <td class="xl68" style="border-left:none;width:48pt" width="64">Month</td> <td class="xl68" style="border-left:none;width:48pt" width="64">Amount</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl70" style="height:15.0pt" height="20">54303</td> <td class="xl71">No Country</td> <td class="xl70">Canada</td> <td class="xl72" style="width:48pt" width="64">Marketing</td> <td class="xl73">123456</td> <td class="xl75" align="right">Jan-12</td> <td class="xl76" align="right">$54,632</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl70" style="height:15.0pt" height="20">54303</td> <td class="xl71">India</td> <td class="xl70">India</td> <td class="xl72" style="width:48pt" width="64">Marketing</td> <td class="xl73">100005</td> <td class="xl75" align="right">Jan-12</td> <td class="xl76" align="right">$58,944</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl70" style="height:15.0pt" height="20">54314</td> <td class="xl71">Thailand</td> <td class="xl70">Thailand</td> <td class="xl72" style="width:48pt" width="64">Marketing</td> <td class="xl73">100005</td> <td class="xl75" align="right">Jan-12</td> <td class="xl76" align="right">$89,022</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl71" style="height:15.0pt" height="20">71762</td> <td class="xl71">GCC</td> <td class="xl67" style="width:48pt" width="64">GCC</td> <td class="xl72" style="width:48pt" width="64">Marketing</td> <td class="xl74">234567</td> <td class="xl75" align="right">Jan-12</td> <td class="xl76" align="right">$53,000</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl71" style="height:15.0pt" height="20">71762</td> <td class="xl71">China</td> <td class="xl67" style="width:48pt" width="64">China</td> <td class="xl72" style="width:48pt" width="64">Marketing</td> <td class="xl74">234567</td> <td class="xl75" align="right">Jan-12</td> <td class="xl76" align="right">$98,700</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl71" style="height:15.0pt" height="20">71762</td> <td class="xl71">No Country</td> <td class="xl67" style="width:48pt" width="64">London</td> <td class="xl72" style="width:48pt" width="64">Marketing</td> <td class="xl74">234567</td> <td class="xl75" align="right">Jan-12</td> <td class="xl76" align="right">$89,555</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl71" style="height:15.0pt" height="20">71762</td> <td class="xl71">China</td> <td class="xl67" style="width:48pt" width="64">China</td> <td class="xl72" style="width:48pt" width="64">Marketing</td> <td class="xl74">234567</td> <td class="xl75" align="right">Jan-12</td> <td class="xl76" align="right">$32,000</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl71" style="height:15.0pt" height="20">71762</td> <td class="xl71">Africa</td> <td class="xl67" style="width:48pt" width="64">Africa</td> <td class="xl72" style="width:48pt" width="64">Marketing</td> <td class="xl73">234567</td> <td class="xl75" align="right">Jan-12</td> <td class="xl76" align="right">$52,348</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl71" style="height:15.0pt" height="20">71762</td> <td class="xl71">China</td> <td class="xl71">China</td> <td class="xl72" style="width:48pt" width="64">Marketing</td> <td class="xl73">234568</td> <td class="xl75" align="right">Jan-12</td> <td class="xl76" align="right">$9,873</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl71" style="height:15.0pt" height="20">71762</td> <td class="xl71">Japan</td> <td class="xl71">Japan</td> <td class="xl72" style="width:48pt" width="64">Fees</td> <td class="xl74">234567</td> <td class="xl75" align="right">Jan-12</td> <td class="xl76" align="right">$85,222</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl71" style="height:15.0pt" height="20">71762</td> <td class="xl71">Japan</td> <td class="xl71">Japan</td> <td class="xl72" style="width:48pt" width="64">Fees</td> <td class="xl74">234567</td> <td class="xl75" align="right">Jan-12</td> <td class="xl76" align="right">$96,633</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl70" style="height:15.0pt" height="20">54303</td> <td class="xl71">US</td> <td class="xl71">US</td> <td class="xl72" style="width:48pt" width="64">Fees</td> <td class="xl74">234568</td> <td class="xl75" align="right">Jan-12</td> <td class="xl76" align="right">$96,000</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl70" style="height:15.0pt" height="20">54303</td> <td class="xl71">US</td> <td class="xl71">US</td> <td class="xl72" style="width:48pt" width="64">Fees</td> <td class="xl74">234569</td> <td class="xl75" align="right">Jan-12</td> <td class="xl76" align="right">$88,000</td> </tr> </tbody></table>
Example
I'm using this formual instead of a vlookup as followed but apparently, it doesn't work for me.
=IF(ROWS($K$2:K2)>Count!$F2,"",INDEX('worksheet 2'!AB2:AB37,SMALL(IF(Worksheet 1!$B2&Worksheet1!$F2&Worksheet 1!$D2&Actuals!$E2='Worksheet 2'!$O$2:$O$37&'Worksheet 2'!$R$2:$R$37&'Worksheet 2'!$U$2:$U$37&'Worksheet 2'!$AC$2:$AC$37,ROW('Worksheet 2'!$AB$2:$AB$37)-ROW('Worksheet 2'!$AB$2)+1),ROWS(Worksheet 1!$K2:K2))))
I am not proficient with Excels and I have a problem with finding a formula for this situation where I have extract data from another worksheet for the budget sheet. I have a few similar criterias and probably 2 or 3 of the criterias may be the same. What formula should i use to extract the data from worksheet 2 to worksheet 1? This will be updated periodically. However, some of the information in worksheet 2, i may not need them.
Someone please help me, I have been trying to figure it out for the past 4 days. Thank you very much!!
Sample from worksheet 1:
<table style="width: 630px; height: 236px;" border="0" cellpadding="0" cellspacing="0"><colgroup><col style="width:48pt" span="6" width="64"> <col style="mso-width-source:userset;mso-width-alt:2596;width:53pt" width="71"> </colgroup><tbody><tr style="height:27.0pt" height="36"> <td class="xl68" style="height:27.0pt;width:48pt" height="36" width="64">Product</td> <td class="xl68" style="border-left:none;width:48pt" width="64">Country</td> <td class="xl68" style="border-left:none;width:48pt" width="64">Account code</td> <td class="xl68" style="border-left:none;width:48pt" width="64">Activity Code</td> <td class="xl74" style="border-left:none;width:48pt" width="64">Jan</td> <td class="xl74" style="border-left:none;width:48pt" width="64">Feb</td> <td class="xl74" style="border-left:none;width:53pt" width="71">March</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl69" style="height:15.0pt" height="20">54303</td> <td class="xl69">Canada</td> <td class="xl71" style="width:48pt" width="64">Marketing
</td> <td class="xl72">123456</td> <td>
</td> <td>
</td> <td>
</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl69" style="height:15.0pt" height="20">54303</td> <td class="xl69">India</td> <td class="xl71" style="width:48pt" width="64">Marketing</td> <td class="xl72">100005</td> <td>
</td> <td>
</td> <td>
</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl80" style="height:15.0pt" height="20">54314</td> <td class="xl80">Thailand</td> <td class="xl81" style="width:48pt" width="64">Marketing</td> <td class="xl82">100005</td> <td>
</td> <td>
</td> <td>
</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl80" style="height:15.0pt" height="20">54314</td> <td class="xl80">Thailand</td> <td class="xl81" style="width:48pt" width="64">Marketing</td> <td class="xl82">100003</td> <td>
</td> <td>
</td> <td>
</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl70" style="height:15.0pt" height="20">71762</td> <td class="xl67" style="width:48pt" width="64">GCC</td> <td class="xl71" style="width:48pt" width="64">Marketing</td> <td class="xl73">234567</td> <td>
</td> <td>
</td> <td>
</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl75" style="height:15.0pt" height="20">71762</td> <td class="xl76" style="width:48pt" width="64">China</td> <td class="xl77" style="width:48pt" width="64">Marketing</td> <td class="xl78">234567</td> <td>
</td> <td>
</td> <td>
</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl75" style="height:15.0pt" height="20">71762</td> <td class="xl76" style="width:48pt" width="64">China</td> <td class="xl77" style="width:48pt" width="64">Marketing</td> <td class="xl78">234567</td> <td>
</td> <td>
</td> <td>
</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl75" style="height:15.0pt" height="20">71762</td> <td class="xl75">China</td> <td class="xl77" style="width:48pt" width="64">Marketing</td> <td class="xl79">411306</td> <td>
</td> <td>
</td> <td>
</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl70" style="height:15.0pt" height="20">71762</td> <td class="xl70">Japan</td> <td class="xl71" style="width:48pt" width="64">Fees</td> <td class="xl73">234567</td> <td>
</td> <td>
</td> <td>
</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl70" style="height:15.0pt" height="20">71762</td> <td class="xl70">Japan</td> <td class="xl71" style="width:48pt" width="64">Fees</td> <td class="xl73">234567</td> <td>
</td> <td>
</td> <td>
</td> </tr> </tbody></table>
-- removed inline image ---
2nd worksheet:
<table style="width: 635px; height: 328px;" border="0" cellpadding="0" cellspacing="0"><colgroup><col style="width:48pt" span="7" width="64"> </colgroup><tbody><tr style="height:27.0pt" height="36"> <td class="xl69" style="height:27.0pt;width:48pt" height="36" width="64">Product</td> <td class="xl69" style="border-left:none;width:48pt" width="64">Geography</td> <td class="xl69" style="border-left:none;width:48pt" width="64">Country</td> <td class="xl69" style="border-left:none;width:48pt" width="64">Account code</td> <td class="xl69" style="border-left:none;width:48pt" width="64">Activity Code</td> <td class="xl68" style="border-left:none;width:48pt" width="64">Month</td> <td class="xl68" style="border-left:none;width:48pt" width="64">Amount</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl70" style="height:15.0pt" height="20">54303</td> <td class="xl71">No Country</td> <td class="xl70">Canada</td> <td class="xl72" style="width:48pt" width="64">Marketing</td> <td class="xl73">123456</td> <td class="xl75" align="right">Jan-12</td> <td class="xl76" align="right">$54,632</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl70" style="height:15.0pt" height="20">54303</td> <td class="xl71">India</td> <td class="xl70">India</td> <td class="xl72" style="width:48pt" width="64">Marketing</td> <td class="xl73">100005</td> <td class="xl75" align="right">Jan-12</td> <td class="xl76" align="right">$58,944</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl70" style="height:15.0pt" height="20">54314</td> <td class="xl71">Thailand</td> <td class="xl70">Thailand</td> <td class="xl72" style="width:48pt" width="64">Marketing</td> <td class="xl73">100005</td> <td class="xl75" align="right">Jan-12</td> <td class="xl76" align="right">$89,022</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl71" style="height:15.0pt" height="20">71762</td> <td class="xl71">GCC</td> <td class="xl67" style="width:48pt" width="64">GCC</td> <td class="xl72" style="width:48pt" width="64">Marketing</td> <td class="xl74">234567</td> <td class="xl75" align="right">Jan-12</td> <td class="xl76" align="right">$53,000</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl71" style="height:15.0pt" height="20">71762</td> <td class="xl71">China</td> <td class="xl67" style="width:48pt" width="64">China</td> <td class="xl72" style="width:48pt" width="64">Marketing</td> <td class="xl74">234567</td> <td class="xl75" align="right">Jan-12</td> <td class="xl76" align="right">$98,700</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl71" style="height:15.0pt" height="20">71762</td> <td class="xl71">No Country</td> <td class="xl67" style="width:48pt" width="64">London</td> <td class="xl72" style="width:48pt" width="64">Marketing</td> <td class="xl74">234567</td> <td class="xl75" align="right">Jan-12</td> <td class="xl76" align="right">$89,555</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl71" style="height:15.0pt" height="20">71762</td> <td class="xl71">China</td> <td class="xl67" style="width:48pt" width="64">China</td> <td class="xl72" style="width:48pt" width="64">Marketing</td> <td class="xl74">234567</td> <td class="xl75" align="right">Jan-12</td> <td class="xl76" align="right">$32,000</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl71" style="height:15.0pt" height="20">71762</td> <td class="xl71">Africa</td> <td class="xl67" style="width:48pt" width="64">Africa</td> <td class="xl72" style="width:48pt" width="64">Marketing</td> <td class="xl73">234567</td> <td class="xl75" align="right">Jan-12</td> <td class="xl76" align="right">$52,348</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl71" style="height:15.0pt" height="20">71762</td> <td class="xl71">China</td> <td class="xl71">China</td> <td class="xl72" style="width:48pt" width="64">Marketing</td> <td class="xl73">234568</td> <td class="xl75" align="right">Jan-12</td> <td class="xl76" align="right">$9,873</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl71" style="height:15.0pt" height="20">71762</td> <td class="xl71">Japan</td> <td class="xl71">Japan</td> <td class="xl72" style="width:48pt" width="64">Fees</td> <td class="xl74">234567</td> <td class="xl75" align="right">Jan-12</td> <td class="xl76" align="right">$85,222</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl71" style="height:15.0pt" height="20">71762</td> <td class="xl71">Japan</td> <td class="xl71">Japan</td> <td class="xl72" style="width:48pt" width="64">Fees</td> <td class="xl74">234567</td> <td class="xl75" align="right">Jan-12</td> <td class="xl76" align="right">$96,633</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl70" style="height:15.0pt" height="20">54303</td> <td class="xl71">US</td> <td class="xl71">US</td> <td class="xl72" style="width:48pt" width="64">Fees</td> <td class="xl74">234568</td> <td class="xl75" align="right">Jan-12</td> <td class="xl76" align="right">$96,000</td> </tr> <tr style="height:15.0pt" height="20"> <td class="xl70" style="height:15.0pt" height="20">54303</td> <td class="xl71">US</td> <td class="xl71">US</td> <td class="xl72" style="width:48pt" width="64">Fees</td> <td class="xl74">234569</td> <td class="xl75" align="right">Jan-12</td> <td class="xl76" align="right">$88,000</td> </tr> </tbody></table>
Example
I'm using this formual instead of a vlookup as followed but apparently, it doesn't work for me.
=IF(ROWS($K$2:K2)>Count!$F2,"",INDEX('worksheet 2'!AB2:AB37,SMALL(IF(Worksheet 1!$B2&Worksheet1!$F2&Worksheet 1!$D2&Actuals!$E2='Worksheet 2'!$O$2:$O$37&'Worksheet 2'!$R$2:$R$37&'Worksheet 2'!$U$2:$U$37&'Worksheet 2'!$AC$2:$AC$37,ROW('Worksheet 2'!$AB$2:$AB$37)-ROW('Worksheet 2'!$AB$2)+1),ROWS(Worksheet 1!$K2:K2))))
Last edited: