I am trying to set up a function which looks to see if multiple criteria,
across different columns are met.

Idealy I should think the following function should work, but alas, it does
not:

=COUNTIF(AND(A1:A5=1, B1:B5=2))

Any suggestions?