apache / apache/arrow-adbc

c/driver/postgresql: Implement constraint metadata in GetObjects

Open
#3,839 0 comments 0 reactions 0 assignees View on GitHub
Type: enhancement
Dominant language
C#
Stars
627
Forks
217
Avg merge
17h
Merged PRs (30d)
57

Description

### What feature or improvement would you like to see?

```
ERROR tests/test_connection.py::TestConnection::test_get_objects_constraints_foreign[postgresql:15+] - NotImplementedError
ERROR tests/test_connection.py::TestConnection::test_get_objects_constraints_primary[postgresql:15+] - NotImplementedError
ERROR tests/test_connection.py::TestConnection::test_get_objects_constraints_unique[postgresql:15+] - NotImplementedError
```
These tests are being skipped right now because the PostgreSQL driver throws NotImplementedError when GetObjects is called with depth levels that request constraint information (foreign keys, primary keys, unique constraints). The driver should query PostgreSQL system catalogs (pg_constraint, pg_index) to retrieve constraint metadata so that we can enable the get_objects_constraints_* feature flags and pass the tests.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.