Skip to main content
This is a pre-production deployment of Warehouse. Changes made here affect the production instance of PyPI (pypi.python.org).
Help us improve Python packaging - Donate today!

Execute an Oracle SQL query and return result as Pandas data frame

Project Description

This package consists of a single method that runs a specified query, passed in as a string, on an Oracle database and returns the result to a Pandas data frame.


Sample usage:

from oracle_db_query import query_to_df

query = "select id, name from students where name like '%Oscar%'"
query_to_df(query, "config.yml")

Returns:

              ID                NAME
0    3298272         Meyer,Oscar
1    2304928         Wilde,Oscar
2    7654321        Grouch,Oscar
.        ...                 ...
128  2234879    De La Hoya,Oscar
129  9872322      Peterson,Oscar
130  9082394       Sanchez,Oscar

[131 rows x 2 columns]

Sample config file:

database:
    username: "OGROUCH"
    password: "SECR3TPASSWORD"
    host: >
            (DESCRIPTION =
                    (ADDRESS = (PROTOCOL = TCP)
                               (HOST = servername.williams.edu)
                               (PORT = 1521)
                    )
                        (CONNECT_DATA = (SERVER = DEDICATED)
                                    (SID = dbname)
                    )
            )

If you don’t wish to store your password in the configuration file, you can omit that line. If a password isn’t present in the configuration file, you will be prompted for it at runtime.

Release History

Release History

This version
History Node

1.0.0

Download Files

Download Files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
oracle_db_query-1.0.0-py3-none-any.whl (4.1 kB) Copy SHA256 Checksum SHA256 py3 Wheel Nov 10, 2015
oracle_db_query-1.0.0.tar.gz (2.3 kB) Copy SHA256 Checksum SHA256 Source Nov 10, 2015

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting