summaryrefslogtreecommitdiff
path: root/cpp/demo/Database/Oracle/proc/README
blob: 555cff270b798e1bbe69541450641d31778b48de (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
Oracle Pro*C/C++ demo
=====================

This demo shows how to implement an Ice server that uses Oracle
through its Embedded SQL (Pro*C/C++) API.

It is a fairly simple demo that illustrates how to:
 - map relational data to Ice objects, in particular convert 
   between Ice and Oracle Pro*C/C++ types.
 - associate an Oracle Pro*C/C++ context and database connection
   to each thread in the Ice server thread pool.
 - use Ice default servants

Building the demo
-----------------
On Linux or Unix, set ORACLE_HOME to point to your Oracle 
installation home directory. Then build as usual.

On Windows, you need to add the following directories to your 
Visual C++ environment: 
 - Include files: <oracle-home>\precomp\public
 - Library files: <oracle-home>\precomp\lib
 - Executable files: <oracle-home>\bin
Then build as usual.

Running the demo
----------------
- Setup an Oracle database with the traditional EMP/DEPT schema. 
With Oracle server 10.2, the corresponding SQL script is 
$ORACLE_HOME/rdbms/admin/utilsamp.sql.

- Review the Oracle.ConnectInfo property in the config.server file.
You may need to change it to connect to your Oracle instance.

- Start the server:
$ server

- Start the client in a separate terminal:
$ client