WS
02/23/2021, 7:33 PMspookerlabs
02/23/2021, 7:41 PMselect mac FROM interface_details WHERE interface = (select interface FROM routes WHERE destination = '0.0.0.0');
works0.0.0.0
) and so query interface_details for this interfaceWS
02/23/2021, 7:45 PMQuery Execution Failed : Scalar sub-query has returned multiple rows
i follow the logic thoughspookerlabs
02/23/2021, 7:46 PMWS
02/23/2021, 7:47 PM10.0.0.26
172.20.10.7
10.85.15.115
utun1
en0
en0
utun1
utun1
...
spookerlabs
02/23/2021, 7:50 PMfritz
02/23/2021, 8:08 PMSELECT interface, mac, platform,
CASE
WHEN platform = 'windows' THEN MAX(dhcp_lease_obtained)
WHEN platform = 'darwin' THEN MAX(ibytes)
END AS max_column
FROM interface_details, os_version;
WS
02/23/2021, 8:09 PMfritz
02/23/2021, 8:11 PM