The main rule in these kind of equations is "what you do to one side you must do to the other"
With this being the case instead of subtracting on one side and adding on the other, you need to add 12 on both sides to get your answer.
34=y-12
+12 +12
----------------
46=y