[Info-vax] Oracle on VMS
Jan-Erik Soderholm
jan-erik.soderholm at telia.com
Sat Nov 19 19:33:02 EST 2016
Den 2016-11-19 kl. 22:40, skrev Bill Gunshannon:
> On 11/19/16 6:08 AM, Jan-Erik Soderholm wrote:
>> Den 2016-11-19 kl. 00:30, skrev Bill Gunshannon:
>>> On 11/18/16 12:16 PM, Jan-Erik Soderholm wrote:
>>>> Den 2016-11-18 kl. 17:02, skrev Bill Gunshannon:
>>>>>
>>>>> Maybe I have been out of touch long enough to miss the
>>>>> change, but wasn't Oracle ordered by the courts to continue
>>>>> support for VMS? I was looking at the pre-compilers for
>>>>> embedded SQL and the absence of any for VMS is kinda obvious.
>>>>> Was there never pre-compilers for VMS or have they dropped
>>>>> all support at this point in time? Of course, a pre-compiller
>>>>> implies a linkable library for the supported languages. I assume
>>>>> these don't exist either. Or did I miss something subtle?
>>>>>
>>>>> bill
>>>>
>>>> Are you talkning about "Oracle Oracle" or "Oracle Rdb"?
>>>
>>> Oracle Oracle
>>>
>>> I have never used Rdb.
>>
>> It's nice and more integrated with the VMS environment
>> then Oracle "Classic".
>>
>>> Were there pre-compilers for embedded SQL
>>> for things like COBOL for Rdb?
>>
>> Of course. Ada, C, COBOL, FORTRAN, Pascal, and PL/I *are* supported.
>> Why do you ask in past tense?
>
> Because the oracle pre-compiler download page makes no mention of VMS
> at all so I have to assume they were no longer supporting VMS.
What I wrote about was about Oracle *Rdb*. I know close to nothing
about the Oracle Oracle database and VMS. I have just seen the
PowerPoint slides talkning about supported versions and so on.
Usualy, it is hard to just search your way on the Oracle web site to VMS
specific stuff, you need to know the address, like www.oracle.com/rdb
for everything releted to Oracle Rdb.
>
>>
>> For a more language independant mode, you can also compile plain SQL
>> modules (source files) using the Modular Language SQL compiler. That
>> produces standard VMS OBJ object files that can be linked just as
>> usual with any language on VMS that follows the VMS calling standard.
>>
>> The docs are here:
>>
>> http://www.oracle.com/technetwork/database/database-technologies/rdb/documentation/index.html
>>
>>
>>
>> And the embedded SQL info is in Volume 1 of the SQL ref manual.
>> Updated as late as sept-2016, so it is up to date...
>
> Might be worth a look. Just so people understand where I am coming
> from, I am not really interested in either of the databases but I am
> interested in how embedded SQL is implemented on the commercial DBs...
You mean internaly or how it is implemented in the source code?
Such as in a typical Cobol code?
I see now that the manual called "Guide to SQL Programming" isn't
listed on the Rdb 7.3 documentation page. It is linked on the 7.0 page:
http://www.oracle.com/technetwork/database/database-technologies/rdb/documentation/rdb-doc-r70-523712.html
I think that manual has a better desctiption of the embedded SQL
programming in different languages. And also how it is compiled
and linked.
> because I am trying to look into implementing it for open source DBs
> and GnuCOBOL.
I have found that many "simpler" databases uses a "Dynamic SQL"
interface, that is, the SQL statements are sent as-is to the database
for processing at run-time. That can be done with Rdb also, but you
get much worse performance of course, when all your SQL has to be
"compiled" at each call. Yes, in many cases there are way to prepare
an SQL statement and then call it multiple times, but it still has to
be prepared (syntax checked and compiled) each time the EXE runs.
The SQL pre-compiler "compiles" your SQL code into machine code that
is optimized and read-to-run, so to speak, everytime the EXE runs.
If you look at the compiler listing file you'll see that all your:
EXEC SQL
SELECT bla, bla FROM bla WHERE [and so on]
END-EXEC
has been replaced with a CALL to some-function with a weird name.
That function contains the Rdb code to execute the SQL. The
pre-compiler embedds those function as object code into the OBJ file
for your application and the linker is linking it into your EXE.
A lot can be said about this, but actually running some exemples
might be more enlightening.
Have fun.
Jan-Erik.
More information about the Info-vax
mailing list