The energy of point charge configuration can be written as: $$W = \frac{1}{2}\sum_{i=1}^{n}q_{i}V(r_{i}) \, ,$$ which can take both positive and negative values. However, when we integrate the equation to get the energy of a continuous charge dustribution: $$W = \frac{1}{2}\int\rho Vd\tau \Rightarrow W = \frac{\epsilon_{0}}{2}\left [ \int E^{2} d\tau + \oint VE\cdot da\right ] \, .$$
Take the volume to integrate to be all space, then the second term vanishes: $$W = \frac{\epsilon_{0}}{2}\int E^{2}d\tau \, .$$ This formula can take only positive values.
So there is a discrepancy between the two formulas. What caused the discrepancy? According to Griffith's Introduction to Electrodynamics, it says in the former equation $V(r_{i})$ represent the potential due to all charges but $q_{i}$, whereas later $V(r_{i})$ is the full potential. But why would the original charge has any potential when there is no other charge already present?