There were a number of precedents for Caesar requesting to be allowed to stand for the consulship in absentia. However, it was outlawed sometime after 71 BC and before 60 BC. Cato the Younger was instrumental in opposing Caesar's attempt to stand in absentia in 50 BC, just as he had opposed Pompey's attempt in 62 BC.
Among the more notable names who succesfully stood for consul in absentia are Marius (in 105 BC, 104 BC, 102 BC), and Pompey and Crassus (both in 70 BC). There was also one consul-elect in absentia, Lucius Postumius Albinus (216 BC), who was killed in battle before he could take office.
The source for the election in absentia of Gaius Marius, which happened in 105 BC, 104 BC and 102 BC, is Plutarch. This is mentioned in his Life of Marius (in 105 BC, for consul in 104 BC):
...the people would have nothing to do with anyone of high birth or of
a wealthy house who offered himself at the consular elections, but
proclaimed Marius consul in spite of his absence from the city.
and (in 104 BC, for consul in 103 BC) Marius
...was appointed consul for the second time, although the law
forbade that a man in his absence and before the lapse of a specified
time should be elected again; still, the people would not listen to
those who opposed the election.
For the 102 BC election for consul in 101 BC, Plutarch says that Marius received the news of his election shortly after a battle near Massalia (modern-day Marseilles).
Earlier, Lucius Postumius Albinus, was elected consul for a third time in 216 BC for the year 215 BC while in Cisalpine Gaul where he was leading an army against Gallic allies of Hannibal during the Second Punic War.
However, before he could take office, his army was ambushed in a forest at the Battle of Silva Litana not long after the Roman disaster at Cannae. Postumius' army was almost totally destroyed and, according to Livy, the consul-elect died fighting to avoid capture.
Pompey and Crassus were also elected in absentia for the consulship in 70 BC. The original source for this is Appian (Book 1. 121). In Pompey's Consulships and the End of Electoral Competition, Richard Evans of the University of South Africa states that
In late 71 after the Spartacus revolt had been suppressed and the war
in Spain against Sertorius concluded, Pompey and Crassus canvassed for
the consulship, and were elected without opposition....during the run
up to the elections, both Pompey and Crassus had to remain outside the
city since neither could canvass as they each continued to command
armies cum imperio....the presiding magistrate by virtue of his own
imperium need not have accepted either candidacy, but there were
numerous precedents for candidacies in absentia.
Pompey and Crassus' election in absentia is also mentioned by Matthew Dillon & Lynda Garland in Ancient Rome: A Sourcebook. In a footnote, Evans also mentions that Marcus Antonius and Titus Didius waited outside Rome for their triumphs
in 100/99 while campaigning for their consulships of 99 and 98.
Pompey, however, was opposed by Cato the Younger (but supported by Caesar) when he attempted to stand for consul in absentia in 62 BC.
Caesar's request in 50 BC was not his first attempt to stand in absentia. Evans, again in a footnote, states:
When Caesar tried to emulate Pompey or rather Crassus in 60 his
candidacy was initially disallowed and he forfeited his triumph in
order to canvass in person. The law appears to have changed after 71
and in absentia candidacies were not allowed by 60 BC. The lex is
Caesar, who had supported Pompey's attempt in 62 BC, probably expected the latter to support his attempt in 50 BC but Pompey declined to take sides.