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

Proposal: Add flexible version of getTables, and getTableTypes #41

Open
mpilgrem opened this issue Sep 8, 2019 · 0 comments
Open

Proposal: Add flexible version of getTables, and getTableTypes #41

mpilgrem opened this issue Sep 8, 2019 · 0 comments

Comments

@mpilgrem
Copy link

mpilgrem commented Sep 8, 2019

getTables :: Connection -> IO [String] provides results for ODBC table type TABLE. I found myself wanting the equivalent results for other ODBC table types, such as VIEW or SYSTEM TABLE.

Perhaps the library could be extended to include:

getTablesOfType :: Connection -> String -> IO [String]
getTableTypes :: Connection -> IO [String]

so that getTableTypes conn provides a list of the valid table types for conn and getTablesOfType conn "TABLE,VIEW,SYSTEM TABLE" (for example) gets the relevant table names of those types.

I have done that in a fork, by extending the constructor of data type Connection. Would it be of interest? If yes, I'll make a pull request.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant