[ << ] [ < ] [ Up ] [ > ] [ >> ]         [Top] [Contents] [Index] [ ? ]

6.13 $PIECE

Syntax

$PIECE(s,d[,n[,end]])

Accesses the nth through end d-delimited pieces of string s.

The first argument is the string to be evaluated.

The second argument is the delimiter to be used.

The optional third argument is the first d-delimited piece to access, and defaults to 1.

The optional fourth argument is the final d-delimited piece to access, and defaults to the value of the third argument (n).

Can be used on the left-hand side of an expression in order to SET a value into a d-delimited piece of s, as in:

; ^jpw="this^is^a^piece"
SET $PIECE(^jpw,"^",2)="isn't" ; => "this^isn't^a^piece"

This document was generated on September 20, 2023 using texi2html 5.0.