Expand description
FunctionalDependencies keeps track of functional dependencies inside DFSchema.
Structs§
- Constraints
- This object encapsulates a list of functional constraints:
- Functional
Dependence - This object defines a functional dependence in the schema. A functional dependence defines a relationship between determinant keys and dependent columns. A determinant key is a column, or a set of columns, whose value uniquely determines values of some other (dependent) columns. If two rows have the same determinant key, dependent columns in these rows are necessarily the same. If the determinant key is unique, the set of dependent columns is equal to the entire schema and the determinant key can serve as a primary key. Note that a primary key may “downgrade” into a determinant key due to an operation such as a join, and this object is used to track dependence relationships in such cases. For more information on functional dependencies, see: https://www.scaler.com/topics/dbms/functional-dependency-in-dbms/
- Functional
Dependencies - This object encapsulates all functional dependencies in a given relation.
Enums§
- Constraint
- This object defines a constraint on a table.
- Dependency
- Describes functional dependency mode.
Functions§
- add_
offset_ 🔒to_ vec - Adds
offsetvalue to each entry insidein_data. - aggregate_
functional_ dependencies - Calculates functional dependencies for aggregate output, when there is a GROUP BY expression.
- get_
required_ group_ by_ exprs_ indices - Returns indices for the minimal subset of GROUP BY expressions that are functionally equivalent to the original set of GROUP BY expressions.
- get_
target_ functional_ dependencies - Returns target indices, for the determinant keys that are inside group by expressions.
- update_
elements_ 🔒with_ matching_ indices - Updates entries inside the
entriesvector with their corresponding indices inside theproj_indicesvector.