9. The computer implemented method of claim 1 , wherein the describing step, matching step, and generating step are performed by a XQuery generator that sends the automatically generated sentences to the query processing engine.
1. A computer implemented method for automatically generating a query to test a query processing engine that processes queries received by the query processing engine, the computer implemented method comprising: describing data and occurrence using a sequence type; matching the data and the occurrence from the sequence type to a sequence type pattern; automatically generating, by a computer processor, sentences in a query language using the sequence type pattern; testing an ability of the query processing engine to interpret queries using the sentences that are automatically generated by the computer implemented method; defining a grammar wherein the grammar uses the sequence type pattern to drive sentence generation by producing a plurality of tokens in the grammar automatically, wherein the plurality of tokens is consistent with the sequence type pattern, and translating the plurality of tokens into a syntactically valid query in a target language automatically; and defining the sequence type pattern wherein the sequence type pattern abstracts a class of query.