support: Customer Portal
Focused on delivering choice, investment protection and flexibility to organizations with valuable COBOL assets
 

Veryant Knowledge Base
Home > All Categories > Data Access > COBOL/ESQL and Veryant ESQL Generator > How do I set up isCOBOL ESQL Generator for use with Microsoft SQL Server?
Question Title How do I set up isCOBOL ESQL Generator for use with Microsoft SQL Server?

Follow these steps:

  1. Compile your program with these variables set to use the Database Bridge (EasyDB) to generate bridge programs containing ESQL statements to access your Sql Server database:
       iscobol.compiler.easydb=1
       iscobol.compiler.easydb.sqlserver=1
    
  2. Put the JDBC driver in the CLASSPATH
    1. Download the Microsoft JDBC Drivers for your version of SQL Server from http://msdn.microsoft.com/en-us/data/aa937724.aspx.
    2. Open the compressed folder you downloaded and choose the .jar file you need, based on the version of Java you're using.
      For instance the jdbc driver for SQL Server version 11.2 to use with Java 1.8 would be called "mssql-jdbc-11.2.0.jre8.jar".
    3. Put this jar file in the CLASSPATH. The easiest way to do this is to put it in the %ISCOBOL%\jars folder, since this folder is automatically added to the CLASSPATH when you use the isCOBOL wrappers.
  3. Create an extended file descriptor (optional)
    1. Compile your COBOL program that has the SELECT and FD for this file with the -efd compiler option.
  4. Run your program using the correct settings in your runtime properties file
    1. Set your file index to easydb, and your prefix to the default SQL Server prefix:
         iscobol.file.index=easydb
         iscobol.easydb.prefix=srv
      
    2. Set your JDBC driver name and URL. Here's an example:
         iscobol.jdbc.driver=com.microsoft.sqlserver.jdbc.SQLServerDriver
         iscobol.jdbc.url=jdbc:sqlserver://localhost:1433;user=sa;password=sa;encrypt=false;DatabaseName=master
      
    3. We suggest you also set the ESQL internal cursor type to the SQL Server specific value of 1009, instead of the default 1007:
         iscobol.jdbc.cursor.concurrency=1009
      
NOTE: To use ISMIGRATE to move data to SQL Server from another format (for instance, Vision flat indexed file data), Repeat steps 1-3 above, and use these settings in ISMIGRATE, either by entering them manually in the Wizard, or setting them in a configuration file
   iscobol.ismigrate_input_file_index=vision
   iscobol.ismigrate_output_file_index=easydb
   iscobol.jdbc.driver=com.microsoft.sqlserver.jdbc.SQLServerDriver
   iscobol.jdbc.url="your URL - see above step 4b"
There is a video demonstration of ISMIGRATE using EasyDB here: https://youtu.be/YliamjSiuDI

Authored by: Veryant Support This question has been viewed 7972 times so far.
Click Here to View all the questions in COBOL/ESQL and Veryant ESQL Generator category.
File Attachments File Attachments
There are no attachment file(s) related to this question.
How helpful was this article to you?
User Comments User Comments Add Comment
There are no user comments for this question. Be the first to post a comment. Click Here
Related Questions Related Questions
  1. How do I use isCOBOL ESQL with Microsoft SQL Server?
  2. How do I migrate a Vision file to an Oracle database table?
  3. When to set iscobol.jdbc.autocommit=false when using ESQL
  4. How do I connect to a MS SQL 2005 Named Instance?
  5. Where is the Veryant ESQL generator? What files do I download?
  6. How does isCOBOL limit the size of database query working set for the START statement?
  7. How do I get isCOBOL to create a database table when iscobol.file_suffix is set?
  8. How is READ NEXT implemented in isCOBOL ESQL Generator (EasyDB)?
  9. How is it possible to insert a NULL into an ORACLE TABLE when host variable has been initialized?
Article Information Additional Information
Article Number: 61
Created: 2009-09-02 11:38 AM
Rating: 1 Star
 
Article Options Article Options
Print Question Print this Question
Email Question Email Question to Friend
Export to Adobe PDF Export to PDF File
Export to MS Word Export to MS Word
Bookmark Article
Subscribe to Article Subscribe to Article
 
Search Knowledge Base Search Knowledge Base



 
 

© Veryant - All Rights Reserved
Veryant and isCOBOL are trademarks or registered marks of Veryant in the United States and other countries. All other marks are the property of their respective owners.