We embed a simple contracting model with ex-ante investments in which there is scope for Court intervention in a full-blown open-ended dynamic setting. The underlying preferences of both Courts and contracting parties are fully forward looking and unbiased. Our point of departure is instead the observation that when Courts intervene in a contractual relationship they obviously do so at the ex-post stage. This introduces a natural tension between actual Court behavior and ex-ante optimal Court decisions. In a Case Law regime each Court is tempted to behave myopically because, ex-post, this affords current extra gains from trade. This temptation is traded off against the effect of its ruling, as a precedent, on future ones. We model the Statute Law regime in an extreme way: no discretion is left to the Courts which behave according to fixed rules. This solves the time-inconsistency problem afflicting the Case Law Courts, but is costly because of its lack of flexibility. We find that when the nature of the environment changes sufficiently often through time the Case Law regime is superior, while when the environment does not change very often the Statute Law regime dominates. Overall, our findings support the view that the Case Law regime is superior in fields in which innovation, and hence change, is central (e.g. finance), while the Codified Law regime is superior in more slow-changing ones (e.g. inheritance law).