There is a routine as you describe and I am trying to remember where I saw a
reference to it, a couple of months ago. I considered using it but ended up
rolling my own. You can specify the wildcard characters so you could use %
instead of ? a la SQL. I will keep trying to remember.

Charles


-----Original Message-----
From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On
Behalf Of Peter Morrison
Sent: Friday, October 26, 2018 2:35 AM
To: IBM-MAIN@LISTSERV.UA.EDU
Subject: Comparison Routine - take 2

Hello listers.

 

The answers to my original question were interesting, but not close to what
I am looking for.

 

(By the way, in the original question I scanned for typos before I hit
'send', but of course (good one, Murphy) missed one.  SQU should have been
SQL, of course).

 

The answers covered regular expressions, GREP, and SUPERC.  None of these
are any good to me.

 

I believe there is a routine, either directly callable via a pointer in a
system control block (I have looked in the CVT and ECVT and cannot find
anything), OR a loadable/linkable module that IBM provide.

 

Specifically, it DOES NOT handle general regular expressions, but explicitly
handles just SQL-style 'LIKE' matches, but using '*' instead of '%' (match 0
or more characters, and 'greedy') and '?' instead of '_' (match 1
character).

 

The routine can be easily called from assembler or most high-level
languages.  In my case I want to call it from Assembler, with no LE
environment, so 'C' routines are no good (I could use metal C (assuming that
there is a suitable routine that can be compiled with metal C, or is in the
'standard' metal C support library) but don't want to set up an interface to
it for just one routine.).

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN

Reply via email to