We constrain a unified dark matter ( UDM ) model from the latest observational data . This model assumes that the dark sector is degenerate . Dark energy and dark matter are the same component . It can be described by an affine equation of state P _ { X } = p _ { 0 } + \alpha \rho _ { X } . Our data set contains the newly revised H ( z ) data , type Ia supernovae ( SNe Ia ) from Union2 set , baryonic acoustic oscillation ( BAO ) observation from the spectroscopic Sloan Digital Sky Survey ( SDSS ) data release 7 ( DR7 ) galaxy sample , as well as the cosmic microwave background ( CMB ) observation from the 7-year Wilkinson Microwave Anisotropy Probe ( WMAP7 ) results . By using the Markov Chain Monte Carlo ( MCMC ) method , we obtain the results in a flat universe : \Omega _ { \Lambda } = 0.719 _ { -0.0305 } ^ { +0.0264 } ( 1 \sigma ) _ { -0.0458 } ^ { +0.0380 } ( 2 \sigma ) , \alpha = 1.72 _ { -4.79 } ^ { +3.92 } ( 1 \sigma ) _ { -7.30 } ^ { +5.47 } ( 2 \sigma ) ( \times 10 ^ { -3 } ) , \Omega _ { b } h ^ { 2 } = 0.0226 _ { -0.0011 } ^ { +0.0011 } ( 1 \sigma ) _ { -0.0015 } ^ { +0.0016 } ( 2 \sigma ) . Moreover , when considering a non-flat universe , \Omega _ { \Lambda } = 0.722 _ { -0.0447 } ^ { +0.0362 } ( 1 \sigma ) _ { -0.0634 } ^ { +0.0479 } ( 2 \sigma ) , \alpha = 0.242 _ { -0.775 } ^ { +0.787 } ( 1 \sigma ) _ { -1.03 } ^ { +1.10 } ( 2 \sigma ) ( \times 10 ^ { -2 } ) , \Omega _ { b } h ^ { 2 } = 0.0227 _ { -0.0014 } ^ { +0.0015 } ( 1 \sigma ) _ { -0.0018 } ^ { +0.0021 } ( 2 \sigma ) , \Omega _ { k } = -0.194 _ { -1.85 } ^ { +2.02 } ( 1 \sigma ) _ { -2.57 } ^ { +2.75 } ( 2 \sigma ) ( \times 10 ^ { -2 } ) . These give a more stringent results than before . We also give the results from other combinations of these data for comparison . The observational Hubble parameter data can give a more stringent constraint than SNe Ia . From the constraint results , we can see the parameters \alpha and \Omega _ { k } are very close to zero , which means a flat universe is strongly supported and the speed of sound of the dark sector seems to be zero .