Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Creating table class from Postgres system files #13

Closed
Tracked by #23
benedeki opened this issue Oct 10, 2023 · 1 comment · Fixed by #24
Closed
Tracked by #23

Creating table class from Postgres system files #13

benedeki opened this issue Oct 10, 2023 · 1 comment · Fixed by #24
Assignees
Labels
dependent The item depends on some other open item (Issue or PR) enhancement New feature or request

Comments

@benedeki
Copy link
Collaborator

benedeki commented Oct 10, 2023

Background

Tables need to be represented within the application for further analysis and eventually change SQL entries

Feature

The table class is to be filled from Postgres system tables.

NB!
Function to return Option of the table class, in case the table does not exist (then None is returned)

Hint

This is for functions, but query or table won't be that different.

SELECT
    n.nspname,
	A.rolname,
	T.typname AS returntype,
    p.*
    
FROM 
    pg_catalog.pg_namespace n JOIN 
    pg_catalog.pg_proc p ON p.pronamespace = n.oid JOIN
	pg_catalog.pg_authid A ON  p.proowner  = A.oid JOIN
	pg_catalog.pg_type T ON p.prorettype = T.oid
WHERE 	
	n.nspname NOT IN ('public', 'pg_catalog', 'pg_toast', 'information_schema') AND
	p.prokind = 'f'
ORDER BY n.nspname, p.proname

Depends on AbsaOSS/fa-db#8`2

@benedeki benedeki added the enhancement New feature or request label Oct 10, 2023
@benedeki benedeki self-assigned this Oct 11, 2023
@benedeki
Copy link
Collaborator Author

This item depends on:

dk1844 referenced this issue in AbsaOSS/fa-db Oct 12, 2023
@benedeki benedeki transferred this issue from AbsaOSS/fa-db Oct 21, 2023
benedeki added a commit that referenced this issue Jan 19, 2024
*Work in progress (safety commit)
@benedeki benedeki added dependent dependent The item depends on some other open item (Issue or PR) and removed dependentx labels Jan 22, 2024
@benedeki benedeki added this to the Ultet POC release milestone Feb 15, 2024
benedeki added a commit that referenced this issue Feb 16, 2024
* #13: Creating table class from Postgres system files
* added the ability to extract table info from postgres system tables
* update of .gitignore
* headers fix
@github-project-automation github-project-automation bot moved this from 🏗 In progress to ✅ Done in CPS small repos project Feb 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependent The item depends on some other open item (Issue or PR) enhancement New feature or request
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

1 participant