Not only that, but as often as ST writers have went to the well to base a plot on the failure a technical device, I would think that everyone would want to take precaution before going into a room. -Particularly if they wear a red shirt.
Given the number of times that our hero encountered a "weapon deactivator," you would think they would carry a backup weapon of some sort, one that was non-technological and simple. An small compressed air gun or just a knife.
How about having a good old-fashioned Klingon bat'leth, or a good pair of strong boots to give them a kick in the family jewels (as long as you can locate them.)
The phaser rifle in all of its incarnations is a good bat and a parrying weapon. A bayonet might be useful, though. Even on the "pistol" sidearms... Real-world pistol-knife combinations fail because pistols are difficult to balance to start with, having recoil and gas exhaust (meaning the presence of the knife blade harms the use as a pistol) and knives require some basics of holding ergonomics (meaning the pistol grip harms the use as a knife). TNG phasers would be a different matter: there's no reason to assume a bayonet would make the beam go awry, and the grip is oriented so that a bayonet aligned along the direction of the beam would actually be pretty ergonomic. What I'd really like to see on the TNG phaser is a "stiletto rapier" functionality. It should be trivial for the handle to sprout a blade of adjustable length, from a few centimeters (for simple cutting purposes) to a dozen centimeters (knifefights) to a meter or so (slashing at an opponent armed with a typical edged or blunt instrument). The STIX stiletto-katana is not the only way to go. The blade could be made of solid matter (say, simple steel rolling out from a spool), but also of some sort of jam-proof forcefields, or then materialized in place with replicator technology. Not all tech can be jammed, and making some of it jam-proof might actually result in a more reliable device than one based purely on mechanics. Larry Niven's variable-sword is always an option, too. Timo Saloniemi
Even a baton of some kind would be an improvement over what Starfleet carries in to combat situations. I once came up with the idea of a stun baton (not an original name, I'll grant you) that was essentially like the kids collapsible swords, but having a small power source that could stun opponents. I think it is kind like a pain-stik, but more design to incapacitate rather than cause pain or kill. I agree that some sort of jam-proof weapons would be preferred by any combat team, Marines or not. The ability to deal with opponents without the benefit of a phaser should be a part of at least Security training.