RDKit substructure filter for unsubstitued rings/nitrogens

Hi,
I’m currently attempting to utilize the RDKit mol substructure filter to sift through a chemical library. However, I’ve encountered difficulty specifically when attempting to filter unsubstituted phenyl rings. My objective is to exclude all phenyl rings lacking substituents or containing NH instead of N-C from amides within the main dataset.
The substructure input is generated using MarvinSketch. Nevertheless, upon applying the filter, it seems unable to differentiate between substitution over the ring and its absence, likely due to implicit substituents being bypassed.
Could you kindly advise on any potential solutions to address this issue? Any recommendations would be greatly appreciated!
Lucas

Not 100% sure what you are after here.
If you mean an aryl ring connected to a molecule, but no other substituents then something like this would work;
[c-*]1:[cH]:[cH]:[cH]:[cH]:[cH]:1
If you want to exclude molecules containing Aryl-NH-amides, then this will do it;
c-[NH]-[CX3](=[OX2])-C

Simon.