1460729947-2e57e53c-3a13-4638-8b42-56687cca64dc

1. A method of optimizing a query in a computer, the query being performed by the computer to retrieve data from a relational database stored in an electronic storage device coupled to the computer, the method comprising the steps of:
(a) receiving a query having a subquery containing a predicate for matching a nullable left-hand-size (LHS) operand to a nullable right-hand-size (RHS) operand, the query predicate presented in the form of \u201cLHS operand=RHS operand OR (LHS operand IS NULL AND RHS operand IS NULL)\u201d;
(b) transforming the subquery such that the re-written subquery has a simple predicate LHS=RHS returning TRUE value in a presence of a NULL value in all said operands, thereby enabling an optimizer to allow all access methods; and
(c) executing the transformed query in the computer to retrieve data from the relational database.
2. The method according to claim 1, wherein the subquery transforming step comprises the step of re-writing the subquery by forming a \u201cCASE\u201d expression having two subqueries wherein:
the first subquery is executed when the LHS operand is NULL and having an \u201cRHS operand IS NULL\u201d predicate, and
the second subquery is executed when the LHS operand is not NULL and having an \u201cLHS operand=RHS operand\u201d predicate.
3. The method according to claim 2, wherein the executing the transformed query step comprises the following steps:
determining whether to execute the first or second subquery by evaluating whether the LHS operand having a NULL value,
if so, checking the RHS operand for nullness, or
if not so, checking whether the LHS operand has the same value as the RHS operand, and
interpreting the predicate as TRUE, in a presence of a NULL value in both operands.
4. The method according to claim 1, wherein the query transforming step is applied during a query plan compilation phase of query processing.
5. The method according to claim 1, wherein the query transforming step is applied during a query rewrite phase of query processing.
6. An apparatus for optimizing a query, comprising:
a computer having an electronic storage device coupled thereto for storing a relational database, the query being performed by the computer to retrieve data from the relational database;
means, performed by the computer, for receiving a query having a subquery containing a predicate for matching a nullable left-hand-size (LHS) operand to a nullable right-hand-size (RHS) operand, the query predicate presented in the form of \u201cLHS operand=RHS operand OR (LHS operand IS NULL AND RHS operand IS NULL)\u201d;
means, performed by the computer, for transforming the subquery such that the rewritten subquery has a simple predicate LHS=RHS returning TRUE value in a presence of a NULL value in all said operands, thereby enabling an optimizer to allow all access methods; and
means, performed by the computer, for executing the transformed query in the computer to retrieve data from the relational database.
7. The apparatus according to claim 6, wherein the means for transforming the subquery comprises the means for re-writing the subquery by forming a \u201cCASE\u201d expression having two subqueries wherein:
the first subquery is executed when the LHS operand is NULL and having an \u201cRHS operand IS NULL\u201d predicate, and
the second subquery is executed when the LHS operand is not NULL and having an \u201cLHS operand=RHS operand\u201d predicate.
8. The apparatus according to claim 7, wherein the means for executing the transformed query comprises:
means for determining whether to execute the first or second subquery by evaluating whether the LHS operand having a NULL value,
means for checking the RHS operand for nullness,
means for checking whether the LHS operand has the same value as the RHS operand, and
means for interpreting the predicate as TRUE, in a presence of a NULL value in both operands.
9. The apparatus according to claim 6, wherein the means for transforming the query is applied during a query plan compilation phase of query processing.
10. The apparatus according to claim 6, wherein the means for transforming the query is applied during a query rewrite phase of query processing.
11. A program storage device readable by a computer tangibly embodying a program of instructions executable by the computer to perform method steps for optimizing a query, the query being performed by the computer to retrieve data from a relational database stored in an electronic storage device coupled to the computer, the method comprising the steps of:
(a) receiving a query having a subquery containing a predicate for matching a nullable left-hand-size (LHS) operand to a nullable right-hand-size (RHS) operand, the query predicate presented in the form of \u201cLHS operand=RHS operand OR (LHS operand IS NULL AND RHS operand IS NULL)\u201d;
(b) transforming the subquery such that the rewritten subquery has a simple predicate LHS=RHS returning TRUE value in a presence of a NULL value in all said operands, thereby enabling the optimizer to allow all access methods; and
(c) executing the transformed query in the computer to retrieve data from the relational database.
12. The method according to claim 11, wherein the subquery transforming step comprises the step of re-writing the subquery by forming a \u201cCASE\u201d expression having two subqueries, wherein:
the first subquery is executed when the LHS operand is NULL and having an \u201cRHS operand IS NULL\u201d predicate, and
the second subquery is executed when the LHS operand is not NULL and having an \u201cLHS operand=RHS operand\u201d predicate.
13. The method according to claim 12, wherein the executing the transformed query step comprises the following steps:
determining whether to execute the first or second subquery by evaluating whether the LHS operand having a NULL value,
if so, checking the RHS operand for nullness, or
if not so, checking whether the LHS operand has the same value as the RHS operand, and interpreting the predicate as TRUE, in a presence of a NULL value in both operands.
14. The method according to claim 11, wherein the query transforming step is applied during a query plan compilation phase of query processing.
15. The method according to claim 11, wherein the query transforming step is applied during a query rewrite phase of query processing.
16. A method of optimizing a query in a computer, the query being performed by the computer to retrieve data from a relational database stored in an electronic storage device coupled to the computer, the method comprising the steps of:
(a) receiving a query containing a predicate for matching a nullable left-hand-size (LHS) operand to a nullable right-hand-size (RHS) operand, the query predicate presented in the form of \u201cLHS operand=RHS operand OR (LHS operand IS NULL AND RHS operand IS NULL)\u201d;
(b) transforming the predicate into a simple predicate LHS= =RHS including an operator \u201c= =\u201d defining a possible simultaneous presence of a NULL value in the LHS and RHS operand, thereby enabling an optimizer to allow all join methods and access methods; and
(c) executing the transformed query in the computer to retrieve data from the relational database such that the marked predicate is TRUE in a presence of a NULL value in the LHS and RHS operand.
17. The method according to claim 16, wherein the executing the transformed query step comprises the following steps:
determining whether the predicate has the operator \u201c= =\u201d,
checking the LHS and RHS operand for nullness, and
interpreting the predicate as TRUE, in a presence of a NULL value in both operands.
18. The method according to claim 16, wherein the query transforming step is applied during a query plan optimization phase of query processing.
19. The method according to claim 16, wherein the query transforming step is applied during a query rewrite phase of query processing.
20. An apparatus for optimizing a query, comprising:
a computer having an electronic storage device coupled thereto for storing a relational database, the query being performed by the computer to retrieve data from the relational database;
means, performed by the computer, for receiving a query containing a predicate for matching a nullable left-hand-size (LHS) operand to a nullable right-hand-size (RHS) operand, the query predicate presented in the form of \u201cLHS operand RHS=operand OR (LHS operand IS NULL AND RHS operand IS NULL)\u201d;
means, performed by the computer, for transforming the predicate into a simple predicate LHS= =RHS including an operator \u201c= =\u201d defining a possible simultaneous presence of a NULL value in the LHS and RHS operand, thereby enabling an optimizer to allow all join methods and access methods; and
means, performed by the computer, for executing the transformed query in the computer to retrieve data from the relational database such that the marked predicate is TRUE in a presence of a NULL value in the LHS and RHS operand.
21. The apparatus according to claim 20, wherein the means for executing the transformed query comprises:
means, performed by the computer, for determining whether the predicate has the operator \u201c= =\u201d,
means, performed by the computer, for checking the LHS and RHS operand for nullness; and
means, performed by the computer, for interpreting the predicate as TRUE, in a presence of a NULL value in both operands.
22. The apparatus according to claim 20, wherein the means for transforming the query is applied during a query plan optimization phase of query processing.
23. The apparatus according to claim 20, wherein the means for transforming the query is applied during a query rewrite phase of query processing.
24. A program storage device readable by a computer tangibly embodying a program of instructions executable by the computer to perform method steps for optimizing a query, the query being performed by the computer to retrieve data from a relational database stored in an electronic storage device coupled to the computer, the method comprising the steps of:
(a) receiving a query containing a predicate for matching a nullable left-hand-size (LHS) operand to a nullable right-hand-size (RHS) operand, the query predicate presented in the form of \u201cLHS operand=RHS operand OR (LHS operand IS NULL AND RHS operand IS NULL)\u201d;
(b) transforming the predicate into a simple predicate LHS= =RHS including an operator \u201c= =\u201d defining a possible simultaneous presence of a NULL value in the LHS and RHS operand, thereby enabling an optimizer to allow all join methods and access methods; and
(c) executing the transformed query in the computer to retrieve data from the relational database such that the marked predicate is TRUE in a presence of a NULL value in the LHS and RHS operand.
25. The method according to claim 24, wherein the executing the transformed query step comprises the following steps:
(a) determining whether the predicate has the operator \u201c= =\u201d;
(b) checking the LHS and RHS operand for nullness; and
(c) interpreting the predicate as TRUE, in a presence of a NULL value in both operands.
26. The method according to claim 24, wherein the query transforming step is applied during a query plan optimization phase of query processing.
27. The method according to claim 24, wherein the query transforming step is applied during a query rewrite phase of query processing.
28. A method of optimizing a query in a computer, the query being performed by the computer to retrieve data from a relational database stored in an electronic storage device coupled to the computer, the method comprising the steps of:
(a) receiving a query containing a predicate for matching a nullable left-hand-size (LHS) operand to a nullable right-hand-size (RHS) operand, the query predicate presented in the form of \u201cLHS operand=RHS operand OR (LHS operand IS NULL AND RHS operand IS NULL)\u201d;
(b) transforming the predicate into a simple predicate LHS=RHS;
(c) marking the predicate as defining a possible simultaneous presence of a NULL value in the LHS and RHS operand, thereby enabling an optimizer to allow all join methods and access methods; and
(d) executing the query in the computer to retrieve data from the relational database such that the marked predicate is TRUE in a presence of a NULL value in the LHS and RHS operand.
29. The method according to claim 28, wherein the executing the query step comprises the following steps:
determining whether the predicate is marked;
checking the LHS and RHS operand for nullness; and
interpreting the predicate as TRUE, in a presence of a NULL value in the LHS and RHS operand.
30. The method according to claim 28, wherein the query predicate marking step is applied during a query plan optimization phase of query processing.
31. The method according to claim 28, wherein the query predicate marking step is applied during a query rewrite phase of query processing.
32. An apparatus for optimizing a query, comprising:
a computer having an electronic storage device coupled thereto for storing a relational database, the query being performed by the computer to retrieve data from the relational database;
means, performed by the computer, for receiving a query containing a predicate for matching a nullable left-hand-size (LHS) operand to a nullable right-hand-size (RHS) operand, the query predicate presented in the form of \u201cLHS operand=RHS operand OR (LHS operand IS NULL AND RHS operand IS NULL)\u201d;
means, performed by the computer, for transforming the predicate into a simple predicate LHS=RHS;
means, performed by the computer, for marking the predicate as defining a possible simultaneous presence of a NULL value in the LHS and RHS operand, thereby enabling an optimizer to allow all join methods and access methods; and
means, performed by the computer, for executing the query in the computer to retrieve data from the relational database such that the marked predicate is TRUE in a presence of a NULL value in the LHS and RHS operand.
33. The apparatus according to claim 32, wherein the means for executing the query comprises:
means, performed by the computer, for determining whether the predicate is marked;
means, performed by the computer, for checking the LHS and RHS operand for nullness; and
means, performed by the computer, for interpreting the predicate as TRUE, in a presence of a NULL value in the LHS and RHS operand.
34. The apparatus according to claim 32, wherein the means for marking the query predicate is applied during a query plan optimization phase of query processing.
35. The apparatus according to claim 32, wherein the means for marking the query predicate is applied during a query rewrite phase of query processing.
36. A program storage device readable by a computer tangibly embodying a program of instructions executable by the computer to perform method steps for optimizing a query, the query being performed by the computer to retrieve data from a relational database stored in an electronic storage device coupled to the computer, the method comprising the steps of:
(a) receiving a query containing a predicate for matching a nullable left-hand-size (LHS) operand to a nullable right-hand-size (RHS) operand, the query predicate presented in the form of \u201cLHS operand=RHS operand OR (LHS operand IS NULL AND RHS operand IS NULL)\u201d;
(b) transforming the predicate into a simple predicate LHS=RHS;
(c) marking the predicate as defining a possible simultaneous presence of a NULL value in the LHS and RHS operand, thereby enabling an optimizer to allow all join methods and access methods; and
(c) executing the query in the computer to retrieve data from the relational database such that the marked predicate is TRUE in a presence of a NULL value in the LHS and RHS operand.
37. The method according to claim 36, wherein the executing the query step comprises the following steps:
determining whether the predicate is marked;
checking the LHS and RHS operand for nullness; and
interpreting the predicate as TRUE, in a presence of a NULL value in the LHS and RHS operand.
38. The method according to claim 36, wherein the query predicate marking step is applied during a query plan optimization phase of query processing.
39. The method according to claim 36, wherein the query predicate marking step is applied during a query rewrite phase of query processing.

