Test 1v1 Tournament

0

Please login or register to vote for this query.

(click on this box to dismiss)

Cognitive Sciences Meta

Q&A about the site for practitioners, researchers, and students in cognitive science, psychology, neuroscience, and psychiatry

DECLARE @Players TABLE (
	ID INT PRIMARY KEY IDENTITY,
	Name VARCHAR(50)
)

DECLARE @Matches TABLE (
	ID INT PRIMARY KEY IDENTITY,
	WinnerId INT,
    LoserId INT
)

DECLARE @Comments TABLE (
	ID INT PRIMARY KEY IDENTITY,
	MatchId INT,
    Comment VARCHAR(MAX)
)

INSERT INTO @Players VALUES ('Alex')
INSERT INTO @Players VALUES ('Bob')
INSERT INTO @Players VALUES ('Chris')
INSERT INTO @Players VALUES ('Dave')

INSERT INTO @Matches VALUES (1,2)
INSERT INTO @Matches VALUES (4,2)
INSERT INTO @Matches VALUES (3,1)

INSERT INTO @Comments VALUES (2,'That was a close one.')
INSERT INTO @Comments VALUES (3,'I did not expect that outcome.')

SELECT * FROM @Players
SELECT * FROM @Matches
SELECT * FROM @Comments

Enter Parameters

Options:
Switch sites:
loading Hold tight while we fetch your results