You are correct about the law, but that is also an idealized statement. They do use precedent as well in Germany. Judges do draw from previous comparable verdicts. A previous failed attempt can significantly lower chances for a future success in a similar case. For each book of law, you can buy books with commentary, relating to previous cases and what their outcome was. This has actual influence on future verdicts.