join example

0

Please login or register to vote for this query.

(click on this box to dismiss)

Skeptics

Q&A for scientific skepticism

create table #test (
id int
)

create table #test2 (
id int
)

insert into #test values(1)
insert into #test values(2)
insert into #test values(3)
insert into #test values(null)


insert into #test2 values(-1)
insert into #test2 values(1)
insert into #test2 values(3)
insert into #test2 values(4)
insert into #test2 values(null)

select * from #test
cross join #test2 --on #test.id=#test2.id

Enter Parameters

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