Sometimes the hammer from the second floor does not work on the door it is supposed to be used. The chances to this to appear are random, and unfortunately for me (along with other stuff) I can't fix it. But here's a small tutorial which will (so far as I'm concerned) work every time. IT IS IMPORTANT TO HAVE THE HAMMER SINCE IT IS REQUIRED IN THE FURTHER PUZZLES.
1. Leave the game without saving (it's quick to play again from that spot)
2. Open your level editor. Look in the upper left corner. Click File -> Open and then browse through the files until you find Amnesia's custom story folder. Open Amnesia - Orion -> maps -> NewStoryMap1.map
3. Go to the "Entity" category. This is represented as the grey ghost on the very left side of the editor.
4. From the "Entities" category find "items", and from there, choose "stone_hammer". Place it anywhere you want in the editor. After you have placed it, click it. You will see the text field "Name". In there, write simply the word "Hammer", and press enter to save it. Then, save the map by either going to upper left corner -> File -> Save, or simply by pressing LCTRL + S.
5. Now as you start the story, the item should be where you placed it and you can proceed from the door.
If you have any problems with the editor, or any other trouble then please comment down and I will help.