MIDRANGE dot COM Mailing List Archive



Home » MIDRANGE-L » January 2013

Re: AW: API for getting a list of users



fixed

Y'all - I have to go back to the simple method I recommended - DSPUSRPRF *ALL to an output file - you have all the stuff you need for filtering then - much easier than using any of the user list APIs.

JMHO
Vern

On 1/13/2013 2:46 AM, Birgitta Hauser wrote:
If you only want to have a list of all user profiles, you may also use the
UDTF USERS() located in schema QSYS2. Try:

Select *
>From Table(Users()) x;

The UDTF can be used directly in an SQL Select statement without generating
a temporary file (even though exactly this is done within the UDTF).

Mit freundlichen Grüßen / Best regards

Birgitta Hauser

"Shoot for the moon, even if you miss, you'll land among the stars." (Les
Brown)
"If you think education is expensive, try ignorance." (Derek Bok)
"What is worse than training your staff and losing them? Not training them
and keeping them!"

-----Ursprüngliche Nachricht-----
Von: midrange-l-bounces@xxxxxxxxxxxx
[mailto:midrange-l-bounces@xxxxxxxxxxxx] Im Auftrag von Rpglist
Gesendet: Saturday, 12.1 2013 20:32
An: Midrange Systems Technical Discussion
Betreff: Re: API for getting a list of users

User profiles

Sent from my iPhone

On Jan 12, 2013, at 1:00 PM, "Jerry C. Adams" <midrange@xxxxxxxx> wrote:

Do you mean actually running job(s) at any given moment or user profiles?

For the former the QUSLJOB might suffice (in the interest of full
disclosure: Never used it). But it a list API, which means you have
to build, open, and process the user space (maybe multiple user
spaces). There are examples on the web, and Bruce Vining covers it in his
"APIs at Work"
tome.

For the latter perhaps the QSYLAUTU (another list) api?

Jerry C. Adams
IBM i Programmer/Analyst
History judges a man, not by his victories or defeats, but by their
results.
-Winston Churchill
--
A&K Wholesale
Home Office: 615-832-2730
email: midrange@xxxxxxxx

-----Original Message-----
From: midrange-l-bounces@xxxxxxxxxxxx
[mailto:midrange-l-bounces@xxxxxxxxxxxx] On Behalf Of
rpglist@xxxxxxxxxxx
Sent: Saturday, January 12, 2013 12:06 PM
To: Midrange Systems Technical Discussion
Subject: API for getting a list of users

Is there an api that will provide a list of all the users or better a
class of users on the system?


--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing
list To post a message email: MIDRANGE-L@xxxxxxxxxxxx To subscribe,
unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx Before posting, please take
a moment to review the archives at http://archive.midrange.com/midrange-l.


--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing
list To post a message email: MIDRANGE-L@xxxxxxxxxxxx To subscribe,
unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx Before posting, please take
a moment to review the archives at
http://archive.midrange.com/midrange-l.

--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list
To post a message email: MIDRANGE-L@xxxxxxxxxxxx To subscribe, unsubscribe,
or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx Before posting, please take a
moment to review the archives at http://archive.midrange.com/midrange-l.








Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2014 by MIDRANGE dot 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 here. If you have questions about this, please contact