|
1 | 1 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
2 | 2 | <html xmlns="http://www.w3.org/1999/xhtml">
|
3 | 3 | <head>
|
4 |
| -<title>Python and Oracle Database: Scripting for the Future</title> |
| 4 | +<title>Python and Oracle Database Tutorial: Scripting for the Future</title> |
5 | 5 | <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
6 | 6 |
|
7 | 7 | <link rel="stylesheet" href="resources/base.css" type="text/css"/>
|
8 | 8 | <link rel="shortcut icon" type="image/x-icon" href="resources/favicon.ico"/>
|
9 | 9 | </head>
|
10 | 10 | <body bgcolor="#ffffff" text="#000000">
|
11 | 11 |
|
12 |
| - <h1>Python and Oracle Database: Scripting for the Future</h1> |
| 12 | + <h1>Python and Oracle Database Tutorial: Scripting for the Future</h1> |
13 | 13 |
|
14 | 14 | <img src="resources/community-py-200.png" alt="Python cx_Oracle logo">
|
15 | 15 |
|
16 | 16 | <h2>Contents</h2>
|
17 | 17 |
|
18 | 18 | <ul>
|
19 |
| - <li><a href="#preface" >Preface</a></li> |
20 |
| - <li><a href="#connectioninformation" >Connection Information</a></li> |
21 | 19 | <li><a href="#overview" >Overview</a></li>
|
22 |
| - <li><a href="#lab" >Using Python cx_Oracle 7 with Oracle Database</a></li> |
| 20 | + <li><a href="#preface" >Setup</a></li> |
| 21 | + <li><a href="#connectioninformation" >Connection Information</a></li> |
| 22 | + <li><a href="#lab" >Using Python cx_Oracle 8 with Oracle Database</a></li> |
23 | 23 | <ul>
|
24 | 24 | <li><a href="#connecting">1. Connecting to Oracle</a>
|
25 | 25 | <ul>
|
@@ -104,15 +104,31 @@ <h2>Contents</h2>
|
104 | 104 | <li><a href="#resources" >Resources</a></li>
|
105 | 105 | </ul>
|
106 | 106 |
|
107 |
| - <h2><a name="preface">Preface</a></h2> |
| 107 | + <h2><a name="overview">Overview</a></h2> |
| 108 | + |
| 109 | + <p>This tutorial is an introduction to using Python with Oracle |
| 110 | + Database. It contains beginner and advanced material. Sections can |
| 111 | + be done in any order. Choose the content that interests you and |
| 112 | + your skill level.</p> |
| 113 | + |
| 114 | + <p>Follow the steps in this document. The <code>tutorial</code> |
| 115 | + directory has scripts to run and modify. The |
| 116 | + <code>tutorial/solutions</code> directory has scripts with the |
| 117 | + suggested code changes.</p> |
| 118 | + |
| 119 | + <p>If you are new to Python review the <a href="#primer">Appendix: |
| 120 | + Python Primer</a> to gain an understanding of the language. </p> |
| 121 | + |
| 122 | + <h2><a name="preface">Setup</a></h2> |
108 | 123 |
|
109 |
| - <p>This is the cx_Oracle tutorial. These instructions and the files used in them can be found in the <a href="https://github.com/oracle/python-cx_Oracle/tree/master/samples/tutorial" >cx_Oracle GitHub repository</a>.</p> |
| 124 | + <p>These cx_Oracle tutorial instructions can be found <a href="https://oracle.github.io/python-cx_Oracle/samples/tutorial/Python-and-Oracle-Database-Scripting-for-the-Future.html" >here</a>. The files used in them can be found in the <a href="https://github.com/oracle/python-cx_Oracle/tree/master/samples/tutorial" >cx_Oracle GitHub repository</a>.</p> |
110 | 125 |
|
111 | 126 | <p>If you are running this tutorial in your own environment, install the required software:</p>
|
112 | 127 |
|
113 | 128 | <ol>
|
114 | 129 | <li><p><a target="_blank" href="https://www.python.org/">Python</a>. Version 3.6 (or later) is preferred.</p></li>
|
115 |
| - <li><p>cx_Oracle version 7.3 (or later) and the Oracle Client libraries.</p> |
| 130 | + <li><p>cx_Oracle version 7.3, or version 8, or later.</p> |
| 131 | + <li><p>Oracle Client libraries.</p> |
116 | 132 | <ul>
|
117 | 133 | <li><a target="_blank" href="https://cx-oracle.readthedocs.io/en/latest/user_guide/installation.html#installing-cx-oracle-on-linux">Linux</a></li>
|
118 | 134 | <li><a target="_blank" href="https://cx-oracle.readthedocs.io/en/latest/user_guide/installation.html#installing-cx-oracle-on-macos">macOS</a> - please note the special instructions for macOS in the link.</li>
|
@@ -150,32 +166,16 @@ <h2><a name="connectioninformation">Connection Information</a></h2>
|
150 | 166 |
|
151 | 167 | <p>The username is "pythonhol" with
|
152 | 168 | the password "welcome". The connect string is "localhost/orclpdb1".
|
153 |
| - See <code>sql/SampleEnv.sql</code>.</p> |
| 169 | +.</p> |
154 | 170 |
|
155 |
| - <p>It is easist to have a local pluggable database with the service |
156 |
| - 'orclpdb1' configured. If your database is not local, or has a |
157 |
| - different service, you will need to modify the connection information in db_config.py and db_config.sql.</p> |
| 171 | + <p>If your database is not local, or has a different service, you will need to |
| 172 | + modify the connection information in these two files. If you are installing |
| 173 | + your own schema, you can also modify the default username and password in |
| 174 | + <code>sql/SampleEnv.sql</code>.</p> |
158 | 175 |
|
159 | 176 | <p>The following sections may need adjusting, depending on how you
|
160 | 177 | have set up your environment.</p>
|
161 | 178 |
|
162 |
| - <h2><a name="overview">Overview</a></h2> |
163 |
| - |
164 |
| - <p>This tutorial is an introduction to using Python with Oracle |
165 |
| - Database. It contains beginner and advanced material. Sections can |
166 |
| - be done in any order. Choose the content that interests you and |
167 |
| - your skill level.</p> |
168 |
| - |
169 |
| - <p>Follow the steps in this document. The <code>tutorial</code> |
170 |
| - directory has scripts to run and modify. The |
171 |
| - <code>tutorial/solutions</code> directory has scripts with the |
172 |
| - suggested code changes.</p> |
173 |
| - |
174 |
| - <p>Use the Desktop icons to start editors and terminal windows.</p> |
175 |
| - |
176 |
| - <p>If you are new to Python review the <a href="#primer">Appendix: |
177 |
| - Python Primer</a> to gain an understanding of the language. </p> |
178 |
| - |
179 | 179 | <h2><a name="lab">Using Python cx_Oracle 7 with Oracle Database</a></h2>
|
180 | 180 |
|
181 | 181 | <p>Python is a popular general purpose dynamic scripting language.
|
|
0 commit comments