Microsoft SQL Derived Table
-- Derived tables are inner subqueries within the from statement of the outer query
select product, productCounter
from
(
select [Product], count(*) as ProductCounter
from [test].[dbo].[options on fx majorsii]
group by Product
) as ProductDerivedTable
where ProductCounter>2

-- Derived tables are inner subqueries within the from statement of the outer query
select product, productCounter
from
(
select [Product], count(*) as ProductCounter
from [test].[dbo].[options on fx majorsii]
group by Product
) as ProductDerivedTable
where ProductCounter>2
No comments:
Post a Comment