Blaine Carter bae5cbe76a Modified the HoL for Collaborate (#169)
Modified samples and instructions to import common connection information from db_config.py or db_config.sql in order to make setup a bit more generic.
2018-04-20 15:35:17 -07:00
..
2017-10-13 19:14:17 -06:00
2017-11-17 21:40:28 -07:00

This directory contains samples for cx_Oracle.

  1. The schemas and SQL objects that are referenced in the samples can be created by running the SQL script sql/SetupSamples.sql. The syntax is:

     sqlplus / as sysdba @sql/SetupSamples.sql
    

    The script will create users pythondemo and pythoneditions and will create an edition called python_e1.

    If you wish to change the names of the users or the name of the edition you can edit the file sql/SampleEnv.sql. You will also need to edit the file SampleEnv.py or set environment variables as documented in it.

  2. Run a Python script, for example:

     python Query.py
    
  3. After running cx_Oracle samples, the schemas and SQL objects can be dropped by running the SQL script sql/DropSamples.sql. The syntax is

     sqlplus / as sysdba @sql/DropSamples.sql