dbTalk Databases Forums  

help with VBA code

comp.databases.ms-access comp.databases.ms-access


Discuss help with VBA code in the comp.databases.ms-access forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
BFord
 
Posts: n/a

Default help with VBA code - 08-05-2003 , 07:54 PM






Using Access2000, i need help coding the SEQ field (see sample below)
TIA,
Bob

trans_id beg_date end_date seq
149 1/1/2003 12/31/2003 1
2331 1/1/2003 2/22/2003 1
2331 2/23/2003 6/28/2003 2
2331 6/29/2003 9/6/2003 3
2331 9/7/2003 12/31/2003 4
7789 1/1/2003 8/5/2003 1
7789 8/6/2003 12/31/2003 2
10003 1/1/2003 12/31/2003 1
etc...



Reply With Quote
  #2  
Old   
Art
 
Posts: n/a

Default Re: help with VBA code - 08-05-2003 , 08:55 PM






Make a query that does a Group on the Trans_Id and count of Trans_id. Then
open the query as a recordset, and loop through the recordset doing a find
by the trans_id and incrementing the SEQ (since you know the number of
records for each trans_id).
Art

"BFord" <nospam (AT) nospam (DOT) com> wrote

Quote:
Using Access2000, i need help coding the SEQ field (see sample below)
TIA,
Bob

trans_id beg_date end_date seq
149 1/1/2003 12/31/2003 1
2331 1/1/2003 2/22/2003 1
2331 2/23/2003 6/28/2003 2
2331 6/29/2003 9/6/2003 3
2331 9/7/2003 12/31/2003 4
7789 1/1/2003 8/5/2003 1
7789 8/6/2003 12/31/2003 2
10003 1/1/2003 12/31/2003 1
etc...





Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.