you can easily do this with a decode inside a sum function
sum(decode(fielda, 'value1', 1,0)) as COUNT_OF_A
says everytime fielda = 'value1' add 1 to the sum otherwise add a 0 and name this sum COUNT_OF_A.
your other count is
sum(decode(fielda, 'value2', 1, 0)) as COUNT_OF_2