The Swedish situation is... confusing. :-) There are first names ("förnamn"), possibly more than one. The one in daily use — not necessarily the first one! — is called "tilltalsnamn" (something like "addressing name"), and is traditionally marked in official paperwork by underlining or with an asterisk. (You know someone has not done their homework when you get junk mail that starts with "Dear <Wrongname>!) Then there used to be middle names ("mellannamn"), which was something put between the first and last names. These were typically used e.g. by people who wanted to have both their own and their spouse's name. These are no longer issued, though those who have them can keep them. Instead, you can now have a double last name, which used to be impossible. (People have sported "double-barrelled surnames" for ages, but they have not, as far as I can understand, been officially recognised, but functioned more like "stage names").
The confusing bit is that the rules about middle names and double surnames have changed at least twice in... my lifetime, which is becoming much longer than I care to think about. :-) I didn't do a very good job of conveying that in my comment.
Small nitpick, if you are* in Germany but have an e.g. Spanish name (e.h. Hector Garcia Gonzalez) then... that's 2 surnames without a dash. I have no idea what happens if you marry or have children, but your example is just the -most basic- version.
*"you are" meaning you'd be a German citizen with a German passport.
> I have no idea what happens if you marry or have children
When you marry, you get to define what is going to be the family name and then children born from that marriage get to be registered with that family name.
In the case of foreign-born people, they can keep the naming rules from their original country. In the case of the marriage between foreigners from two different countries, you have to choose which rules are you going to follow, but the family name stays fixed.
To us (Brazilian marrying a Greek) it was a very interesting process. I have two last family names, and Greek names are gender-conjugated (i.e, the last name changes whether you are a boy or a girl). It the end the simplest thing to do was to just keep only one my last family names.
Is it that rare? I have two middle names (William Howard) and I never thought much of it. As a kid, I was more amused by a friend of my sister's who had a quadruple-barrelled surname...