MF Visual cobol with eclipse

Dear sir,

I have the following problem :

Compiling JVMWorldClass1.cbl...

    [cobol] COBCH0829S Could not find method 'adoaseti' with this signature  : C:\Users\Pedro\workspace\HelloJVMworld\src\com\microfocus\example\JVMWorldClass1.cbl(45,14,14)

  • What directives are you using to compile your program?

    I

    f you are using a SQL DBMAN directive it cannot be set to ADO in the JVM environment.

    It should be set to JDBC in the JVM environment.

    Thanks.

  • When you put DBMAN Directiva in MF Visual cobol  is pre -set to JDBC no other can be set....

  • Can you please post the contents of your program and any directives that you are using so that I can try to reproduce the problem here?

    If you are planning on using JDBC in your project it is recommended that you take a look at the sample in the Samples Browser under COBOL for JVM, SQL JDBC - Getting Started (JVM)

    Thanks.

  •     $set ilusing(com.microfocus.example)

          class-id com.microfocus.example.JVMWorldClass public.

          working-storage section.

         $set constant DBMS "SQLSERVER"

         *

         * Set this constant to yes to use Windows authentication with Microsoft SQL Server

         *  

         $set constant integratedSecurity "YES"

         $if DBMS = "SQLSERVER"

         *

         * SQL Server URL syntax is

         * jdbc:sqlserver://[serverName[\instanceName][:portNumber]][;property=value[;property=value]]

         *    

         $set constant driverClass "com.microsoft.sqlserver.jdbc.SQLServerDriver"

         $if integratedSecurity="YES"

         $set constant databaseURL "jdbc:SQLSERVER://localhost;database=SQLPEDRO;integratedSecurity=true;"

         $end

         *  Include the SQL Communications Area. This includes the

         *  definitions of SQLCODE, etc

              EXEC SQL INCLUDE SQLCA END-EXEC.

              EXEC SQL BEGIN DECLARE SECTION END-EXEC

          01 svr              pic x(32).

          01 usr              pic x(32).

          01 char-col         pic x(10).

          01 int-col          pic S9(4) comp-5.

          01 connectionstring pic x(300) value spaces.

              EXEC SQL END DECLARE SECTION END-EXEC

          method-id main static.

          01 class1 type JVMWorldClass.

          procedure division using by value args as String occurs any.

              set class1 to new JVMWorldClass

              invoke class1::instanceMethod

              stop run.

          end method.

          method-id instanceMethod.

          procedure division.

         $if DBMS not = "ANY"

    TYPE6      exec sql

    TYPE6      connect using :connectionstring

    TYPE6      end-exec

         $end

              if sqlcode not = 0

                   display "Error: cannot connect "

                   display sqlcode

                   display sqlerrmc

                   goback

              end-if

              display "Hello world Sentra".

              goback.

          end method.

          end class.

    **********

    ** I am using Directives:

    ** DBMANUAL=JDBC

    ** AUTOCOMMITT

  • I was able to reproduce the problem here and I have passed it on to development for further investigation.

    It seems as if this error occurs whenever EXEC SQL statements are used under JVM from within a COBOL class.

    They work fine in a COBOL program (PROGRAM-ID) but are not being handled correctly when they are used from within a method of a COBOL class (CLASS-ID).

    I will keep you updated on the resolution that is found.

    Thanks.

  • Verified Answer

    OK ...Thanks....We wait for your resolution.....

  • Dear Sir,

    Any new about this Ocurrence ??

    Regards

  • This is a bug in the Visual COBOL 2.0 Eclipse product JVM support.

    It has been fixed by Development and should be available in the next product release, Visual COBOL 2.1 which is currently due to be GA in the September/October time frame.

    Thanks.

  • YES. The version 2.1  Corrected the Problem. TKS