× 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.



In order to remember what all the parameters are, we wrapped a command
around a cheap CL that only does a CALL to QCLSCAN.  Now we use the prompt
text instead of trying to remember if TARGET comes first, or TARGET_LEN.

--Paul E Musselman
PaulMmn@ix.netcom.com



>>I seem to remember an "API" for scanning for a string...

>>Chuck

>QCLSCAN
>
>Like this.
>
>       CALL    'QCLSCAN'
>       PARM                    TARGET
>       PARM                    TARGET_LEN
>       PARM                    STARTING_POS
>       PARM                    PATTERN
>       PARM                    PATTERN_LEN
>       PARM                    TRANS_LOW_UP
>       PARM                    TRIM
>       PARM                    WILD_CARD
>       PARM                    POS_FND
>
>TARGET =       numeric         What you're looking into.
>TARGET_LEN     3,0             Length of the TARGET variable is(not it's
>contents)
>STARTING_POS   3,0             Offset of where in TARGET to start search
>PATTERN                numeric         Pattern you're looking for.
>PATTERN_LEN    3,0             Length of Pattern Field(not it's contents)
>TRANS_LOW_UP   1               Translate Lower case to Upper( 1 = Yes, 0 = No)
>TRIM           1               Trims something or other. (1=Yes,0=No)
>WILD_CARD      1               Wild card character
>POS_FND        3,0             Position the string was found in target,
>zero if not found.
>
>The TARGET and PATTERN  Can be any length alpha field.  (like a description
>field from a file).
>
>You can call this program from RPG or CL.
>
>The wild card is nice.
>
>John Carr CDP


+---
| This is the Midrange System Mailing List!
| To submit a new message, send your mail to MIDRANGE-L@midrange.com.
| To subscribe to this list send email to MIDRANGE-L-SUB@midrange.com.
| To unsubscribe from this list send email to MIDRANGE-L-UNSUB@midrange.com.
| Questions should be directed to the list owner/operator: david@midrange.com
+---


As an Amazon Associate we earn from qualifying purchases.

This thread ...

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.