If you buy a piece of property/a house that you are NOT living in, it is considered a "speculation," and is thus, when sold, subject to a special speculation tax--IF you hold it for less than ten years. Hold it for more than ten years, there is no tax. If you actually live in the house, or have lived in it, then the sale is tax-exempt. But you can't have ten properties you live in at once. German law provides for a "primary residence" and a "secondary residence." You can't have a secondary residence inside Germany if your primary residence is not. The "Speculation tax" is usually calculated at the rate one would have paid in income tax without the speculation profit.
I actually think it is one instance where I agree with them. If you are actually living in a house, its value is of secondary consideration. If you luck out when you want to sell it or not, the government shouldn't penalize you for an increase of value. If you buy a house purely as an investment speculation, that is a different story, and you may be able to rent it out before you sell, it, too. If you buy/sell three or more properties a year, you are considered to be running a business, and have to register as such. On the other hand, if you buy a property and hold it for ten years or more, you are considered to be making a long-term speculation, the sale of which is then tax-free.
Germany has several laws like this. I was affected twice. I had two instances of something I owned for more than the German period that made the investment (not exactly, but close enough) tax-free in Germany, but not in the USA, where I was hit for 31.8% in taxes on the gain in each case.