In [3], it was shown that there are no warped product submanifolds of a locally product Riemannian manifold such that the spherical submanifold of a warped product is proper slant. In this paper, we introduce the notion of warped product submanifolds with a slant function and show that there exists a class of non-trivial warped product submanifolds of a locally product Riemannian manifold such that the spherical submanifold is pointwise slant by giving some examples. We present a characterization theorem and establish a sharp relationship between the squared norm of the second fundamental form and the warping function in terms of the slant function for such warped product submanifolds of a locally product Riemannian manifold. The equality case is also considered.