Where can I find field "Last IP-Address" in Query Designer / DSM Reporter?

Document ID : KB000010394
Last Modified Date : 14/02/2018
Show Technical Document Details
Introduction:

Where can I find field "Last IP-Address" in Query Designer / DSM Reporter?

There is the property "Last IP-Address" in the agent section of the computer properties. (together with "registered", "last run", Trust level" ...)
I'm looking for this field in the Query Designer and the DSM Reporter, but can't find it.

1.png

Environment:
All Versions of Client Automation
Instructions:

The field 'ip_address' from table 'ca_agent' is not available in field section within the DSM Reporter out of the box.

But this can be added using SQL Queries.

 

1. In SQL Server Management Studio, execute the following query:

use mdb

INSERT INTO rpdatfld
VALUES
('ITRM_DISCOVEREDHARDWARE11','ENU','Last IP Address','ca_agent','ip_address',
'Last IP Address',1,1,15,7,0,
'Crit0PseudoTemplate=Last IP Address = ''$CritValueLabel$'';'+CHAR(13)+CHAR(10)+
'DisplayEnum=;'+CHAR(13)+CHAR(10)+
'Crit0Type=CT_STRING;'+CHAR(13)+CHAR(10)+
'Usage=0;'+CHAR(13)+CHAR(10)+
'CriteriaCount=1;'+CHAR(13)+CHAR(10)+
'PseudoTemplate=($Crit0Pseudo$);'+CHAR(13)+CHAR(10)+
'Crit0Name=Last IP Address;'+CHAR(13)+CHAR(10)+
'Crit0ValueSelector=VS_EDITABLELIST;'+CHAR(13)+CHAR(10)+
'Category=General Information>Computer;'+CHAR(13)+CHAR(10)+
'Table=ca_agent;'+CHAR(13)+CHAR(10)+
'Column=ip_address;'+CHAR(13)+CHAR(10)+
'Crit0PossibleValues=SELECT DISTINCT ip_address as label, ip_address as value FROM ca_agent ORDER by label;'+CHAR(13)+CHAR(10)+
'Description=Last IP Address;'+CHAR(13)+CHAR(10)+
'Name=Last IP Address;'+CHAR(13)+CHAR(10)+
'From=ca_agent;'+CHAR(13)+CHAR(10)+
'SqlTemplate=$target.primarykeyfield$ in ($Crit0Sql$);'+CHAR(13)+CHAR(10)+
'Crit0SqlTemplate=SELECT object_uuid FROM ca_agent WHERE ip_address $CritOperator$ ''$CritValue$'';'+CHAR(13)+CHAR(10)+
'Where=object_uuid=PRIMOBJECT;'+CHAR(13)+CHAR(10)+
'ProcessSiblings=0;'+CHAR(13)+CHAR(10))

 2.png

 

2. Close and reopen the DSM Explorer/DSM Reporter. The "Last IP Address" field will now be available.

 3.jpg