Catalysis of the reaction: 2 ATP + L-glutamine + CO2 + H2O = 2 ADP + phosphate + glutamate + carbamoyl phosphate.
hydrogen-carbonate:L-glutamine amido-ligase (ADP-forming, carbamate-phosphorylating) activity