Creating an OLE Column
\The Sandbox \PB History & Future \New in PB 2 \Painter Features \DataWindow Painter \OLE Columns
Assigning
Accelerators
Tag Values
DW Icon
Comments
Changing
Databases
Controlling DW
Updates
OLE Columns
DataWindow
Reports
Dynamic DWs
Runtime Print
Specifications
Displaying the
DDLB Arrow
Displaying
Row Counts
Sort and Filter
Testing
Modifying Result
Sets Descriptions
Moving Object
with Keyboard
Naming Objects
Aggregate
Functions
New Color Bar
Events
DW Functions
New Menu Items
Grid Style
Shortcut Keys
Align Objects
Size Objects
Space Objects
Saving DWs
with Comments
Keyboard Object
Selection
Selecting a Font
Selecting a
Line Edit
Keyboard Sizing
Specifying
SQL Syntax
Background
Color
Timer Interval
Unit of Measure
Validation
Message
DB Table
Changes
Suppressing
Repeating Values
Testing an
OLE Column
Using Comments

To create an OLE column:

  1. Specify the data source.  The database table you select must have at least two columns (a key column and a column with the data type blob).
  2. Save the DataWindow and return to the DataWindow Painter workspace.
  3. Select OLE Database Blob from the Objects Menu and click the position at  which you want to place the Blob in the DataWindow.  The Database Binary/Large Text Object window lists the available database tables.
  4. Enter a name for the object in the Name box.
  5. Select the database table that contains the large database object you want to insert in the DataWindow.  The names of the large binary or text columns in the selected table display in the Large Binary/Text Column list box. 
  6. Select the column that contains the Blob data type by double-clicking the column name or entering the name in the box.
  7. Enter the key clause in the Key Clause box. The key clause can be any valid WHERE clause.  For example: 

        key_col = :doc_id

    The key clause is used to build the WHERE clause in the SELECT or UPDATE statement for the OLE column.

  1. Enter the name of the file you want to open in the OLE client application.  For example, to specify a Word for Windows document, enter the name of a .doc file.
  2. TIP:   If the server application is not on the current path, enter the fully-qualified name. 

  3. Enter the text or an expression that can be evaluated in the DataWindow (usually with a Key clause) in the Client Name Expression box.  This expression will display in the server application to identify the file.
  4. TIP:   If you have more than one OLE column in your DataWindow, use an expression to make sure the name is unique.  For example, you might enter this expression to identify a document (doc_id as the key column name):
                "Document: " + doc_id

  5. Click OK.  PowerBuilder closes the Database Binary/Large Text Object window and displays the DataWindow workspace.

TIP:      To make the blob column easy to see, place a rectangle on top of the Blob and then select Send To The Back on the Edit Menu.

PBL Peeper PB Help PB History
& Future About Us Feedback Site Map

Google
 
Web www.techno-kitten.com
www.sybase.com