$ for all $i,j\in I$. Choose the ideal $J$ in Lemma \[le:Uzideal\] as explained above. Then one gets the Shapovalov determinants of $U_q({\mathfrak{g}})$ and $u_q({\mathfrak{g}})$ from the one of $U(\chi )$ in Thm. \[th:Shapdet2\].

The second part of Thm. \[th:ShapdetUqg\] was proved in [@a-KumLetz97] in the case when the order of $q$ is prime and ${\Bbbk }$ is the cyclotomic field $\mathbb{Q}[q]$.

Appendix
========

For the proofs of Thms. \[th:Shapdet\] and \[th:Shapdet2\] we need some commutative algebra which is considered here. Let ${\bar{{\Bbbk }}}$ be an algebraically closed field.

\[le:rankX\] Let $B$ be an integral domain, $x$ an indeterminate, $k\in {\mathbb{N}}$, and $X\in B[x]^{k\times k}$. Then there exist $s\in \{0,1,\dots ,k\}$, $D_1,D_2\in
  B^{k\times k}$, $D_0\in B[x]^{k\times k}$ and $b\in B\setminus \{0\}$ such that $\det D_1,\det D_2\not=0$, $$\begin{aligned}
    D_1XD_2=xD_0+b\,\mathrm{diag} (\underbrace{1,\dots ,1}_s,0,\dots ,0).
    \label{eq:rankX}
  \end{aligned}$$

Let ${\mathrm{Frac}}(B)$ be the field of fractions of $B$. Then there exist $s\in \{0,1,\dots ,k\}$ and $D'_1,D'_2\in {\mathrm{Frac}}(B)^{k\times k}$ such that $\det D'_1,\det D'_2\not=0$ and $$D'_1X(0)D'_2=\mathrm{diag} (\underbrace{1,\dots ,1}_s,0,\dots ,0).$$ Let $b_1,b_2\in B\setminus \{0\}$ such that $b_1D'_1,b_2D'_2\in B[x]^{k\times k}$. Let $b=b_1b_2$, $D_1=b_1D'_1$, and $D_2=b_2D'_2$. Then $$D_1X(0)D_2=b\,\mathrm{diag} (\underbrace{1,\dots ,1}_s,0,\dots ,0),$$ and hence the lemma holds for $D_0=D_1X'D_2$, where $X'\in B[x]^{k\times k}$ such that $X=X(0)+xX'$.

\[le:detXfactor\] Let $B$ be a finitely generated integral domain over ${\bar{{\Bbbk }}}$, $x$ an indeterminate, $k\in {\mathbb{N}}$, $r\in \{0,1,\dots ,k\}$, and $X\in B[x]^{k\times k}$. Assume that $\mathrm{rk}\,X(0)_p\le r$ for all points $p$ in a non-empty Zariski open subset of the affine variety of $B$. Then $\det X=x^{k-r}b$ for some $b\in B[x]$.

By Lemma \[le:rankX\] there exist $s\in \{0,1,\dots ,k\}$, $b\in B\setminus \{0\}$, $D_1,D_2\in B^{k\