Podcast #128: We chat with Kent C Dodds about why he loves React and discuss what life was like in the dark days before Git. Listen now.
2 Saved 2 bytes due to Razvan's suggestion
source | link

T-SQL, 8080 78 bytes

SELECT-1n INTO t;INSERT t VALUES(0),(1)SELECT * FROMSELECT*FROM t,t z WHERE t.n<>0OR z.n<>0

Creates a (permanent) table t containing (-1,0,1), and performs a self-join with a WHERE clause that excludes the 0,0 row. The table t is not cleaned up by my code, you must drop it yourself.

Sadly nearly twice as long as the boring solution (44 bytes), since SQL allows returns in strings:

PRINT'0,1
0,-1
1,0
-1,0
1,1
1,-1
-1,1
-1,-1'

T-SQL, 80 bytes

SELECT-1n INTO t;INSERT t VALUES(0),(1)SELECT * FROM t,t z WHERE t.n<>0OR z.n<>0

Creates a (permanent) table t containing (-1,0,1), and performs a self-join with a WHERE clause that excludes the 0,0 row. The table t is not cleaned up by my code, you must drop it yourself.

Sadly nearly twice as long as the boring solution (44 bytes), since SQL allows returns in strings:

PRINT'0,1
0,-1
1,0
-1,0
1,1
1,-1
-1,1
-1,-1'

T-SQL, 80 78 bytes

SELECT-1n INTO t;INSERT t VALUES(0),(1)SELECT*FROM t,t z WHERE t.n<>0OR z.n<>0

Creates a (permanent) table t containing (-1,0,1), and performs a self-join with a WHERE clause that excludes the 0,0 row. The table t is not cleaned up by my code, you must drop it yourself.

Sadly nearly twice as long as the boring solution (44 bytes), since SQL allows returns in strings:

PRINT'0,1
0,-1
1,0
-1,0
1,1
1,-1
-1,1
-1,-1'
1
source | link

T-SQL, 80 bytes

SELECT-1n INTO t;INSERT t VALUES(0),(1)SELECT * FROM t,t z WHERE t.n<>0OR z.n<>0

Creates a (permanent) table t containing (-1,0,1), and performs a self-join with a WHERE clause that excludes the 0,0 row. The table t is not cleaned up by my code, you must drop it yourself.

Sadly nearly twice as long as the boring solution (44 bytes), since SQL allows returns in strings:

PRINT'0,1
0,-1
1,0
-1,0
1,1
1,-1
-1,1
-1,-1'