Build your application using the DBRMLIB SQL compiler option to create DBRMs from your source code.
Create a bind script file using the Manage Packages and Plans tool, or manually in a text editor. If you create the file in a text editor, be sure to give it a file extension of
.hcodsn.
Note: For a listing of commands that are valid in HCOSS bind script files, see the topic
Bind Script Commands.
Using the Manage Connections tool, connect to your SQL Server database with a login ID and password that grants you permission to update the SYSIBM table.
In Visual Studio, open the properties for the project that contains your application.
On the
COBOL tab, click
Build Events.
In the
Post-build event command line field, type the following:
DSN SYSTEM(SQLServerConnection) @"bindScriptFile"
where
SQLServerConnection is the name of your SQL Server connection, and
bindScriptFile is the full path to and filename of your bind script file.