Oracle Database Development (3). Introduce to Pro*C/C++ Precompiler Options
Vert Melon
Jun 7,2007
1.Preface
Now we have already known about the Pro*C/C++ Development Environment in Windows
or Linux, but it is not enough.
Anyway, esaier said than done, let's start our trip.
2.What is the Precompiler
During precompilation, Pro*C/C++ generates C or C++ code that replaces the SQL
statements embedded in your host program. The generated code contains data structures
that indicate the datatype, length, and address of host variables, as well as other
information required by the runtime library, SQLLIB. The generated code also contains
the calls to SQLLIB routines that perform the embedded SQL operations.
The precompiler does not generate calls to Oracle Call Interface (OCI) routines.
The paragraph above is copied from 《Pro*C/C++ Precompiler Programmer's Guide》. I'm
clever at doing this ^_^ .
SQLLIB named "orasql9.lib" in Windows, but named "libclntsh.so.9.0" in Linux.
You could get more messages if your find it in the last articles within this series.
Oracle Database Development (1). Configuration of ProC in Windows
Oracle Database Development (2). Configuration of ProC in Linux
3.Use the Precompiler Options
Precompiler options enable you to control how resources are used, how errors are reported,
how input and output are formatted, and how cursors are managed.
In the Windows , most people prefer to use "procui.exe" to precompile host program.
Of course , the tool provides "Options" menu which gives us a platform to edit options.
When we use Linux OS, we can appoint the parameters in the command line. For example :
$ proc parse=none iname=main.pc
Developer can get more information by typing command " proc ? " in both Windows and Linux.
The method