Use _Connect-Type to select Remote Client connections only.The following ABL code example demonstrates and can be customised to requirements:
FOR EACH _Connect NO-LOCK WHERE _Connect-Name <> ? AND _Connect-Type = 'REMC':
IF AVAILABLE _Connect THEN
DISPLAY _Connect-Type _Connect-ClientType _Connect-Name _Connect-ID SKIP
_Connect-Pid _Connect-Device _Connect-IPAddress SKIP
SUBSTRING(_Connect-Time,5,6) LABEL "con DATE"
SUBSTRING(_Connect-Time,12,8) LABEL "con TIME"
_Connect-Transid _Connect-Server .
END.
- If specific client-types are required the WHERE condition can use _Connect-Type, for example:
FOR EACH _Connect NO-LOCK WHERE _Connect-Name <> ? AND _Connect-Type = 'REMC' AND _Connect-ClientType = 'SQLC' :The following SQL code example demonstrates and can be customised to requirements:
$ sqlexp testdb -S <port> -user sysprogress -password sysprogress -infile listAllSqlConnections.sql -outfile connectionsSql.txtWhere listAllSqlConnections.sql contains the following statement:
SELECT "_Connect-Type", "_Connect-ClientType", "_Connect-Name", "_Connect-Pid", "_Connect-Device", "_Connect-IPAddress"
FROM PUB."_Connect"
WHERE "_Connect-Name" IS NOT NULL AND "_Connect-Type" = 'REMC' AND "_Connect-ClientType" = 'SQLC';