kosiew opened a new pull request, #16340:
URL: https://github.com/apache/datafusion/pull/16340

   ## Which issue does this PR close?
   
   Closes #16309
   
   ## Rationale for this change
   
   Table constraints like primary keys, uniqueness, and foreign keys are common 
features in relational systems, but DataFusion does not currently enforce or 
optimize based on most of them. This lack of enforcement isn't clearly 
documented, which can lead to confusion for TableProvider authors and users 
expecting standard SQL behavior. This PR aims to clarify that and guide users 
with expectations and references for typical implementations.
   
   ## What changes are included in this PR?
   
   - Adds documentation to the `custom-table-providers.md` file describing how 
DataFusion currently treats table constraints.
   - Notes that some constraints (like nullability) are enforced, but others 
(like uniqueness or PK/FK constraints) are not.
   - References relevant background discussion and highlights the optimizer's 
current limitations in leveraging constraint metadata.
   
   ## Are these changes tested?
   
   N/A – This change is purely documentation-related and does not include or 
require any code or behavior changes.
   
   ## Are there any user-facing changes?
   
   Yes – this change updates the documentation to make constraint behavior more 
transparent for users implementing custom `TableProvider`s.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org
For additional commands, e-mail: github-h...@datafusion.apache.org

Reply via email to