opennms=# select id from ifservices where nodeid = 21 and ipaddr = '192.168.5.15' and serviceid = 8; id ----- 138 (1 row)