The claims below are in addition to those above.
All refrences to claim(s) which appear below refer to the numbering after this setence.

1. A resonant converter (200, 300) consisting of a first circuit, primarily a DC circuit (201, 301) connected to a resonant circuit (207, 307) which is further connected to a switchfilter circuit (212, 312), which is connected to a second circuit, primarily an AC circuit (219, 319), characterized in that the resonant converter (200, 300) contains a direct connection between a voltage centre (203, 303) in the DC circuit (201, 301) and a voltage centre (209, 309, 325) in the resonant circuit (207, 307), and that the resonant circuit (207, 307) contains at least one transformer having at least two windings (223, 224, 331, 332, 333, 334), wherein there is a connection from the windings (223, 224, 331, 332) of the transformer to at least first and second switches (215, 216, 315, 316, 328, 329), wherein activation of the switches (215, 216, 315, 316, 328, 329) forms a connection to at least a first node (214, 314, 327), wherein a voltage centre (203, 303) in the DC circuit (201, 301) is also connected to the first node (214, 314, 327) by activation of at least a third switch (213, 313, 326).
2. A resonant converter (300) according to claim 1, characterized in that the transformer has additional windings (332, 333) which operate in anti-phase to the windings (331, 334).
3. A resonant converter (200, 300) according to claim 1 or 2, characterized in that the resonant converter (200, 300) is used as a DC to AC converter.
4. A resonant converter (200, 300) according to claim 1 or 2, characterized in that the resonant converter (200, 300) is used as an AC to DC converter, wherein the first node (214, 314, 327) of the resonant converter (200, 300) is connected to an AC supply (219, 319), wherein the first node (214, 314, 327) is connected by activation of switches (215, 216, 315, 316, 328, 329) to windings (223, 224, 331, 332) on the transformer, said transformer having windings (223, 224, 331, 332) which are connected to a DC circuit (201, 301).
5. A resonant converter (200, 300) according to one of claims 1 to 4, characterized in that the resonant converter (200, 300) is incorporated in an N-phase system having at least one resonant converter (200, 300) per phase, the number of phases N being at least 1.
6. A resonant converter (200, 300) according to claim 5, characterized in that several switchfilter circuits in the N-phase system use the same common resonant circuit (207, 307) and the same common DC circuit (201, 301), wherein each phase is formed by activation of independent sets of switches (213, 215, 216, 313, 315, 316, 326, 328, 329).
7. A resonant converter (200, 300) according to one of claims 2, 5 or 6, characterized in that the resonant converter (200, 300) is used as an AC to AC converter.
8. A resonant converter (200, 300) according to claim 7, characterized in that the resonant converter (200, 300) is used for converting at least one of the parameters frequency, voltage and current.
9. A resonant converter (200, 300) according to one of claims 1 to 8, characterized in that semiconductors are used as switches comprising at least one of the types field effect transistor, bipolar transistor, Insulated Gate Bipolar Transistor (IGBT), Gate Turn-Off thyristor (GTO) and Injection Enhanced Gate Transistor (IEGT).
10. A resonant converter (200, 300) according to one of claims 1 to 9, characterized in that the resonant frequency (200, 300) uses three point modulation.
11. A resonant converter (200, 300) according to one of claims 1 to 10, characterized in that the resonance is controlled by the switches (213, 215, 216, 313, 315, 316, 326, 328, 329) in the switchfilter circuit (212, 312).
12. A resonant converter (200, 300) according to one of claims 1 to 10, characterized in that the resonance is controlled by a current source which is coupled magnetically to the resonant circuit (207, 307) via the core (208, 308).