1. A system for executing complex procedural queries across a plurality of databases, the system comprising one or more processors configured to function as: a query processor configured to iteratively execute a complex procedural query defined using a general-purpose functional programming language, the complex procedural query comprising a top-level complex procedural query and sub-queries; a set of database adaptors configured to optimize and refer collections of queries, corresponding to the complex procedural query, to external databases; and a query cache in communication with the query processor and the set of database adaptors, the query cache configured to store results of the external database queries in the query cache and note unresolved data which the complex procedural query needs but does not have; wherein the query processor is configured to detect a soft failure, wherein the query processor is configured to execute a subsequent iteration of the entire complex procedural query, if unresolved data is noted from a previous iteration of the complex procedural query, using the stored results, wherein the complex procedural query is severable such that at least a first portion of the complex procedural query can proceed even if a second portion of the complex procedural query fails.