identifying first non-zero value in multiple rows

Newport Count

Active Member
Joined
Oct 25, 2009
Messages
326
Hi,

I am trying to display data from several rows onto a single row - the first single row for that chunk of data.


Example (sorry about the format):

columnA columnB columnC columnD columnE
batch line item no. value desired outcome1 desired outcome2
35 1 0 55 15
35 2 55
35 3 15

57 1 0 12.5
57 2 0
57 3 12.5

88 1 0 blank

91 1 0 blank


Batches are listed in a spreadsheet in numeric order and a blank row exists between each one, where no data exists.

Potentially, each data set (batch) could contain several line items....but only some have values.


Ideally, I would like to list these values in column D (and in column E, if more than one exist)


I can't work out how to search for a non-zero value and display it, and then also stop when a blank value (blank row that separates batches) is found.


Any ideas?


Cheers,
Rich
 

Some videos you may like

Excel Facts

Save Often
If you start asking yourself if now is a good time to save your Excel workbook, the answer is Yes

Newport Count

Active Member
Joined
Oct 25, 2009
Messages
326
sorry that looks terrible - I can't work out how to add an image or spreadsheet

hope you can work it out
 

Watch MrExcel Video

Forum statistics

Threads
1,127,898
Messages
5,627,526
Members
416,250
Latest member
darius_rebelo

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top