That got most of the VM's but my filter for '%Template%' also filtered more that is was supposed to. Not because of anything in the where clause or the value '%Template%' but because we didn't remove the descriptions out of the VM's after spinning up from a template......lol
OOOPS!
I'll post the final query. The one above was simplified after some logic was applied to export the tables to a test DB.