Consider the following code:
In[63]:= f[x_]=1/(2*Pi*sigma^2)^0.5Exp[-(x-mu)^2/(2*sigma^2)]
In[64]:= p[x_]=Product[f[Subscript[x, i]],{i,1,n}]
In[68]:= D[p[x],mu]

It simply did nothing but added a partial derivative symbol at the front of p(x). Am I missing something here?