把这个功能转化成MYSQL,我不会MYSQL,在线!请牛人帮帮忙!
declare @sql varchar(8000)
set @sql=''
declare @index int
set @index=1
while @index<11
begin
set @sql='select type_value'+@index'+ from tempTable where type_type'+@index+' in(4,5,6)'
execute(@sql)
set @index=@index+1
end