The HQ-9 is quite an expensive system, which is demonstrated by Pakistan purchasing only one HQ-9P battery for its army since 2021. There might be even fewer HQ-9BE in service with the PAF. There is simply no way for Pakistan to defend all of its main military infrasctructure using the HQ-9 series; even if the HQ-9 system was present at those airbases during India's attack, the defending forces might have reserved the HQ-9 for missiles targeting highly-critical parts of the airbase whilst letting other missiles through. For the record, this is allegedly what happened during Iran's attack on Nevatim Air Base in October 2024.
All of this is to say that the biggest weakness of Pakistan's HQ-9P/BE network is numbers. Even if the existing launchers expended all of their rounds with a 100% hit rate, Indian missiles still would've made their way to their targets.
You can assess a system's effectiveness only if you have the target hit rate (i.e. # of successful hits / # of launched missiles), not because an area supposedly defended by the said system managed to get hit.
Pakistan can improve this situation by purchasing less-expensive alternatives such as the HQ-22/FK-3, although I'm not sure just how much cheaper those systems would be. The up-ranged HQ-16FE is also supposedly in Pakistani service but there is no photographic evidence of that, plus I'd expect the number of such systems to be very small.