Correcting for auto-correlation when using a lagged DV in the regression I am conducting a regression where in I have data at the quarterly level for 19 companies (I have data ranging from 2007-2019 so about  30-50 quarters for each company). My regression model in STATA is as follows:
DV (in quarter t+1) = constant + IV (in quarter t) + Controls (in quarter t) + Lag DV (i.e DV in quarter t) + error
IV stands for independent variable and DV for dependent variable. The lagged DV is just a control variable and not my main variable of interest. The main variable of interest is the IV (in quarter t). I run the above using quarter and firm fixed effects and robust standard errors.
Question - does the inclusion of lagged DV bias all coefficients or just the coefficient on lagged DV? I know I should control for some sort of autocorrelation but how can I do that (eg. using prais command?). Is there anything else I can do to test the robustness of my results.
Any help is appreciated
 A: Not a complete answer but maybe we can analyze this by partitioned regression:
$$\mathbf{y_t}=\mathbf{X}\beta+\phi \mathbf{y_{t-1}}+\mathbf{e_t}$$
OLS estimate, $\hat{\beta}$ would be:
$$\hat{\beta}=(\mathbf{X'X})^{-1}\mathbf{X'}(\mathbf{y_t-\hat{\phi}y_{t-1}})=(\mathbf{X'X})^{-1}\mathbf{X'}(\mathbf{X}\beta+(\phi-\hat{\phi})\mathbf{y_{t-1}+e_t})$$
Therefore,
\begin{align}
E(\hat{\beta})&=\beta+\phi (\mathbf{X'X})^{-1}\mathbf{X'}\big(E(\mathbf{y_{t-1}})-E(\hat{\phi}\mathbf{y_{t-1}})\big)
\\&=\beta + \beta\frac{\phi}{1-\phi}+(\mathbf{X'X})^{-1}\mathbf{X'}E(\hat{\phi}\mathbf{y_{t-1}})
\\&=\frac{\beta}{1-\phi}+ (\mathbf{X'X})^{-1}\mathbf{X'}E(\hat{\phi}\mathbf{y_{t-1}})
\end{align}
I am unable to show that the term $E(\hat{\phi}\mathbf{y_{t-1}})$ would not be $0$, but I think because $\hat{\phi}$ is a function of $y_t$, there will be a lingering variance term in this and so it would not be $0$. If correct, then it seems the other parameter estimates are also biased.
(I tried searching for OLS estimation and inference of ARIMAX models but couldn't find anything; also the above results are based on simple OLS and not for robust standard errors)
