+ "where P.I_CLASS=2 and P.PARENT_ID=N.ID and P.NAME='[http://www.jcp.org/jcr/1.0]primaryType' "
+ "and P.CONTAINER_NAME='" + jdbcDataContainer.containerConfig.containerName + "')" : "select * from "
+ itemTable + " N where N.I_CLASS=1 and NOT EXISTS " + "(select * from " + itemTable
+ " P where P.I_CLASS=2 and P.PARENT_ID=N.ID " + "and P.NAME='[http://www.jcp.org/jcr/1.0]primaryType')",
new String[]{DBConstants.COLUMN_ID, DBConstants.COLUMN_PARENTID, DBConstants.COLUMN_NAME},
"A node that doesn't have primary type property", new NodeRemover(jdbcDataContainer.getConnectionFactory(),
jdbcDataContainer.containerConfig, nodeTypeManager)));
itemsInspectionQuery.add(new InspectionQuery(singleDatabase ? "select * from " + valueTable
+ " V where NOT EXISTS(select * from " + itemTable + " P " + "where V.PROPERTY_ID = P.ID and P.I_CLASS=2)"
: "select * from " + valueTable + " V where NOT EXISTS(select * from " + itemTable + " P "