The Change Distribution List Entry command lets you change or remove
an entry from one, generic, or all distribution lists. The From User
ID value must match an existing entry. An ACTION parameter exists
which defaults to *TEST to allow testing of what the *CHANGE function
will provide.
You must have *ALLOBJ special authority to use CHGDSTLE.
A typical command would be:
CHGDSTLE LSTID(*ALL) FROMUSRID(xxx yyy) +
TOUSRID(aaa bbb) ACTION(*CHANGE)
The TOUSRID value would be checked to see if an entry exists in the
system distribution directory (can be displayed with WRKDIRE). The
text description for the TOUSRID parameter defaults to *RTV meaning
the description is retrieved from the distribution directory.
All distribution lists would be checked to see if an entry matches
the FROMUSRID value. If one is found, the entry is removed by the
system RMVDSTLE command and a new entry is added by the system
ADDDSTLE command.
A listing would be output describing any lists that were changed.
System support
--------------
A user to be entered into a distribution list must first be entered
into the system distribution directory. The WRKDIRE command may be
used with option 1 to add a new user. A 2 part address (each part is
8 bytes) must be described and a description entered. The
description is not just text and will be compared to when removing an
entry from a distribution list.
A distribution list is supported by several commands such as:
CRTDSTL
WRKDSTL
To add an entry, WRKDSTL could be used with option 8 'Work with
entries'. The system supports ADDDSTLE and RMVDSTLE, but does not
support a CHGDSTLE. To change an entry, the entry must be removed
and then added.
When an entry is added, the description of the user (USRID parameter)
must match the description in the system distribution directory
(unless the FROMLSTID parameter is used).
If the entry is added by using the WRKDIRE option 8 ('Work with
entries), the system automatically adds the proper description from
the distribution directory. However, when the ADDDSTLE command is
used directly, the description must be entered to match the
distribution directory value. Entering an exact match of the
description can be awkward as it may be several bytes in length
(different case is allowed, but can lead to inconsistencies).
The RMVDSTLE command uses a default of *FIRST for the description of
the USRID parameter. This avoids keying the description if the first
2 parts of the parameter provide a unique entry.
Both the ADDDSTLE and CHGDSTLE commands allow multiple distribution
lists to be specified, but each list must be specifically named.
There is no *ALL or generic capability.
TAA support
-----------
The TAA CHGDSTLE command lets you change an entry in one or more
distribution lists. A change is performed by removing the entry and
then adding a new entry.
A single list may be changed, or all lists, or a generic name of a
list (see the section on 'Generic support of list names'). Only
those lists which have an entry that matches the From User ID will be
changed.
As with the RMVDSTLE command, FROMUSRID parameter defaults the
description to *FIRST. This is an appropriate default as long as you
have a unique entry using the first two parts of the parameter.
When an entry is added, the TOUSRID parameter for the description
defaults to *RTV. This retrieves the current text description from
the system distribution directory thus avoiding complex keying of a
long description. The *RTV function assumes that the matching entry
in the system distribution directory can be found by using a unique
address (first two parts of TOUSRID).
Generic support of list names
-----------------------------
The system allows a distribution list to be created by any value. It
could be 123 or 123* or AB*C.
CHGDSTLE supports a generic naming convention for the LSTID parameter
to allow easier processing if your distribution lists use a typical
naming structure. If a trailing * is found at the end of the LSTID
name, it is assumed that the previous characters represent a generic
name and all lists that match the generic name would be processed.
CHGDSTLE escape messages you can monitor for
--------------------------------------------
TAA9892 No distribution list was found to match the LSTID
TAA9893 No entries were found to match the From User ID
TAA9894 The TOUSRID value specified does not exist
Escape messages from based on functions will be re-sent.
Command parameters *CMD
------------------
LSTID The name of the list to be processed. A specific
name, a generic name, or the special value *ALL may
be specified.
The system allows a distribution list to be created
by any value. It could be 123 or 123* or AB*C.
CHGDSTLE supports a generic naming convention for
the LSTID parameter to allow easier processing if
your distribution lists use a typical naming
structure. If a trailing * is found at the end of
the LSTID name, it is assumed that the previous
characters represent a generic name and all lists
that match the generic name would be processed.
FROMUSRID A 3 part parameter.
Part 1 is the user ID as it appears in the
distribution list.
Part 2 is the address as it appears in the
distribution list.
Part 3 is the description as it appears in the
distribution list. The default is *FIRST meaning
the first entry that matches the first 2 parts will
be processed.
TOUSRID A 3 part parameter.
Part 1 is the user ID as it appears in the
distribution directory as displayed by WRKDIRE.
Part 2 is the address as it appears in the
distribution directory.
Part 3 is the description as it appears in the
distribution directory. The default is *RTV meaning
the description will be retrieved from the first
entry that matches the first two parts.
ACTION The action to be taken.
*TEST is the default meaning that no changes will
occur. The output listing will describe what lists
would have been changed if *CHANGE had been
specified.
*CHANGE may be specified to cause changes for any
From User ID that is matched.
Restrictions
------------
You must have *ALLOBJ special authority to use CHGDSTLE.
Prerequisites
-------------
The following TAA Tools must be on your system:
CHKDIRE Check directory entry
EDTVAR Edit variable
RSNALLMSG Resend all messages
RTVDIRE Retrieve directory entry
RTVSYSVAL3 Retrieve system value 3
SNDCOMPMSG Send completion message
SNDESCINF Send escape information
SNDESCMSG Send escape message
SNDSTSMSG Send status message
Implementation
--------------
None, the tool is ready to use.
Objects used by the tool
------------------------
Object Type Attribute Src member Src file
------ ---- --------- ---------- ----------
CHGDSTLE *CMD TAADSTG QATTCMD
TAADSTGC *PGM CLP TAADSTGC QATTCL
TAADSTGR *PGM RPG TAADSTGR QATTRPG
|