473,473 Members | 2,170 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Code to Automate Indexing -- If there is such a thing!

Hi -- I have a Data entry/sequencing problem. Any help appreciated.
Here is the scenario:

Given -- A table with the following fields and sample data:

LineNo Pri Comp Init Tgtno PMno
1 1 1 1 a 1
2 1 1 2 a 1
3 1 1 2 b 1
4 1 1 2 c 1
5 1 1 2 d 1
6 1 1 3 a 1
7 1 2 1 a 1
8 1 2 1 b 1
9 1 2 2 a 1
10 1 3 1 a 1
11 1 3 1 b 1
12 2 1 1 a 1
13 2 1 1 a 2
14 2 1 2 a 1
15 2 1 3 a 1
16 2 1 3 b 1
17 2 1 3 c 1
18 2 1 4 a 1
19 2 1 4 b 1
20 2 2 1 a 1
21 2 2 1 b 1
22 2 2 2 a 1
23 3 1 1 a 1
24 3 1 1 b 1
25 3 2 1 a 1
26 3 2 2 a 1
27 3 2 3 a 1
28 3 2 4 a 1
29 3 2 5 a 1
30 3 2 6 a 1
31 3 2 6 a 2
32 3 2 6 b 1
33 3 2 6 c 1

Problem: If you are in an edit screen at line 22 and want to add a
record. Is there a way to automate the entry so that it writes the
next logical numbering sequence -- based on the values in the next
record?

For example:
22 2 2 2 a 1
the next record values would automatically be written:
22.1 2 2 2 a 2

or if you are at line 31...

31 3 2 6 a 2
the next record would automatically be written:
31.1 3 2 6 a 3

or -- if you are on line 33 ...
33 3 2 6 c 1
Because there are no following records it should write:
34 1 1 1 a 1

I know this is not an easy problem, but any help will be greatly
appreciated.

Thanks,

RBollinger

Nov 13 '05 #1
3 1157
umm... go to www.mvps.org/access and look up something like
"incrementing the numeric portion of a string". Read, follow
instructions. Attempt to understand code. use, enjoy.

Nov 13 '05 #2
"robboll" <ro*****@hotmail.com> wrote in message
news:11*********************@z14g2000cwz.googlegro ups.com...
Hi -- I have a Data entry/sequencing problem. Any help appreciated.
Here is the scenario:

Given -- A table with the following fields and sample data:

LineNo Pri Comp Init Tgtno PMno
1 1 1 1 a 1
2 1 1 2 a 1
3 1 1 2 b 1
4 1 1 2 c 1
5 1 1 2 d 1
6 1 1 3 a 1
7 1 2 1 a 1
8 1 2 1 b 1
9 1 2 2 a 1
10 1 3 1 a 1
11 1 3 1 b 1
12 2 1 1 a 1
13 2 1 1 a 2
14 2 1 2 a 1
15 2 1 3 a 1
16 2 1 3 b 1
17 2 1 3 c 1
18 2 1 4 a 1
19 2 1 4 b 1
20 2 2 1 a 1
21 2 2 1 b 1
22 2 2 2 a 1
23 3 1 1 a 1
24 3 1 1 b 1
25 3 2 1 a 1
26 3 2 2 a 1
27 3 2 3 a 1
28 3 2 4 a 1
29 3 2 5 a 1
30 3 2 6 a 1
31 3 2 6 a 2
32 3 2 6 b 1
33 3 2 6 c 1

Problem: If you are in an edit screen at line 22 and want to add a
record. Is there a way to automate the entry so that it writes the
next logical numbering sequence -- based on the values in the next
record?

For example:
22 2 2 2 a 1
the next record values would automatically be written:
22.1 2 2 2 a 2

or if you are at line 31...

31 3 2 6 a 2
the next record would automatically be written:
31.1 3 2 6 a 3

or -- if you are on line 33 ...
33 3 2 6 c 1
Because there are no following records it should write:
34 1 1 1 a 1

I know this is not an easy problem, but any help will be greatly
appreciated.

Thanks,

RBollinger


You are right, it's not an easy problem, and you are not making it any
easier for someone to help you. Nowhere in your post do I see any clear
definition of exactly how the increments are supposed to take place.

Please take the trouble to actually define the increment pattern, and then
it will be possible to help you.
Nov 13 '05 #3
Thanks, I'll check out http://www.mvps.org/access/strings/str0007.htm

Any other approaches to this? Thanks for any suggestions.

Nov 13 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: Michael Drumheller | last post by:
(If you're not interested in NumArray, please skip this message.) I am new to NumArray and I wonder if someone can help me with array-indexing. Here's the basic situation: Given a rank-2 array...
15
by: Jay | last post by:
Hello all. I've recently transferred our web sites from a Windows2000 server to a Windows2003 server. The transfer went almost flawless until I noticed that our search function isn't working...
8
by: Craig Cockburn | last post by:
Hi I'm aware of the use of robots.txt and the use of <META NAME="ROBOTS" CONTENT="index,follow"> However, what would be more useful is to be able to control within a page which elements of...
5
by: cedric buerfent | last post by:
Hello NG, I ve a question concerning automatic generated source code. When I program the declarations of a class (and save it in a file called myclass.hh for example), its a boring work to...
108
by: Bryan Olson | last post by:
The Python slice type has one method 'indices', and reportedly: This method takes a single integer argument /length/ and computes information about the extended slice that the slice object would...
8
by: inkexit | last post by:
I am a very amatuer c++ programmer and a somewhat accomplished composer. I am trying to write some code that creates 'self similar' melodies from a base melody the user inputs. This musical idea...
2
by: A.E lover | last post by:
Hi all, I am working on a project for industry and looking for free reliable C code for Singular Value Decomposition (SVD). I have the C code based from the book "Numerical recipes in C", but as...
6
by: 78ncp | last post by:
hi... how to implementation algorithm latent semantic indexing in python programming...?? thank's for daniel who answered my question before.. -- View this message in context:...
4
by: David | last post by:
Hi list. Do test-driven development or behaviour-driven development advocate how to do higher-level testing than unit testing? types of testing: unit integration system
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.