Your pnach file must be named correctly soo "your_game_crc_here.pnach" while game crc can be found in pcsx2 log windows after running the game(and use only the number soo without 0x on the beginning which just points that the number is in hexadecimal format). It also needs to be in correct folder called "Cheats" inside your pcsx2 installation directory or in some cases in "C:\Users\username\Documents\PCSX2\Cheats\".

If it still doesn't work, your pnach file ends with another extension(ie. txt) which windows hides by default, or codes are simply wrong/not working in your game version, for example if you have NTSC-U game, codes for PAL version or for NTSC-J will not work;3. If the game had a few releases like a platinum one with some changed stuff, codes from older version will probably also not work.

pcsx2 0.9.7 don't say much.
0.9.7(any revision)is beta and can be old and new gui.
The old gui is using for pnach files a folder named patches and the new gui is using folder named cheats(if you don't have the folder,just create it)

Also patches are enabled differently in the old and new gui of pcsx2 0.9.7