Transit visa question in schengen is a very common and frequently asked question here. The answer lies here

I am referring to the official European union publication, which is precise and clear.
http://ec.europa.eu/dgs/home-affairs/what-we-do/policies/borders-and-visas/visa-policy/docs/frequently_asked_questions_en.pdf

> **I have connecting flights, with a stop at a Schengen state airport. Do I have to apply for an airport transit visa or a short stay visa?**
> 
> It is important to distinguish between two situations:
> 
> 1. transit through the international transit area of an airport (onward journey where you do not leave the international transit area
> of the airport)
> 2. transit via the territory of a Member State albeit limited to an airport (onward journey where you leave the international transit area
> of the airport).
> 
> An airport transit visa (ATV) authorises you to pass through the
> international transit zone at an airport located on the territory of
> the Schengen State and to await a connecting flight to a non-Schengen
> country. The ATV does not allow you to enter the Schengen territory
> (to stay at a hotel or to take an onwards flight to another Schengen
> State, for example). To find out whether you need an airport transit
> visa, you can consult the overview on our website, click here.
> 
> Traveling to a Schengen State via another Schengen State airport is
> not considered an airport transit neither is travelling to a
> non-Schengen country via two Schengen state airports. All flights
> between two or more Schengen States are considered to be «domestic»
> flights. Depending on your nationality, you might need a short stay
> visa as you enter the Schengen area – even if the stay only lasts a
> few hours and you remain in the airport (outside the international
> transit zone).

**List of Countries requiring transit visa**: http://ec.europa.eu/dgs/home-affairs/e-library/documents/policies/borders-and-visas/visa-policy/docs/annex_7b_atv-national_lists.en.pdf#zoom=100 (scroll down the pdf to see)

> **Can I enter the Schengen area in country X, while the visa was issued by Schengen country Y?**
> 
> As a general rule you may cross any Schengen border with visa issued
> by any Schengen country. However, the short-stay visa does not
> automatically entitle you to enter the Schengen area. See FAQ no 16 on
> checks at the external borders.