OK, you got some solutions for getting this to work but please note that your approach just isn't a good idea in the first place (sorry).
in reply to How to access a hash from another file
YOu currently populate the hash by actually typing stuff into a file that you then save as a perl module. However, it can very easily be generated by the code using loops as I mentioned earlier in the other thread you are refering to. It sort of defeats the purpose of scripting if you then end up typing all the combinations of categories and sub-categories by hand into a file (i.e. hardcoding them).
Do yourself a favour and have a go at using loops to let the code generate all these tedious combinations of things and you will begin to see "The Light"(Tm) :-)