Data source queries may be specified in various languages, such as SQL, XQuery, and object-oriented languages, and each language may have various linguistic features that enable different types of queries. It may be advantageous to formulate mixed language queries having portions specified in a first language and portions specified in a second language, and to provide mixed language query evaluation components that can parse portions of queries of different languages. It may also be advantageous to permit the translation of single language queries into multiple languages to be parsed by such mixed language query evaluation components. Such techniques may permit queries to utilize linguistic features and processing techniques of one language that are less efficient, less direct, or simply unavailable in another language.
Legal claims defining the scope of protection, as filed with the USPTO.
1. A method of issuing, from a device having a processor, a query specified in a first language to a query processor configured to parse mixed language queries having query components specified in the first language and query components of specified in a second language that is different from the first language, the method comprising: executing on the processor instructions configured to: translate a translation portion of the query into a second language portion specified in the second language; combine a remainder portion of the query excluding the translation portion and the second language portion to generate a mixed language query; and send the mixed language query to the query processor.
2. The method of claim 1 , comprising: translating the remainder portion of the query into a query language portion specified according to a query language that is different from the first language and the second language.
3. The method of claim 2 , at least one of the second language portion and the query language portion configured to generate a processed query portion that is compatible with the other of the second language portion and the query language portion.
4. The method of claim 1 , comprising: translating a third portion of the query into a third language portion specified in a third language that is different from the first language and the second language, and the combining comprising: combining the remainder portion, the second language portion, and the third language portion to generate the mixed language query.
5. The method of claim 1 : the combining comprising: generating a mixed language expression tree comprising the remainder portion and the second language portion; and the sending comprising: sending the mixed language expression tree to the query processor.
6. The method of claim 1 : the query processor comprising a second language runtime configured to process at least partially compiled components of the second language, and the method comprising: at least partially compiling the second language portion into an at least partially compiled second language component.
7. The method of claim 1 : the query specifying at least one object in the first language, and the method comprising: translating the at least one object into the second language.
8. The method of claim 1 , comprising: upon receiving a query result from the query processor for the mixed language query, translating the query result into the first language.
9. The method of claim 8 , translating to the first language comprising: generating at least one local object of the first language comprising at least one element of the query result.
10. The method of claim 9 , respective local objects corresponding to a record in the query result.
11. The method of claim 8 , translating to the first language comprising: storing at least one element of the query result in at least one local object of the first language.
12. The method of claim 1 : the query processor comprising a first query processor configured to process query components specified in the first language and a second query processor configured to process query components specified in the second language; the remainder portion of the mixed language query targeted to the first query processor and the second portion of the mixed language query targeted to the second query processor; and the sending comprising: sending the query language portion of the mixed language query to the first query processor, and sending the second language portion of the mixed language query to the second query processor.
13. A system for issuing a query specified in a first language to a query processor configured to parse mixed language queries having query components of a query language and components of a second language that is different from the first language on a device having a memory and a processor, the system comprising: a second language translating component comprising instructions stored in the memory that, when executed on the processor, cause the device to translate a translation portion of the query into a second language portion specified in the second language; a mixed language query generating component comprising instructions stored in the memory that, when executed on the processor, cause the device to combine a remainder portion of the query excluding the translation portion and the second language portion to generate a mixed language query; and a query sending component comprising instructions stored in the memory that, when executed on the processor, cause the device to send the mixed language query to the query processor.
14. The system of claim 13 : the mixed language query generating component configured to generate a mixed language expression tree comprising the remainder portion and the second language portion; and the query sending component configured to send the mixed language expression tree to the query processor.
15. The system of claim 13 : the query processor comprising a second language runtime configured to process at least partially compiled components of the second language, and the system comprising: a second language compiling component configured to at least partially compile the second language portion into an at least partially compiled second language component.
16. The system of claim 13 : the query specifying at least one object in the first language, and the system comprising: an object translating component configured to translate the at least one object into the second language.
17. The system of claim 13 , comprising: a query result receiving component configured to translate into the first language a query result received from the query processor for the mixed language query.
18. The system of claim 17 , comprising: a local object generating component configured to generate at least one local object comprising at least one element of the query result.
19. The system of claim 17 , the query result receiving component configured to store at least one element of the query result in at least one local object of the first language.
20. A memory device storing instructions that, when executed on a processor of a computer, cause the computer to issue a query specified in a first language to a query processor configured to parse mixed language queries having query components specified in the first language and query components specified in a second language that is different from the first language, by: translating a translation portion of the query into a second language portion specified in the second language; combining a remainder portion of the query excluding the translation portion and the second language portion to generate a mixed language query; and send the mixed language query to the query processor.
Cooperative Patent Classification codes for this invention. Click any code to explore related patents in that topic.
June 24, 2008
August 26, 2014
Browse 5M+ US patents with plain-English claim translations and AI-generated analysis.