Re: Microfocus Netexpress question : COBSQL vs openESQL

From: Robert Wagner (robert_at_wagner.net.yourmammaharvests)
Date: 09/09/04


Date: Thu, 09 Sep 2004 18:15:43 GMT

On 9 Sep 2004 07:10:18 -0700, sihingchris@hotmail.com (chris bougeard)
wrote:

>Hi everyone,
>On the site i am working on, i am in the process of converting a bunch of
>pro*cobol programs which currently sit on a unix platform/oracle database
>to work in a windows environment.
>
>Im using a development machine (windows 2000) with netexpress 3.1 to test
>how these programs work once regenerated.
>
>When it came to the issue of pre-compiling the embedded sql statements, i
>first tried using the COBSQL method but my compiles always fell over...
>
>However, by using the openESQL approach, my compiles were all clean and the
>programs connect to the database and retrieve data fine...
>
>First question, is it better to use the ORACLE supplied pre-compiler (which
>generally misbehaves) over the openESQL (which works fine) in order to
>reduce the chances of sql anomalies during run time?

It makes no difference. SQL is an ANSI-standard language, there
shouldn't be anomalies.

>Is it strange that i didnt have to load anything specifically on my machine
>in order for openESQL to work (im sure i have read that certain drivers etc
>must exist).

You don't need drivers at compile time unless you're doing SEMANTICS
checking. If the programs contain PL/SQL, SEMANTICS is mandatory.

>I recently tried to run a program compiled on my windows2000 box on an nt4
>machine , the program ran (after installing application server on it) but
>couldnt connect with the oracle database specified in the program.
>
>Could this just be down to the fact that the nt4 box is missing a dll or
>something or is there perhaps a more sinister possibility?

It may be missing an ODBC driver and/or data source. Go to Control
Panel/Administrative/Data Sources, where you'll probably find one
named with the word Oracle. The Oracle-supplied one is preferable but
the Microsoft driver works too.

You also need an entry for the data source in tnsnames.ora. If it is
protected, as it usually is, copy it to a directory to which you have
access, then run REGEDIT to change the pointer to your directory.

There is a way around this, by supplying the tnsnames entry at
execution time. You're not ready for the advanced class yet. :)

>I actually tried today to re-compile this program using COBSQL, its
>failing with CSQL-E-036 "unable to open the precompiler file
>"filename".cs9".
>
>Dont suppose you have any ideas on this one ?

Look in cobsql.dir. Make sure cobsqlinclude= points to the right
directory.

>WHERE do i put the compiler directives when using COBSQL?

That depends on whether you are running it in 'integrated mode' or
standalone. Your comments indicate standalone. In that case you give
precompiler directives to the precompiler and compiler directives to
the compiler. (duh)

Don't trust COBSQL to do anything right. Run the compiler as a
separate step.

>Is "application server" just simply a set of run time dll's that you need
>user licenses for to run cobol apps?
>
>I presume it doesnt run as a service...

Many different products are named "application server". The Oracle
Application Server Standard Edition One is a $4,995 package of
development tools, network cache, etc. It is more than a set of dlls.
If that's the one you're talking about, yes, you need an expensive
license to run apps written in any language.

The good news is you don't need Oracle Application Server. All you
need is a device driver, a defined data source and SQL*NET (the
tnsnames guy).



Relevant Pages

  • dbi:oracle win2k ORA-1222 problems
    ... The database is Oracle 7 running on a totally different machine. ... I found a bit of code that would check all available DBI drivers and their data sources. ... Driver: Oracle ... Data Source is DBI:Oracle:Space ...
    (perl.dbi.users)
  • RE: oracle win2k ORA-1222 problems
    ... I am having a real problem with that! ... The database is Oracle 7 running on a totally different machine. ... Driver: Oracle ... Data Source is DBI:Oracle:Space ...
    (perl.dbi.users)
  • Re: Oracle 9i ODBC Driver for Windows XP 64 (XP 2003)
    ... One thing to try is to use the 32-bit ODBC Data Source Adminstrator. ... the Oracle driver is there. ...
    (comp.databases.oracle.server)
  • RE: oracle win2k ORA-1222 problems
    ... If you are trying to connect to an Oracle 7 database then you need to use ... The database is Oracle 7 running on a totally different machine. ... Driver: Oracle ... Data Source is DBI:Oracle:Space ...
    (perl.dbi.users)
  • FIXXED!! oracle win2k ORA-1222 problems
    ... Have been able to get the webserver to connect to the oracle DB. ... I found a bit of code that would check all available DBI drivers and their data sources. ... Driver: Oracle ... Data Source is DBI:Oracle:Space ...
    (perl.dbi.users)