1. A method for distributing a query, wherein the query comprises a plurality of sub-clauses, wherein each sub-clause comprises a triple pattern having three components for use with a distributed system, the method comprising: identifying each sub-clause; analysing three components of each sub-clause in accordance with analysis rules in order to determine a proportion of values to variables in each of the sub-clause; in response to the determination of the proportions of values to variables, testing at least one of the plurality of sub-clauses against execution rules based, at least partly, on the proportion of values to variables of the at least one sub-clause, wherein the execution rules define an order of processing of a sub-clause based on a proportion of values to variables; and in response to the testing, generating a sub-query based on a first sub-clause of the plurality of sub-clauses having the largest of the proportions of values to variables.