On a judgment for the plaintiff upon an issue of law, he may proceed in the manner prescribed by the first two subdivisions of Section 585, upon the failure of the defendant to answer. If judgment be for the defendant upon an issue of law, and the taking of an account, or the proof of any fact, be necessary to enable the Court to complete the judgment, a reference may be ordered, as in that section provided.