Table:
0
A
B
C
D
E
F
1
District
Incumbent
Party
First elected
Result
Candidates
2
Virginia 1
None (District created)
None (District created)
None (District created)
New seat Democratic-Republican gain
John G. Jackson (DR) Thomas Wilson (F)
3
Virginia 3
John Smith Redistricted from the 1st district
Democratic-Republican
1801
Re-elected
John Smith (DR) 89.9% Joseph Sexton (DR) 10.1%
4
Virginia 4
David Holmes Redistricted from the 2nd district
Democratic-Republican
1797
Re-elected
David Holmes (DR) Isaac Van Meter (F)
5
Virginia 6
Abram Trigg Redistricted from the 4th district
Democratic-Republican
1797
Re-elected
Abram Trigg (DR)
6
Virginia 8
None (District created)
None (District created)
None (District created)
Democratic-Republican gain
Walter Jones (DR) James Ball (F)
7
Virginia 10
John Dawson Redistricted from the 15th district
Democratic-Republican
1797
Re-elected
John Dawson (DR) William I. Callis (F)
8
Virginia 11
Anthony New Redistricted from the 16th district
Democratic-Republican
1793
Re-elected
Anthony New (DR) 71.4% John Taylor (F) 28.6%
9
Virginia 13
John J. Trigg Redistricted from the 5th district
Democratic-Republican
1797
Re-elected
John J. Trigg (DR)
10
Virginia 14
Matthew Clay Redistricted from the 6th district
Democratic-Republican
1797
Re-elected
Matthew Clay (DR) 88.9% James Hurt (F) 11.1%
11
Virginia 16
None (District created)
None (District created)
None (District created)
New seat Democratic-Republican gain
John W. Eppes (DR)
12
Virginia 18
None (District created)
None (District created)
None (District created)
New seat Democratic-Republican gain
Peterson Goodwyn (DR) 66.9% James Jones (F) 33.1%
13
Virginia 19
Edwin Gray Redistricted from the 10th district
Democratic-Republican
1799
Re-elected
Edwin Gray (DR)

Questions and formulas:
Question: How many times was the incumbent john dawson redistricted from the 15th district?
Formula: ROWS(UNIQUE(FILTER(F1, B1="John Dawson Redistricted from the 15th district")))
Formula2: ROWS(UNIQUE(FILTER(F2:F13, B2:B13="John Dawson Redistricted from the 15th district")))
Level: medium
Question: What is the party for the candidates edwin gray (dr)?
Formula: UNIQUE(CHOOSECOLS(FILTER(A1:F1,F1="Edwin Gray (DR)"),3))
Formula2: UNIQUE(CHOOSECOLS(FILTER(A2:F13,F2:F13="Edwin Gray (DR)"),3))
Level: medium
Question: What is the result in the virginia 11 district?
Formula: UNIQUE(CHOOSECOLS(FILTER(A1:F1,A1="Virginia 11"),5))
Formula2: UNIQUE(CHOOSECOLS(FILTER(A2:F13,A2:A13="Virginia 11"),5))
Level: medium
Question: What is the district with the candidates edwin gray (dr)?
Formula: UNIQUE(CHOOSECOLS(FILTER(A1:F1,F1="Edwin Gray (DR)"),1))
Formula2: UNIQUE(CHOOSECOLS(FILTER(A2:F13,F2:F13="Edwin Gray (DR)"),1))
Level: medium
Question: How many incumbents were first elected in 1797 with the candidates abram trigg (dr)?
Formula: ROWS(UNIQUE(FILTER(B1, (D1=1797)*(F1="Abram Trigg (DR)"))))
Formula2: ROWS(UNIQUE(FILTER(B2:B13, (D2:D13=1797)*(F2:F13="Abram Trigg (DR)"))))
Level: medium