Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 8
Default If statement 08/20/09

Can someone help?

I have a workbook with 2 spreadsheets. 1 sheet is data and the other is the
report.

Both sheets have Rig no., Income and Expense Columns. I want a formula in
the report spreadsheet, to go to data spreadsheet and get corresponding
Income and/or Expense amount to corresponding Rig no; because same rig no.
may be listed several times on the report spreadsheet.

Thanks,
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 8,520
Default If statement 08/20/09

Take a look at the worksheet function VLOOKUP() which searches for a value in
the first column of a table array and returns a value in the same row from
another column in the table array.

Syntax is
=VLOOKUP(lookup_value,table_array,col_index_num,ra nge_lookup)

OR
=VLOOKUP(A1,Shee2!A1:D100,4,0)
(This formula if applied in Sheet1 cell B1 will search the value of Sheet1
A1 in Sheet2 A1:A100 and returns the matching value from Column D (4) of
sheet2)


If this post helps click Yes
---------------
Jacob Skaria


"Angie G." wrote:

Can someone help?

I have a workbook with 2 spreadsheets. 1 sheet is data and the other is the
report.

Both sheets have Rig no., Income and Expense Columns. I want a formula in
the report spreadsheet, to go to data spreadsheet and get corresponding
Income and/or Expense amount to corresponding Rig no; because same rig no.
may be listed several times on the report spreadsheet.

Thanks,

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2,276
Default If statement 08/20/09

Hi,
if I didn't misunderstood you have in column A the rig number and you want
to summarize from the sheet called data if information start in row 2 and you
have your incomes in column B and expenses in column C in the report column B
enter

=sumproduct(--(A2=data!$A$1:$A$1000),data!$B$1:$B$1000)

in column C you will enter

=sumproduct(--(A2=data!$A$1:$A$1000),data!$c$1:$c$1000)

change range to fit your needs but remember both sides of the formula need
the same range


"Angie G." wrote:

Can someone help?

I have a workbook with 2 spreadsheets. 1 sheet is data and the other is the
report.

Both sheets have Rig no., Income and Expense Columns. I want a formula in
the report spreadsheet, to go to data spreadsheet and get corresponding
Income and/or Expense amount to corresponding Rig no; because same rig no.
may be listed several times on the report spreadsheet.

Thanks,

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 8
Default If statement 08/20/09

Eduardo,

I don't want to summarize. On the data spreadsheet, rig no is only listed
once, on the report spreadsheet it can be listed more than once. *(see
example below)I just want to be able to put a formula in the report
spreadsheet income cell - to go to the data spreadsheet - to look in col A
being the rig no. column, if in the income column (col b)has an amount to
copy to report cell.

Example below:

Data sheet - entered manually.
Col A Col B Col C
Rig # Income Expense
4 1000 500

Report Sheet

Col A Col B Col C Col D Col E
Rig # Income Expense xxxx xxxx
4 *
4
5
5
6
6

Hope this makes better sense. Thanks for all your help.




"Eduardo" wrote:

Hi,
if I didn't misunderstood you have in column A the rig number and you want
to summarize from the sheet called data if information start in row 2 and you
have your incomes in column B and expenses in column C in the report column B
enter

=sumproduct(--(A2=data!$A$1:$A$1000),data!$B$1:$B$1000)

in column C you will enter

=sumproduct(--(A2=data!$A$1:$A$1000),data!$c$1:$c$1000)

change range to fit your needs but remember both sides of the formula need
the same range


"Angie G." wrote:

Can someone help?

I have a workbook with 2 spreadsheets. 1 sheet is data and the other is the
report.

Both sheets have Rig no., Income and Expense Columns. I want a formula in
the report spreadsheet, to go to data spreadsheet and get corresponding
Income and/or Expense amount to corresponding Rig no; because same rig no.
may be listed several times on the report spreadsheet.

Thanks,

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Embedding an OR statement in an IF statement efficiently Chatnoir11 Excel Discussion (Misc queries) 4 February 2nd 09 08:12 PM
If statement or lookup statement not sure Renegade40 Excel Worksheet Functions 2 January 18th 09 06:11 AM
Can an If statement answer an If statement? M.A.Tyler Excel Discussion (Misc queries) 2 June 24th 07 04:14 AM
appending and IF statement to an existing IF statement spence Excel Worksheet Functions 1 February 28th 06 11:00 PM
If statement and Isblank statement Rodney C. Excel Worksheet Functions 0 January 18th 05 08:39 PM


All times are GMT +1. The time now is 07:52 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"