Catalyzes the formation of pyridoxal 5'-phosphate from ribose 5-phosphate (RBP), glyceraldehyde 3-phosphate (G3P) and ammonia. The ammonia is provided by the PdxT subunit. Can also use ribulose 5-phosphate and dihydroxyacetone phosphate as substrates, resulting from enzyme-catalyzed isomerization of RBP and G3P, respectively. aldehydo-D-ribose 5-phosphate + D-glyceraldehyde 3-phosphate + L-glutamine = H(+) + 3 H2O + L-glutamate + phosphate + pyridoxal 5'-phosphate Cofactor biosynthesis; pyridoxal 5'-phosphate biosynthesis. In the presence of PdxT, forms a dodecamer of heterodimers. Belongs to the PdxS/SNZ family.