Provides instructions for running the same steps to analyze, build, bind, and run the MTwoPackageSet application, which is
an ADO.NET version of TwoPackageSet.
Analyze the MTwoPackageSet project
- In the
Solution Explorer, double-click the
Properties entry for the
MTwoPackageSet project.
- Click the
SQL tab.
Notice the directive settings for the OpenESQL ESQL Preprocessor include SQL(DBMAN=ADO). This means that the compiler uses
an ADO.NET database connection rather than an ODBC database connection.
- Close the Properties window.
Build the MTwoPackageSet project
- In the
Solution Explorer, right-click the
MTwoPackageSet project and select
Set as StartUp Project from the context menu.
- Again, right-click the
MTwoPackageSet project, but this time select
Build from the context menu.
Bind the TwoPackageSet program
- From the HCO for SQL Server interface, go to the
Bind Scripts tab of the
Manage Packages and Plans tool.
- Click
Execute All, to execute all of the BIND commands listed.
Because the application was rebuilt as a .NET application, HCOSS uses the same commands to create and bind the packages and
plan to the .NET version of the application.
Run the TwoPackageSet application
- From the
Solution Explorer in Visual Studio, open the
TwoPackageSet.cbl source file.
- Set a break point on the STOP RUN line.
- Click
Debug > Start Debugging to debug the application.
You should see the same data output that you saw when you ran the TwoPackageSet native application, indicating that the program
is switching package sets between row fetches.
This completes the tutorial.