Denote by $V$ the vanishing locus of the affine quadric $z_1^2+\dots+z_n^2-1$ in $\mathbb{C}^n$. Clearly $V$ is a complex manifold. Let $g:V\to V$ be an automorphism of $V$ (a biholomorphism, not necessarily algebraic). As any holomorphic function on $V$ extends to a holomorphic function on $\mathbb{C}^n$, we can extend $g$ to a map $g=(g_1,\dots,g_n):\mathbb{C}^n\to\mathbb{C}^n$ (not unique). Does the fact that $g$ restricted to $V$ is an automorphism of $V$ implies that we can find an extension $g$ (Thanks Nate!) such that the equation $g_1^2+\dots+g_n^2=z_1^2+\dots+z_n^2$ holds globally on $\mathbb{C}^n$? Anyone knows a proof or a counterexample?
Maybe another question is that can we always extend an automorphism of $V$ to an automorphism of $\mathbb{C}^n$?