Create LineNum by HdrNum in a conversion effort (1 Viewer)

feinj

OracLegend
Local time
Today, 05:48
Joined
Oct 17, 2007
Messages
42
I am in desperate need of some help here.

I have a situation where I must convert data in an existing access database for use in a new database. The existing data has multiple line entries for the same header number, but has not identified each of those line entries with a line number.

I need to create a query that will automatically create the line number for each line entry, to restart at number 1 each time the header number changes.

I would greatly appreciate any help with this problem.

I have uploaded a small example of the data.

Thanks in advance for your help.
 

Attachments

  • Line Numbering Example.xls
    16 KB · Views: 103

pbaldy

Wino Moderator
Staff member
Local time
Today, 05:48
Joined
Aug 30, 2003
Messages
36,140
Search on "ranking" and you should find two general techniques: subquery or DCount. Either would use a criteria that matched HdrNum and counted ID <= the current value.
 

Users who are viewing this thread

Top Bottom