IIf([criteria_id] Like "P*",1,0) This would return a 1 for a record where the criteria_id started with P and 0 if it didn't. If you then summed this you would get a count for all the records.
The * after the P means it will look for something that starts with but P doesn't matter what is...