The spectroscopic Sloan Digital Sky Survey ( SDSS ) Data Release 7 ( DR7 ) galaxy sample represents the final set of galaxies observed using the original SDSS target selection criteria . We analyse the clustering of galaxies within this sample , including both the Luminous Red Galaxy ( LRG ) and Main samples , and also include the 2-degree Field Galaxy Redshift Survey ( 2dFGRS ) data . In total , this sample comprises 893 319 galaxies over 9 100 deg ^ { 2 } . Baryon Acoustic Oscillations are observed in power spectra measured for different slices in redshift ; this allows us to constrain the distance–redshift relation at multiple epochs . We achieve a distance measure at redshift z = 0.275 , of r _ { s } ( z _ { d } ) / D _ { V } ( 0.275 ) = 0.1390 \pm 0.0037 ( 2.7 % accuracy ) , where r _ { s } ( z _ { d } ) is the comoving sound horizon at the baryon drag epoch , D _ { V } ( z ) \equiv [ ( 1 + z ) ^ { 2 } D _ { A } ^ { 2 } cz / H ( z ) ] ^ { 1 / 3 } , D _ { A } ( z ) is the angular diameter distance and H ( z ) is the Hubble parameter . We find an almost independent constraint on the ratio of distances D _ { V } ( 0.35 ) / D _ { V } ( 0.2 ) = 1.736 \pm 0.065 , which is consistent at the 1.1 \sigma level with the best fit \Lambda CDM model obtained when combining our z = 0.275 distance constraint with the WMAP 5-year data . The offset is similar to that found in previous analyses of the SDSS DR5 sample , but the discrepancy is now of lower significance , a change caused by a revised error analysis and a change in the methodology adopted , as well as the addition of more data . Using WMAP5 constraints on \Omega _ { b } h ^ { 2 } and \Omega _ { c } h ^ { 2 } , and combining our BAO distance measurements with those from the Union Supernova sample , places a tight constraint on \Omega _ { m } = 0.286 \pm 0.018 and H _ { 0 } = 68.2 \pm 2.2 { km } { s } ^ { -1 } { Mpc } ^ { -1 } that is robust to allowing \Omega _ { k } \neq 0 and w \neq - 1 . This result is independent of the behaviour of dark energy at redshifts greater than those probed by the BAO and supernova measurements . Combining these data sets with the full WMAP5 likelihood constraints provides tight constraints on both \Omega _ { k } = -0.006 \pm 0.008 and w = -0.97 \pm 0.10 for a constant dark energy equation of state .