mysql_real_escape_string / Говнокод #22306 Ссылка на оригинал

0

  1. 1
  2. 2
  3. 3
  4. 4
  5. 5
  6. 6
  7. 7
  8. 8
  9. 9
  10. 10
  11. 11
with cteTypes (TypeId)
as (
			  select 4 
	union all select 5 
	union all select 6 
	union all select 9 
	union all select 1 			
) 
select *
from dbo.SomeTable tbl
    cross join ( select TypeId from cteTypes ) t ( TypeId )

Великолепный CROSS JOIN.
Не пишите так, можно просто:
cross join cteTypes
и все!

Запостил: qsmart qsmart, (Updated )

Комментарии (2) RSS

Добавить комментарий

Переведи на "PHP", guest!

    А не использовать ли нам bbcode?


    8