I understand the difference between batch and stochastic gradient descent as follows: let's say there are only two samples and two features. Let the function used to estimate $y^{(i)}$ be: $$h_{\theta}(x^{(i)}) = \theta_1x_1^{(i)}+\theta_2x_2^{(i)}$$
Specifically the batch gradient descent algorithm will go something like this: in the first "update" step, $$\hat{\theta}_1 = \theta_1 + \alpha\sum_{i=1}^2\big(y^{(i)}-h_{\theta}(x^{(i)})\big)x_1^{(i)}$$ $$\hat{\theta}_2 = \theta_2 + \alpha\sum_{i=1}^2\big(y^{(i)}-h_{\theta}(x^{(i)})\big)x_2^{(i)}$$
i.e., each $\theta_j$ is updated in a single "update step" to the new value $\hat{\theta}_j$. And then more "update steps" will be performed till both $\theta_1$ and $\theta_2$ converge.
Question 1: when $\theta_2$ is being updated in the first "update step" to $\hat{\theta}_2$, does the calculation of $h_{\theta}(x^{(i)})$ involve using the old value of $\theta_1$ or the updated value of that parameter? i.e., do we say $$h_{\theta}(x^{(i)}) = \theta_1x_1^{(i)} + \theta_2x_2^{(i)}$$ or $$h_{\theta}(x^{(i)}) = \hat{\theta}_1x_1^{(i)} + \theta_2x_2^{(i)}$$
I also wanted to clarify my understanding of stochastic gradient descent (not talking about mini-batch). This time the first "update" step looks like: $$\hat{\theta}_1 = \theta_1 + \alpha\big(y^{(r)}-h_{\theta}(x^{(r)})\big)x_1^{(r)}$$ $$\hat{\theta}_2 = \theta_2 + \alpha\big(y^{(s)}-h_{\theta}(x^{(s)})\big)x_2^{(s)}$$
Then this "update step" is repeated till the $\theta$'s converge (hopefully my understanding is correct). Same question as before applies to this case as well: to calculate $h_{\theta}(x^{(s)})$, do we use the old value $\theta_1$ or the updated value $\hat{\theta}_1$?
Question 2: I've read that a random sample is chosen in each update. Is that same random sample used for the update of all the $\theta_j$'s (i.e. is $r$ necessarily equal to $s$), or is a different random sample chosen for calculating the update to each $\theta_j$ (i.e. $r$ may not be the same as $s$)?
Please correct me if I got any of the theory wrong. Apologies if the question is too verbose or if this has been asked in part, but I've tried browsing many related questions and these things weren't addressed in those, as far as I could see.