create table #e ( [year] int, [avg] int ); insert into #e...

0

Please login or register to vote for this query.

(click on this box to dismiss)

Woodworking

Q&A for professional and amateur woodworkers

create table #e (
    [year] int,
    [avg] int
);
insert into #e ([year], [avg])
values (
    2007,
    (
        select avg(score) from posts where year(creationdate) = 2007
    )
)
select * from #e

Enter Parameters

Options:
Switch to meta site
loading Hold tight while we fetch your results