× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



If I just would like all words, is that where you use
FOR
ENDFOR

I would want everything bet. each blanks, every word.

Rather than to do lookups. this is new to me.


> OK This is really what is needed. If I can just take every word in the
> comments, that is either only numbers, or a combo (alpha and numerals).
>
> Bec. invoices sometimes have letters in them.
>
> SO in your idea, I would have to load 26 letters and 0-9.
>
> But then I'll get other words.
>
> That may not be so bad already since this is used to chain against in a
> later process. But for esthetics, I would be interested to do it more
> correct.
>
>
>> As I said, the method is old.  I am sure there are better ways today.
>>
>> Essentially,
>> 1) define an array of 11 elements.  The elements are "#012356789"
>> 2) define an array of 40 elements.
>>
>> Fill the 40 element array with the comment.  Use those elements, one at
>> a time, to do a lookup in the 11 element.
>>
>> steema@xxxxxxxxxxxxx wrote:
>>> Booth, I wasn't able to make use of your excellent idea. is the string
>>> to
>>> be a CONSTANT?
>>> I am coding it now the slow way, but can always change.
>>>
>>>> The array that you would do your lookup against would be "#0123456789"
>>>> then. Every time you read a '#' you would start a new record, and
>>>> continue that record until you received a blank.
>>>>
>>>> steema@xxxxxxxxxxxxx wrote:
>>>>> On further review, I need to look for the character # that follows
>>>>> the word 'invoice', then take the string that follows this, as in
>>>>> this
>>>>> case:
>>>>> INVOICE # XKC02G146L
>>>>>
>>>>> that is the standard, then I can code for the deviant cases.
>>>>>
>>>>> if it is easier I guess I can just look for '#' and forget about
>>>>> 'invoice'
>>>>>
>>>>>
>>>>>> http://tinyurl.com/9ehns
>>>>>>
>>>>>> This is from 1998, so there are no doubt better ways today, but it
>>>>>> shows
>>>>>> a way to eliminate all of the characters except the ones you list in
>>>>>> a
>>>>>> constant.
>>>>>>
>>>>>> Essentially you can define a 40-element array of 1-character each.
>>>>>> Then
>>>>>>   do a for/endfor loop, reading and saving digits. When I find a
>>>>>> digit
>>>>>> I
>>>>>> start a new record.  If i am reading digits and find anything but a
>>>>>> digit, then the record is done.  That way I can have several invoice
>>>>>> numbers per 40-char. comment.
>>>>>>
>>>>>>
>>>>>>
>>>>>> steema@xxxxxxxxxxxxx wrote:
>>>>>>> On further relection, it is ok if there are 'wrong' invoice numbers
>>>>>>> in
>>>>>>> this mix.
>>>>>>> I have a comment field of 40 that will have some valid invoice
>>>>>>> numbers,
>>>>>>> and maybe non-valids like a phone number.
>>>>>>>
>>>>>>> I just want to wade through this 40 pos. field and pick up all
>>>>>>> contiguous
>>>>>>> numerics. I won't even be concerned about the X before it, I can
>>>>>>> add
>>>>>>> this
>>>>>>> if I want.
>>>>>>>
>>>>>>> The purpose here is to speed up a process by aggregating these
>>>>>>> invoice
>>>>>>> numbers.
>>>>>>>
>>>>>>> I am seeking the most elegant and efficient way to do this.
>>>>>>>
>>>>>>> Thanks,
>>>>>>> Steve
>>>>>> --
>>>>>> -----------------------------------
>>>>>> Booth Martin
>>>>>> http://martinvt.com
>>>>>> -----------------------------------
>>>>>> --
>>>>>> This is the RPG programming on the AS400 / iSeries (RPG400-L)
>>>>>> mailing
>>>>>> list
>>>>>> To post a message email: RPG400-L@xxxxxxxxxxxx
>>>>>> To subscribe, unsubscribe, or change list options,
>>>>>> visit: http://lists.midrange.com/mailman/listinfo/rpg400-l
>>>>>> or email: RPG400-L-request@xxxxxxxxxxxx
>>>>>> Before posting, please take a moment to review the archives
>>>>>> at http://archive.midrange.com/rpg400-l.
>>>>>>
>>>>>>
>>>> --
>>>> -----------------------------------
>>>> Booth Martin
>>>> http://martinvt.com
>>>> -----------------------------------
>>>> --
>>>> This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing
>>>> list
>>>> To post a message email: RPG400-L@xxxxxxxxxxxx
>>>> To subscribe, unsubscribe, or change list options,
>>>> visit: http://lists.midrange.com/mailman/listinfo/rpg400-l
>>>> or email: RPG400-L-request@xxxxxxxxxxxx
>>>> Before posting, please take a moment to review the archives
>>>> at http://archive.midrange.com/rpg400-l.
>>>>
>>>>
>>>
>>
>> --
>> -----------------------------------
>> Booth Martin
>> http://martinvt.com
>> -----------------------------------
>> --
>> This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing
>> list
>> To post a message email: RPG400-L@xxxxxxxxxxxx
>> To subscribe, unsubscribe, or change list options,
>> visit: http://lists.midrange.com/mailman/listinfo/rpg400-l
>> or email: RPG400-L-request@xxxxxxxxxxxx
>> Before posting, please take a moment to review the archives
>> at http://archive.midrange.com/rpg400-l.
>>
>>
>
> --
> This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing list
> To post a message email: RPG400-L@xxxxxxxxxxxx
> To subscribe, unsubscribe, or change list options,
> visit: http://lists.midrange.com/mailman/listinfo/rpg400-l
> or email: RPG400-L-request@xxxxxxxxxxxx
> Before posting, please take a moment to review the archives
> at http://archive.midrange.com/rpg400-l.
>
>


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.