Hubble by Deck
Search
⌃K

campaign

This table includes a single row for almost every campaign in state and federal elections since 2010. It includes the candidate’s name, party affiliation, and incumbency status. It also includes foreign keys to our `district` and `election` tables.
A given candidate might have many entries in this table. For example, as of December 19, 2020, Alexandria Ocasio-Cortez has four entries. That includes one entry for each of her congressional primaries and general election contests. Each of those entries would share the same candidate_id and district_id, but have unique values for campaign_id and election_id.

Schema

Field
Description
campaign id
Unique ID maintained by Deck representing a specific campaign. We define a campaign as an instance of a specific candidate running for a specific office or party nomination. If the same candidate ran in a primary and general election in both 2018 and 2020, they would have four campaign entries across those contests.
candidate id
Unique ID maintained by Deck representing a specific person running for a specific office in a specific district, which is kept the same across elections.
district id
Unique ID maintained by Deck representing a specific political district. We define a district as a geographic subdivision of a jurisdiction that is associated with a specific office. For example, Idaho State House District 2 is a single district. Its associated office is Idaho State House and its associated jurisdiction is Idaho. (For jurisdiction-wide offices, like Governor and Mayor, the district can encompass the entirety of its jurisdiction.)
election id
Unique ID maintained by Deck representing a specific election. We define an election as an opportunity for registered voters in a given jurisdiction to cast a ballot for one or more offices.
election date
The election date of a given campaign as a float ex. 20221108.0.
office name
Proper case office name such as U.S. Senate, U.S. House and State House.
district name
The name of a given district. Georgia State House District 2 will be named “2,” for example.
name first primary
A candidate’s primary first name -- typically their legal first name.
name first alternate
A candidate’s alternate first name, if applicable. This would typically be a nickname.
name middle
A candidate’s middle name.
name last primary
A candidate’s primary last name -- typically their full, legal last name.
name last alternate
A candidate’s alternate last name, if applicable. This could be a maiden name, an alternate presentation of a hyphenated or accented name, or a variation of the primary last name in the event of ambiguity.
incumbency status
A value of “incumbent” if the candidate is currently holding the office in question, “challenger” if the candidate is running against the current office-holder, or “open” if the current office-holder is not running for the office.
party affiliation
The candidate’s stated party affiliation. Note: if a candidate is on the ballot in affiliation with multiple parties (such as the Working Families Party, which is a common second ballot line for New York progressives), we only include one party here: the one with the most electoral success.

Example entry

[
{
"campaign_id": "27832a43-f102-472c-9c08-9c08f4a15599",
"district_id": "d21a75f8-ffd7-4695-85df-edc58a8784f6",
"election_id": "35d9bed4-3181-4914-be67-a3bd9cf73e63",
"election_date": "20221108",
"office_name": "State House",
"district_name": "15",
"name_first_primary": "PETER",
"name_first_alternate": "PETE",
"name_middle": "J",
"name_last_primary": "ABBATE",
"name_last_alternate": null,
"incumbency_status": "incumbent",
"party_affiliation": "DEMOCRATIC"
}
]