Your SQL command was:
SELECT TOP 10 u,g,r,i,z,ra,dec, flags_r 
FROM Star 
WHERE 
 ra BETWEEN 180 and 181 AND dec BETWEEN -0.5 and 0.5
 AND ((flags_r & 0x10000000) != 0)
 AND ((flags_r & 0x8100000c00a4) = 0) 
 AND (((flags_r & 0x400000000000) = 0) or (psfmagerr_r <= 0.2))
 AND (((flags_r & 0x100000000000) = 0) or (flags_r & 0x1000) = 0)

Your query output (max 500,000 rows):

ugrizradecflags_r
24.4675323.9470722.4282322.472522.66874180.318260353763-0.1160054909603332310346883987406864
23.9711125.3612323.2036423.1407422.09952180.126098802501-0.11818531304416513511074062008336
24.3601423.6512422.4026621.3537320.51018180.648263938195-0.01704162054928994503874773712896
25.0168423.5498722.7978622.629422.92391180.078966599624-0.1015842194268974503599929360400
20.8568718.221716.7945916.0473115.66583180.818894296891-0.1661487450104124503599895838720
23.5804224.3319122.6536123.1223622.3844180.272540333379-0.1230559642822384503874773712896
24.4055725.2540622.8247624.6423623.33592180.7398875804040.2950161903042514503874907930624
21.7359420.6977720.5808620.505121.37477180.733447186332-0.04636656464882764503599895805968
22.3973321.8507322.0370122.6815622.98813180.196975632546-0.01794321997992864503874807300112
25.0526125.1368923.3601724.3693922.48689180.0731370914720.2859990635688664503874807267344