It is hard to believe that in this day and age, a municipality would allow a second story deck to be constructed without bolting it to the house. On the second story this is super dangerous.
This is just another example of why even newer houses need to have a home inspection when you purchase them.
This is it very easy problem to fix. Just install bolts. Otherwise someday this deck could pull away from the house and let the occupants fall 12 feet to the ground.