hi,

also ich hatte den Eintrag den das WWS macht falsch im Kopf. Es erzeugt
folgenden Eintrag:

@@NMR <telefonnummer> <firma>

ich brauche nur die Telefonnummer, das Teil was diese Nummer ausliest sieht so
aus:


# retrieve the faxnumber from the txtfile
FAXNUM=`cat ${DEBUGTXT} | ${AWK} '{ IGNORECASE=1 } /FAX-Nr ?: ?[0-9-]*/ \
         {  $0=$0 "xxx"; \
            gsub(/-/,""); \
            anfang=match($0,/ ?: ?/); \
            anfang=anfang+match(substr($0,anfang),/[0-9]/)-1; \
            ende=match(substr($0,anfang),/[^0-9]/)-1; \
            printf ("%s",substr($0,anfang,ende)) \
         }' `
echo ""
echo "Faxnumber extracted: \"${FAXNUM}\"."

Ich muss statt dem FAX-Nr meine @@NMR unterbringen, wie muss der awk Aufruf
aussehen?


Zitat von Denny Schierz <[EMAIL PROTECTED]>:

> # retrieve the faxnumber from the printfile
> # the silly three x's are added because some awk strugle with an
> immediate CR
> # we use a PS to ascii pipe to strip (most of) the Postscript controls
> FAXNUM=`${PS2ASCII} ${FAXFILE} | ${AWK} '{ IGNORECASE=1 } /FAX-Nr ?:

[..]

-------------------------------------------------
This mail sent through IMP: http://horde.org/imp/
----------------------------------------------------------------------------
PUG - Penguin User Group Wiesbaden - http://www.pug.org

Antwort per Email an