Specifying SQL Syntax for DW Updates
\The Sandbox \PB History & Future \New in PB 2 \Painter Features \DataWindow Painter \Specifying SQL Syntax
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

When you use Update on the Rows Menu to create update characteristics for a DataWindow,  you can also specify whether you want PowerBuilder to generate:

    A WHERE clause containing key values, key values and modified columns, or key values and all updateable columns

    An UPDATE statement or a DELETE and INSERT statement when a key field is modified.

TIP:   The syntax you select can effect runtime performance.

To specify the SQL syntax:

  1. Select Update from the Rows menu.  The Update Characteristics window displays.
  2. Specify the columns you want to update.
  3. Select an option in the Where Clause for Update/Delete box; the default is Key Columns. This options controls the columns that will be included in the WHERE clause of the UPDATE or DELETE statement PowerBuilder generates when you update the database with changes in the DataWindow.

This Option

Generates a WHERE clause with

Key Columns

All key columns

Key and Updateable Columns

All key and updateable columns

Key and Modified Columns

All key and modified columns

  1. Select an option in the Key Modification box to specify the SQL you want PowerBuilder to generate when a key value is updated.  The options are :
    1. INSERT and DELETE

      UPDATE (default)

  2. Click the OK button.  PowerBuilder saves your selections and closes the Update Characteristics window.
PBL Peeper PB Help PB History
& Future About Us Feedback Site Map

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