Skip to main content
How can I access the data that is returned when using the LISTUSER command? What file and account is it being stored in?

------------------------------
robert modrich
Developer
Rocket Forum Shared Account
TEMECULA CA US
------------------------------
How can I access the data that is returned when using the LISTUSER command? What file and account is it being stored in?

------------------------------
robert modrich
Developer
Rocket Forum Shared Account
TEMECULA CA US
------------------------------
hi robert,

From which system do you use it ? 

on UNIVERSE the LISTUSER command show 
UsrNo Pid...... UID.. UserName Type Acct.............. LogonTime...............          
    1     31295  1712 efv_unirpc Term /data/uvdbsb55/SM.DEFN Fri Oct 28 08:32:25 2022    
   -2      7161 1000000 dt       Phan /data/uvdbsb55/WEB55 Fri Oct 28 10:43:42 2022      
which is listed from uv shared memory. 
None info comes from 'datafile'.


------------------------------
manu fernandes
------------------------------
How can I access the data that is returned when using the LISTUSER command? What file and account is it being stored in?

------------------------------
robert modrich
Developer
Rocket Forum Shared Account
TEMECULA CA US
------------------------------
You could execute the command from a BP and add the INTERNAL option which returns the data in an array. This will be easier to work with
LISTUSER INTERNAL

------------------------------
Greg Livingston
Universe Practice Lead
OUTsurance Insurance
Centurion GA ZA
------------------------------
How can I access the data that is returned when using the LISTUSER command? What file and account is it being stored in?

------------------------------
robert modrich
Developer
Rocket Forum Shared Account
TEMECULA CA US
------------------------------
Robert,

UniVerse has a USERINFO function that may work for you. Check the UniVerse BASIC Commands reference guide.

Jon

------------------------------
Jon Kristofferson
Pick Programmer
Snap-on Credit LLC
Libertyville IL US
------------------------------
How can I access the data that is returned when using the LISTUSER command? What file and account is it being stored in?

------------------------------
robert modrich
Developer
Rocket Forum Shared Account
TEMECULA CA US
------------------------------

Hi,

You can always do in BASIC an EXECUTE 'LISTUSER' CAPTURING RESPONSE

That will return the response in RESPONSE.


I created a program I call SHOWUSER which uses the LISTUSER command and allows me to filter data from LISTUSER that I want.

Since I manage a cloud service for multiple customers some times I need to know how many users are logged in to a specific account.
So,  I can type the following.

:SHOWUSER MENDEZ
and will return the following.
UsrNo Pid...... UID.. UserName Type Acct.............. LogonTime...............
-26 5526 0 root Phan /u1/MENDEZ/WEB Wed Feb 23 12:08:55 2022
48 25635 1209 j.zavala Term /u1/MENDEZ/IMPORT Fri Oct 28 08:10:44 2022
51 17174 1241 r.navarro Term /u1/MENDEZ/IMPORT Fri Oct 28 08:01:15 2022
-68 4237 1168 mqm Phan /u1/MENDEZ/ABI Thu May 26 18:35:06 2022

Total lines returned: 4
:
If I want to know how many PHANTOM's are running I can do the following.

SHOWUSER PHAN

UsrNo Pid...... UID.. UserName Type Acct.............. LogonTime...............
-4 11165 1000 sam Phan /u1/PREMIERE/WEB Tue Oct 11 16:02:26 2022
-9 6153 1168 mqm Phan /u1/ATSABI Wed Feb 23 12:09:12 2022
-10 5577 0 root Phan /u1/AMMEX/WEB Wed Feb 23 12:08:57 2022
-11 5174 0 root Phan /u1/ASSOCIATE/WEB Wed Feb 23 12:08:48 2022
-12 5203 0 root Phan /u1/CAPIN/WEB Wed Feb 23 12:08:49 2022
-13 5230 0 root Phan /u1/HARTRY/WEB Wed Feb 23 12:08:49 2022
-15 5277 0 root Phan /u1/TEAMHAND/WEB Wed Feb 23 12:08:50 2022
-16 5304 0 root Phan /u1/SHANNON/WEB Wed Feb 23 12:08:51 2022
-17 5327 0 root Phan /u1/QSBROKERS/WEB Wed Feb 23 12:08:51 2022
-18 5349 0 root Phan /u1/ATLASINT/WEB Wed Feb 23 12:08:51 2022

If you just type SHOWUSER it will return everything listed from the LISTUSER command.

See attached BASIC Program.

Regards, Sam



------------------------------
Samuel Powell
President/Developer
Advanced Transportation Systems Inc
Colorado Springs CO US
------------------------------
You could execute the command from a BP and add the INTERNAL option which returns the data in an array. This will be easier to work with
LISTUSER INTERNAL

------------------------------
Greg Livingston
Universe Practice Lead
OUTsurance Insurance
Centurion GA ZA
------------------------------
Greg is that for Universe - I am not aware of the INTERNAL option in Unidata

------------------------------
robert modrich
Developer
Rocket Forum Shared Account
TEMECULA CA US
------------------------------