An existence theorem for a stochastic partial differential equation arising from filtering theory