In quantum mechanics, the completeness relation for discrete and continuous basis are $$\begin{align} \sum_n \lvert n \rangle \langle n\rvert &= 1 \tag{1} \\ \int \lvert x \rangle \langle x \rvert \mathrm{d}x = 1 \tag{2} \end{align}$$ respectively. The integral form can be written as $$ \lim_{n \rightarrow \infty} \sum_n \lvert x_n \rangle \langle x_n\rvert \Delta x_n=1 \tag{3} $$ such that $$\langle \psi \lvert \psi \rangle= \int \langle \psi \lvert x \rangle \langle x \lvert \psi \rangle \mathrm{d}x = \lim_{n \rightarrow \infty} \sum_n \langle \psi \lvert x_n \rangle \langle x_n\lvert \psi \rangle \Delta x_n \tag{4}$$ like the definition of definite integral.
My question is, suppose space is discrete, Eq. (2) may be written as $$ \sum_n \lvert x_n \rangle \langle x_n \rvert =1 \tag{6} $$ If I approach the continuous limit (2) from discrete basis (6), how the $\Delta x_n$ in Eq. (3) should appear?