In the console, monitoring, Queries, make a new query, and switch to show query language (it's not there in the pull down / pick lists)
and just this to get you started:
select * from sms_usermachinerelationship
I'm guessing you'll want something like...
where sms_usermachinerelationship.uniqueusername is null
Test of course. I didn't actually make a collection query...
http://msdn.microsoft.com.../library/hh949107.aspx take a look at that for attribute names.
Edit: or... just thought of this (since I didn't actually look at a cm12 console, nor am I looking now); perhaps boxes that don't have a UDA relationship simply don't have an entry in sms_usermachinerelationship at all; so maybe it'll need to be a subselect; those resourceids not in (select resourceid from sms_usermachinerelationship where uniqueusername is not null) ??? Again... just sorta dreaming this up. Not actually doing anything in a console.
<message edited by skissinger on Wednesday, May 30, 2012 8:00 PM>