If I want to become a professor, do universities care what field my PhD. is in or just that I have a PhD? I'm a self taught developer who was worked in the IT management field for a while. My academic background is an MBA and I currently teach classes on database development at a community college.

I want to be a Professor one day, and had been considering what to do for my PhD. Ideally, I'd like to teach either in the CS field or the business field as that's where the cross-section of my work is. 

I've applied to jobs to teach at local Universities and Colleges in my state recently and I've had the feedback that I need a PhD preferably in field X.

Due to life commitments the only options to me that are realistic would be to do a part-time online doctorate in education (EdD) since they are cheap. I can then go publish research in my field or even get a post-graduate certificate in CS or Business to validate my knowledge.

My question is, is this even worth-while? While it may be a harder path for me to get my foot in the door, do Universities require me to have a PhD in my field or do they just need me to have a Doctorate of some variety and then validate my knowledge in that field (either via publications, post-grad certs, or even teaching classes in that field etc)

I already read through a similar question: Is it possible to become a professor in a field where you don&#39;t have a PhD degree? but it was very much focused on overlapping fields (e.g. finance and math)
Generally, you're going to need a PhD in a field very close to the one you want to teach in. Many programs make this information available to applicants, and indicate that they are looking for a PhD in field X, Y or Z. This is because these are the subjects where the information and experience that you gain during the course of a PhD are directly relevant to your ability to then teach the subject you are applying for. Simply getting a PhD isn't going to make you much more competitive for a position, unless your PhD shows that you have gained skills directly relevant to the position.

You mentioned the possibility of doing research or getting other certification of your skills, depending on where you want to be a professor, these could be a better option for you. If you can find a university willing to support your research, and get it published, this definitely shows that you have developed relevant skills for teaching in that field. Added to the fact that you have taught at a community college (indicating that you have some ability to perform a CS teaching job), and you have a much more competitive application than you started with.