text: in the following description , for the purpose of explanation , numerous specific details are set forth in order to provide a thorough understanding of the present invention . it will be apparent , however , that the present invention may be practiced without these specific details . in other instances , well - known structures and devices are shown in block diagram form in order to avoid unnecessarily obscuring the present invention . an embodiment , depicted in fig1 , determines the most efficient allocation of work between the rdbms and the cluster . in step 102 , the embodiment estimates the cost to perform an operation , such as a join , in the rdbms and , in step 104 , the cost of performing the operation with the assistance of the cluster . the embodiment compares , in step 106 , the two estimated costs and performs the operation in the place with the lowest cost . if a join is performed in the rdbms as in step 108 , the cost is simply the cost of sending the relations to the rdbms and performing the join in the rdbms . if the join is performed with the assistance of the cluster , as in step 110 , then additional costs are incurred to obtain the performance benefit of the cluster . these additional costs do not include the completion of the join 112 in the rdbms , in fig1 , because the completion of the join occurs in either case . the additional costs of using the cluster depend on the type of join and whether any blocking operations are present . types of joins include broadcast joins and partitioned joins , as depicted in fig2 . in a broadcast join , if one of the relations is small enough , as determined in step 202 of fig2 , to fit in each unit of the cluster , then it is broadcast to all of the processing units in the cluster . as determined in step 204 , the additional costs of this join include the broadcast and the cost of joining the small relation with part of the large relation in each processing unit . in a partitioned join as depicted in fig2 , each relation to be joined is partitioned based on a join column and the separate partitions are processed by the individual processing units in the cluster . as determined in step 206 , the additional costs of this join include the partitioning and the cost of joining a partition of each relation . as depicted in step 208 of fig2 , blocking operations incur additional costs . these operations , such as sorting and grouping , read all input rows before any output row can be produced , thus preventing other dependent operations from being performed completely in the cluster . instead , part of the operation must be performed in the rdbms . specifically , the rdbms must integrate / merge the results of the blocking operation , partition the results among the processing unit in the cluster , and merge the results from the processing units . a blocking operation thus incurs the additional costs of sending the results of the blocking operation to the rdbms , the cost of partitioning in the rdbms , and the cost of sending the partitions back to the processing units in the cluster . not only are additional costs to use the cluster incurred , but other aspects of transaction processing are affected , as indicated in step 210 of fig2 . specifically , performing operations in the cluster affects the degree of parallelism in the rdbms and requires that the rdbms ensure transaction consistency . prior to performing a join , the rdbms first estimates the sizes of the two relations to be joined after apply any filters , including any applicable bloom filters and projections . the size estimates of the resulting relations include the total number of rows and the total number of bytes . these estimates help determine the costs described below . next , the rdbms determines whether there are any blocking query operations , such as sorting and grouping , under the join in the query plan . if any blocking operations are required , then the rdbms must take this into account in the cost of the join operation . if the join and the query sub - tree under it can be performed fully in the cluster , the rdbms decides what distributed join algorithm would be best . additionally , the rdbms tracks the available memory on each processing unit via periodic status messages sent by each of the processing units . to assess the cost of a join , the system assesses costs under three categories , the cost of partitioning a relation c 1 , the cost of sending relations or partitions of relations c 2 , and the cost of performing the actual join c 3 . the cost of partitioning a relation c 1 depends on the number of rows , the average size of the join key , and the compute and memory bandwidth of a processing unit . the cost of sending relations or partitions c 2 depends on the interconnect bandwidth and size of the relation in bytes , which was determined in a preliminary step . the cost of sending any bloom filters is negligible and is not considered as a cost item . additionally , the evaluation of bloom filters can be done during a table scan in the cluster , so the evaluation cost is excluded . the cost of a join c 3 depends on the number of rows in the two relations ( or sub - relations ) being joined , the size of the join result in bytes , and the compute and memory bandwidth of the processing unit . joins performed completely in the rdbms operate on the entire relations to be joined . joins performed in the cluster operate on partitions of both relations . the cost of performing a join entirely in the rdbms includes only the cost of sending both relations ( c 2 ) to the rdbms and performing the actual join ( c 3 ). there is no cost of partitioning ( c 1 ) a relation because the rdbms performs the join on the entire relations . as mentioned above , a broadcast join , depicted in fig3 , is possible when one relation 304 of the two , 302 , 304 to be joined is small , meaning that the smaller relation 304 can fit in the memories of the processing units . in fig3 , the larger relation 302 is partitioned among three nodes , as 306 a , b , c while the smaller relation 304 is broadcast to those nodes . the smaller relation 304 can be either naturally smaller or made smaller by filtering a larger relation . thus , for a broadcast join , the additional cost ( to the rdbms cost ) includes the cost of partitioning the larger relation ( c 1 ), the cost ( c 2 ) of sending the smaller relation to all of the processing units , the cost ( c 2 ) of sending the partition of the larger relation to all of the processing units , and the cost ( c 3 ) of the join in each of the processing units . the cost of sending the partial joins back to the rdbms is not included , because this is already accounted for in the cost for performing the join entirely in the rdbms . if a broadcast join is not feasible , the rdbms considers the cost of a partitioned join . as shown in fig4 , each of the relations to be joined 402 , 404 is partitioned , according to partitioning parameters set by the rdbms , based on global statistics about the entire data set . the partition pairs 406 a 408 a , 406 b 408 b , 406 c 408 c are then sent to each of the processing units . thus , there is an additional c 1 cost of partitioning the relations , and an additional c 3 cost for performing the partial joins in each of the units . a c 2 cost is not included because it is already accounted for in the rdbms join . the c 1 cost of partitioning the relations can be avoided if the relations are partitioned at load time . if a blocking operation is involved in performing either a broadcast join or a partitioned join , then additional costs are incurred . a c 2 cost is incurred in sending the relation to the rdbms after the blocking operation is performed . a c 1 cost is incurred in partitioning the sent relation . finally , a c 2 cost is incurred in sending the partitioned relation back to the cluster . in certain cases , the system can avoid some of the costs associated with processing joins in the cluster by pre - distributing portions of relations into the processing units of the cluster in a favorable manner . one way the data can be pre - distributed into the cluster depends on an application &# 39 ; s access patterns . another way depends on how the processing units are connected to switches in the cluster . in the case of distributing data according to an application &# 39 ; s access patterns , the data is distributed in a way that co - locates corresponding partitions of different tables . the tables to group together can be found by using referential constraints between tables or by grouping all tables whose partition keys are of the same type . for example , if a storage partition is split across two processing units , the same split value is used for all tables whose partition keys are of the same type . this technique ensures that for joins in which the join columns are the same as the partition keys , the tables are already partitioned and conveniently reside in the proper processing units . in the case of distributing data based on the arrangement of switches in the cluster , tables that cannot be replicated on every node can still be replicated among sets of nodes that are connected to a common switch in the cluster . processing units connected to a common switch have greater bandwidth for communicating among each other . when a join needs to be performed , the partitioning and redistribution of data needs to be done only within the set of units connected to the common switch . in the case of a cluster having a large number of processing units , distributing data based on the switch arrangement is particularly advantageous . as mentioned above , when the cluster participates in database operations , parallelism in the rdbms and transaction consistency are affected . because a cluster may be performing significant query processing for the rdbms , in one embodiment , the rdbms adjusts the number of parallel query processes or threads in accordance with the amount of work the cluster is performing . if a join is processed completely in a cluster , then each parallel query process or thread handles only the communication with the units in the cluster . specifically , the rdbms obtains results from the processing units and streams them to other parallel query processes that perform further operations on the query . in this case , the number of processing units assigned to each process ( and hence the degree of parallelism ) depends on the estimated size of the join result and rate at which the processing units are expected to process the join . the processes or threads in the rdbms are arranged to process the results from the processing units at the rate at which the results are produced . in the case where a blocking operation is involved with the join , the degree of parallelism is set to efficiently merge the results of the blocking operation and then partition it among the units in the cluster . the degree of parallelism in this case is set in a way that is similar to the merge phase of a sort operation . each process in the rdbms needs to be able to merge the results sent to it without becoming a bottleneck , as well as participate in a final merge among all of the processes . at runtime , each processing unit first sends its result size and based on the distribution of sizes , the units are divided among the rdbms processes to equalize the load . in the heterogeneous system depicted in fig5 , the rdbms preserves transactional consistency . using its access to the transaction logs 502 in fig5 , the rdbms 504 takes several steps to assure transaction consistency when a cluster 510 with processing units 508 a - j is involved in a transaction . first , before the cluster performs a query , the rdbms 504 makes sure that the items affected by the query are updated from any write buffers holding data for those items . second , the rdbms 504 makes sure that the cluster only processes rows in blocks having snapshot identifiers that are no later than the snapshot identifiers of the query itself . any blocks that have identifiers later than the query &# 39 ; s snapshot identifier are sent to the rdbms as unprocessed blocks , as depicted in fig6 , where the unprocessed blocks include row 610 in relation 402 and row 612 in relation 404 . third , a mechanism in the rdbms 504 is provided to handle any unprocessed blocks such as those including 610 , 612 . the mechanism includes enhancements that permit the rdbms 504 to perform a partial evaluation for a given set of blocks . in the case of a query plan whose tree includes a table scan row source , the enhancement is to scan only the given blocks . grouping and sorting row sources build on this enhancement , merging the partial evaluations with those from the cluster . in the case of a query plan that includes a join row source , both of its child row sources are first initialized with the set of unprocessed blocks such as those including rows 610 , 612 for each underlying table 402 , 404 as well as the results from the operations of the cluster , if necessary . the rdbms 504 tracks partial results ( called “ deltas ”) of both child row sources by computing bloom filters for the partial results , which it then sends to the processing units in the cluster . the processing units use the bloom filters to determine the number of join matches in the cluster . if there are a small number of matching rows ( corresponding to rows from one of the child row sources ) in the cluster , then the matching rows are sent to the rdbms 504 along with the join results . the rdbms 504 then calculates the join results corresponding to the deltas and their matching rows . if there are a large number of matching rows across all of the units in the cluster and the size of the matching rows is greater than the size of the corresponding delta , then the rdbms 504 broadcasts the delta to all of the processing units in the cluster . the join results corresponding to the deltas are then computed by the processing units in the cluster and sent back to the rdbms 504 . to decide whether or not the rdbms 504 should process the deltas , the system makes an estimate of the efficiency of the bloom filter on the join key column . based on the join filter estimate , the cost of sending deltas ( from the rdbms 504 ) or sending matching rows ( from the processing units ) and the incremental cost of processing the join for the deltas are estimated . the main impact of this is that if the delta is large , it is usually better to process the join entirely in the rdbms 504 . in most data warehouse scenarios the delta is expected to be small ( if not null ) since updates are infrequent , and done in a batch - oriented fashion . note that this process increases the overall cost of join processing . in the cost model described above , this mainly affects the cost of processing the join in the cluster . the cost model should include the extra cost of consistency processing for the join row source but excludes the cost of consistency processing for the child row sources , because the rdbms 504 performs this processing in all cases . according to one embodiment , the techniques described herein are implemented by one or more special - purpose computing devices . the special - purpose computing devices may be hard - wired to perform the techniques , or may include digital electronic devices such as one or more application - specific integrated circuits ( asics ) or field programmable gate arrays ( fpgas ) that are persistently programmed to perform the techniques , or may include one or more general purpose hardware processors programmed to perform the techniques pursuant to program instructions in firmware , memory , other storage , or a combination . such special - purpose computing devices may also combine custom hard - wired logic , asics , or fpgas with custom programming to accomplish the techniques . the special - purpose computing devices may be desktop computer systems , portable computer systems , handheld devices , networking devices or any other device that incorporates hard - wired and / or program logic to implement the techniques . for example , fig7 is a block diagram that depicts a computer system 700 upon which an embodiment may be implemented . computer system 700 includes a bus 702 or other communication mechanism for communicating information , and a hardware processor 704 coupled with bus 702 for processing information . hardware processor 704 may be , for example , a general - purpose microprocessor . computer system 700 also includes a main memory 706 , such as a random access memory ( ram ) or other dynamic storage device , coupled to bus 702 for storing information and instructions to be executed by processor 704 . main memory 706 also may be used for storing temporary variables or other intermediate information during execution of instructions to be executed by processor 704 . such instructions , when stored in non - transitory storage media accessible to processor 704 , convert computer system 700 into a special - purpose machine that is customized to perform the operations specified in the instructions . computer system 700 further includes a read only memory ( rom ) 708 or other static storage device coupled to bus 702 for storing static information and instructions for processor 704 . a storage device 710 , such as a magnetic disk or optical disk , is provided and coupled to bus 702 for storing information and instructions . computer system 700 may be coupled via bus 702 to a display 712 , such as a cathode ray tube ( crt ), for displaying information to a computer user . an input device 714 , including alphanumeric and other keys , is coupled to bus 702 for communicating information and command selections to processor 704 . another type of user input device is cursor control 716 , such as a mouse , a trackball , or cursor direction keys for communicating direction information and command selections to processor 704 and for controlling cursor movement on display 712 . this input device typically has two degrees of freedom in two axes , a first axis ( e . g ., x ) and a second axis ( e . g ., y ), that allows the device to specify positions in a plane . computer system 700 may implement the techniques described herein using customized hard - wired logic , one or more asics or fpgas , firmware and / or program logic which in combination with the computer system causes or programs computer system 700 to be a special - purpose machine . according to one embodiment , the techniques herein are performed by computer system 700 in response to processor 704 executing one or more sequences of one or more instructions contained in main memory 706 . such instructions may be read into main memory 706 from another storage medium , such as storage device 710 . execution of the sequences of instructions contained in main memory 706 causes processor 704 to perform the process steps described herein . in alternative embodiments , hard - wired circuitry may be used in place of or in combination with software instructions . the term “ storage media ” as used herein refers to any non - transitory media that store data and / or instructions that cause a machine to operation in a specific fashion . such storage media may comprise non - volatile media and / or volatile media . non - volatile media includes , for example , optical or magnetic disks , such as storage device 710 . volatile media includes dynamic memory , such as main memory 706 . common forms of storage media include , for example , a floppy disk , a flexible disk , hard disk , solid state drive , magnetic tape , or any other magnetic data storage medium , a cd - rom , any other optical data storage medium , any physical medium with patterns of holes , a ram , a prom , and eprom , a flash - eprom , nvram , any other memory chip or cartridge . storage media is distinct from but may be used in conjunction with transmission media . transmission media participates in transferring information between storage media . for example , transmission media includes coaxial cables , copper wire and fiber optics , including the wires that comprise bus 702 . transmission media can also take the form of acoustic or light waves , such as those generated during radio - wave and infra - red data communications . various forms of media may be involved in carrying one or more sequences of one or more instructions to processor 704 for execution . for example , the instructions may initially be carried on a magnetic disk or solid - state drive of a remote computer . the remote computer can load the instructions into its dynamic memory and send the instructions over a telephone line using a modem . a modem local to computer system 700 can receive the data on the telephone line and use an infra - red transmitter to convert the data to an infra - red signal . an infra - red detector can receive the data carried in the infra - red signal and appropriate circuitry can place the data on bus 702 . bus 702 carries the data to main memory 706 , from which processor 704 retrieves and executes the instructions . the instructions received by main memory 706 may optionally be stored on storage device 710 either before or after execution by processor 704 . computer system 700 also includes a communication interface 718 coupled to bus 702 . communication interface 718 provides a two - way data communication coupling to a network link 720 that is connected to a local network 722 . for example , communication interface 718 may be an integrated services digital network ( isdn ) card , cable modem , satellite modem , or a modem to provide a data communication connection to a corresponding type of telephone line . as another example , communication interface 718 may be a local area network ( lan ) card to provide a data communication connection to a compatible lan . wireless links may also be implemented . in any such implementation , communication interface 718 sends and receives electrical , electromagnetic or optical signals that carry digital data streams representing various types of information . network link 720 typically provides data communication through one or more networks to other data devices . for example , network link 720 may provide a connection through local network 722 to a host computer 724 or to data equipment operated by an internet service provider ( isp ) 726 . isp 726 in turn provides data communication services through the world wide packet data communication network now commonly referred to as the “ internet ” 728 . local network 722 and internet 728 both use electrical , electromagnetic or optical signals that carry digital data streams . the signals through the various networks and the signals on network link 620 and through communication interface 718 , which carry the digital data to and from computer system 700 , are example forms of transmission media . computer system 700 can send messages and receive data , including program code , through the network ( s ), network link 720 and communication interface 718 . in the internet example , a server 730 might transmit a requested code for an application program through internet 728 , isp 726 , local network 722 and communication interface 718 . the received code may be executed by processor 704 as it is received , and / or stored in storage device 710 , or other non - volatile storage for later execution . in the foregoing specification , embodiments have been described with reference to numerous specific details that may vary from implementation to implementation . the specification and drawings are , accordingly , to be regarded in an illustrative rather than a restrictive sense . the sole and exclusive indicator of the embodiments , and what is intended by the applicants to be the scope of embodiments , is the literal and equivalent scope of the set of claims that issue from this application , in the specific form in which such claims issue , including any subsequent correction .