Skip to content

Instantly share code, notes, and snippets.

@uuklanger
Created April 28, 2017 16:31
Show Gist options
  • Save uuklanger/c6ab79b5b725e91f88cdd9a9bfe04b40 to your computer and use it in GitHub Desktop.
Save uuklanger/c6ab79b5b725e91f88cdd9a9bfe04b40 to your computer and use it in GitHub Desktop.
Code for determining what ODBC datasources are available
#!/usr/bin/env python3
# -*- coding: utf8 -*-
import pypyodbc
def show_odbc_sources():
odbc_list = []
for d in pypyodbc.drivers():
odbc_list.append('%s' % (d))
print('\n'.join(odbc_list))
return
if __name__ == '__main__':
show_odbc_sources()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment