I was studying about currents in an injected semiconductor (by illumination) from Integrated Electronics by Millman and Halkias. They consider the diffusion hole current in an injected n-type open-circuit uniformly doped semiconductor, assuming that hole concentration is negligible compared to electron concentration, and hence, the hole drift current can be neglected as it is proportional to the hole concentration.
Since the semiconductor does not have any external potential difference, drift current due to either charge carrier should be zero. But it is said that the diffusion current density of the holes causes an internal electric field leading to the drift current of electrons, and the relation \$J=\sigma E\$ is used to calculate the field (which is non-uniform) where \$E\$ is the electric field caused by the diffusion current density, \$\sigma\$ is the conductivity and \$J\$ is the diffusion current density which is not constant as it depends on distance from illumination.
The net current (which is the sum of hole diffusion current, electron diffusion current and electron drift current) is zero as it is an open circuit. How, physically, does the current density cause an internal electric field?