|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectsimpledb.materialize.MergeJoinPlan
public class MergeJoinPlan
The Plan class for the mergejoin operator.
| Constructor Summary | |
|---|---|
MergeJoinPlan(Plan p1,
Plan p2,
java.lang.String fldname1,
java.lang.String fldname2,
Transaction tx)
Creates a mergejoin plan for the two specified queries. |
|
| Method Summary | |
|---|---|
int |
blocksAccessed()
Returns the number of block acceses required to mergejoin the sorted tables. |
int |
distinctValues(java.lang.String fldname)
Estimates the distinct number of field values in the join. |
Scan |
open()
The method first sorts its two underlying scans on their join field. |
int |
recordsOutput()
Returns the number of records in the join. |
Schema |
schema()
Returns the schema of the join, which is the union of the schemas of the underlying queries. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public MergeJoinPlan(Plan p1,
Plan p2,
java.lang.String fldname1,
java.lang.String fldname2,
Transaction tx)
p1 - the LHS query planp2 - the RHS query planfldname1 - the LHS join fieldfldname2 - the RHS join fieldtx - the calling transaction| Method Detail |
|---|
public Scan open()
open in interface PlanPlan.open()public int blocksAccessed()
blocksAccessed in interface PlanPlan.blocksAccessed()public int recordsOutput()
R(join(p1,p2)) = R(p1)*R(p2)/max{V(p1,F1),V(p2,F2)}
recordsOutput in interface PlanPlan.recordsOutput()public int distinctValues(java.lang.String fldname)
distinctValues in interface Planfldname - the name of a field
Plan.distinctValues(java.lang.String)public Schema schema()
schema in interface PlanPlan.schema()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||