Contents of this
document:
Overview
of the sample
Required
Software
Assumptions
Description
of files in the sample
Prepare and Run the sample
Steps
in the sample
The property can be set as
ADO command object property just before executing the procedure. This way
the extra network trip is performed for
executionof that command
only. So it is a better practice to set the property to 'True' just
before execution of the procedure and then setting it to
'False'.
The sample shows how to set the 'SPPrmsLOB' property with command object.
Note : The maximum size of
image that can be passed as OUT parameter to stored procedure with
OraOLEDB is 64K. Images greater than this
size may not be retrieved properly from database.
Sr No |
File Name |
Type |
File Description |
| 1 | ReadMe.html | HTML File | ReadMe File for the application |
| 2 | ADODBHandler.cs | CSharp class file | Declares and defines the class for handling database functions. |
| 3 | StartForm.cs | CSharp class file | This file contains the definition of class for the form used by application.. |
| 4 | AssemblyInfo.cs | CSharp class file | Generated by compiler, this file contains assembly information for project. |
| 5 | ConnectionParams.h | C++ header file | This file contains connection parameters to connect to particular database. |
| 6 | StoredProcedure.sql | SQL script file | This file contains the sql script to create the stored procedures required by the sample. |
| 7 | StartForm.resx | Resource file | Resource template used by StartForm form |
| 8 | licenses.licx | licx file | Used by resource file |
| 9 | LOBSample.csproj | CSharp Project file | CSharp Project file |
| 10 | LOBSample.sln | CSharp solution file | CSharp Solution file |
| 11 | imageG30.jpg | Image file | Used by ReadMe.html |
| 12 | imageHHP.jpg | Image file | Used by ReadMe.html |
| 13 | imageJ3S.jpg | Image file | Used by ReadMe.html |
2.
Connect to Oracle Sql*plus using <username>/<password>@<connectstring>
.
Here <username> refers to the user in which all the tables have been
created and <password> refers to the password given for the above user
<connectstring> refers to the hostname.
3.
Make sure you have created the database tables required by this sample.
Refer db8setup.html for more information about setting up the
database tables and populating data.
4. Create Database Stored Procedure by running StoredProcedure.sql
script.
SQL> @<path>StoredProcedure.sql
5. Open LOBSample.sln using VCSharp.Net Beta2..
6. Edit ConnectionParams.csfile
to change the database connection parameters i.e. database name, user name
and password
to database you want to use . Save the file.
7. Build and Run the
sample.
fig 1
2. To select another image for update, click on "Browse " button, a File Open Common Dialog appears.
3. Once the image from the File Open Common Dialog Box is selected it appears in the new image frame.
4. "Update Image" button can be pressed to update the product image in the database
Please enter your comments about this sample in the OTN Sample code
discussion forum.