As of May 3rd, the German pig census was around 26.9 million heads, according to the Federal Statistical Office (Destatis), this entailing a drop by some 690,000 animals (-2.5%), after having grown by 1.5% in November 2017.
Among other factors, the drop in the number of fattening pigs has contributed to this fall, with a census of 11.8 million animals: a drop by 3.2% with respect to November 2017, when the census reached 12.2 million heads. In North Rhine-Westphalia and Lower Saxony, the two federal states with the highest pig population, the census fell by 3.3% and 2.1%, respectively.

The number of pig farms also continued to drop in Germany, that has a few less than 23,000: a decrease by 2.3% with respect to November 2017.
Thursday, June 28th, 2018/ Destatis/ Germany.
https://www.destatis.de