Identify Every 7th Row

WONGMEISTER

Board Regular
Joined
Jun 15, 2002
Messages
107
I have a list of records in an Excel. I'm trying to create a column that will identify every 7th record. I have a column named "RecNo" that begins at 1 and goes all the way to 20,000 that I can use in my formula.

Thanks.
 

Excel Facts

Bring active cell back into view
Start at A1 and select to A9999 while writing a formula, you can't see A1 anymore. Press Ctrl+Backspace to bring active cell into view.
I have a list of records in an Excel. I'm trying to create a column that will identify every 7th record. I have a column named "RecNo" that begins at 1 and goes all the way to 20,000 that I can use in my formula.

Thanks.
Do you mean you want to EXTRACT every 7th record?

How about giving us the first few cell addresses of the records to extract so we can see the pattern.

Also tell us where you want the records extracted to.
 
Upvote 0
Yes. Sorry, I meant extract.

My data consists of three columns: [RecNo], [File Name] and [DOR]. Row 1 contains these headings. The data begins at A2 and continues to A20000. The value of A1 is 1, A3 is 2, A4 is 3, A5 is 4, etc.

Thanks.
 
Upvote 0
One way to do it would be to create another column and the value in the first cell of this column would be 7. Then in the next cell down add 7 to the first cell then in the next cell down add 7 to that result, etc etc. So that you have something like this.

<TABLE style="WIDTH: 48pt; BORDER-COLLAPSE: collapse" border=0 cellSpacing=0 cellPadding=0 width=64><COLGROUP><COL style="WIDTH: 48pt" width=64><TBODY><TR style="HEIGHT: 15pt" height=20><TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; BACKGROUND-COLOR: transparent; WIDTH: 48pt; HEIGHT: 15pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0" height=20 width=64 align=right>7</TD></TR><TR style="HEIGHT: 15pt" height=20><TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; BACKGROUND-COLOR: transparent; HEIGHT: 15pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0" height=20 align=right>14</TD></TR><TR style="HEIGHT: 15pt" height=20><TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; BACKGROUND-COLOR: transparent; HEIGHT: 15pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0" height=20 align=right>21</TD></TR>

<TR style="HEIGHT: 15pt" height=20><TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; BACKGROUND-COLOR: transparent; HEIGHT: 15pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0" id=td_post_2850996 height=20 align=right>28</TD></TR><TR style="HEIGHT: 15pt" height=20><TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; BACKGROUND-COLOR: transparent; HEIGHT: 15pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0" height=20 align=right>35</TD></TR><TR style="HEIGHT: 15pt" height=20><TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; BACKGROUND-COLOR: transparent; HEIGHT: 15pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0" height=20 align=right>42</TD></TR>

<TR style="HEIGHT: 15pt" height=20><TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; BACKGROUND-COLOR: transparent; HEIGHT: 15pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0" height=20 align=right>49</TD></TR><TR style="HEIGHT: 15pt" height=20><TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; BACKGROUND-COLOR: transparent; HEIGHT: 15pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0" height=20 align=right>56</TD></TR></TBODY></TABLE>

use a lookup function =VLOOKUP(D1,$A$1:$B$8,2,FALSE)

substitute the beginning of your table in a1 and the end or your table for b8. This is your lookup array, Note how many columns it has. In my example there are 2. So when it comes to the value 7 in my lookup value finds 7 in the lookup array it will give me whatever's in the second column.

Your rec# must be the first column of your lookup array. The value False is an optional parameter that tells the lookup function you only want the values for 7,14,21,28 etc. Otherwise you might get values you're not looking for.
 
Upvote 0
Yes. Sorry, I meant extract.

My data consists of three columns: [RecNo], [File Name] and [DOR]. Row 1 contains these headings. The data begins at A2 and continues to A20000. The value of A1 is 1, A3 is 2, A4 is 3, A5 is 4, etc.

Thanks.
Let's try this...

Suppose this is your data:

Book1
A
1Column Header
2Data
3Data
4Data
5Data
6Data
7Data
8Data
9Data
10Data
11Data
12Data
13Data
14Data
15Data
16Data
17Data
18Data
19Data
20Data
21Data
22Data
23Data
24Data
25Data
26Data
27Data
28Data
29Data
30Data
31Data
32Data
33Data
34Data
35Data
Sheet1

Tell us which cells you want to extract and where you want it to appear.
 
Upvote 0
I know you have the solution now, but I thought i'd give you my idea.
Enter this in cell B1. It will extract every 7th record to that cell.

=IF(MOD(ROW(),7)=0,A1,"")
 
Upvote 0

Forum statistics

Threads
1,224,598
Messages
6,179,822
Members
452,946
Latest member
JoseDavid

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
Back
Top